Automate company enrichment directly in Google Sheets using Dun & Bradstreet (D&B) Data Blocks. This workflow reads DUNS numbers from a sheet, fetches a Bearer token (via Basic Auth → /v3/token), calls the Data Blocks API for each row (/v1/data/duns/...), extracts Paydex , and appends or updates the sheet. A Filter node skips rows already marked Complete for efficient, idempotent runs.
/v3/token (Basic Auth)duns, paydex, Complete.Complete is empty.Authorization: Bearer <token>).{{$json.organization.businessTrading[0].summary[0].paydexScoreHistory[0].paydexScore}}duns, writing paydex and setting Complete = Yes.The workflow also includes Sticky Notes with in-canvas setup help.
duns.Replace any example Sheet IDs/URLs with your own (avoid publishing private IDs).
/v3/token) — Optional Dynamic Token NodeGet Bearer Token1.POSThttps://plus.dnb.com/v3/tokengrant_type = client_credentialsAccept = application/jsonaccess_token.Authorization: Bearer {{$node["Get Bearer Token1"].json["access_token"]}}⚠️ Security: Don't hardcode tokens. Prefer credentials or fetch dynamically.
Node: D&B Info (HTTP Request)
Authentication: Header Auth (recommended)
URL:
https://plus.dnb.com/v1/data/duns/{{ $json.duns }}?blockIDs=paymentinsight_L4_v1&tradeUp=hq&customerReference=customer%20reference%20text&orderReason=6332
Headers:
Accept = application/jsonAuthorization = Bearer {{$node["Get Bearer Token1"].json["access_token"]}}
{{ $json.duns }}is resolved from the current row provided by Get Companies.
Keep Score (Set)
Field Paydex (Number):
{{$json.organization.businessTrading[0].summary[0].paydexScoreHistory[0].paydexScore}}
Append to g-sheets (Google Sheets)
Append or Updatedunsduns = {{ $('Get Companies').item.json.duns }}paydex = {{ $json.Paydex }}Complete = YesComplete blank).Complete = Yes.duns.Complete is truly empty (no spaces) for new items.Need help customizing this (e.g., enriching more fields, normalizing responses, or bulk-processing large sheets)?


