Retrieve a customer by ID for the authenticated workspace.
Python
from dub import Dub with Dub( token="DUB_API_KEY", ) as d_client: res = d_client.customers.get(request={ "id": "<id>", }) # Handle response print(res)
{ "id": "<string>", "externalId": "<string>", "name": "<string>", "email": "<string>", "avatar": "<string>", "country": "<string>", "sales": 123, "saleAmount": 123, "createdAt": "<string>", "link": { "id": "<string>", "domain": "<string>", "key": "<string>", "shortLink": "<string>", "url": "<string>", "programId": "<string>" }, "programId": "<string>", "partner": { "id": "<string>", "name": "<string>", "email": "<string>", "image": "<string>" }, "discount": { "id": "<string>", "amount": 123, "type": "percentage", "maxDuration": 123, "couponId": "<string>", "couponTestId": "<string>", "description": "<string>", "partnersCount": 123 } }
Show child attributes
Was this page helpful?