Skip to Content
Developers
Returns and disputes

Ask for a lead return, or raise a dispute on a call

Needs the returns:write scope. About scopes

Try it with a test key

Sends to https://api.traki.io

Test keys only. The key stays in this page while it is open and is never saved.

/v1/buyer/returns

A lead return must fall inside the campaign’s return window; one request per lead and per call is open at a time. The account decides in its inbox.

Authorization

key
headerAuthorizationBearer <traki_buyer_…>

Request Body

application/json
  1. body
kind*string
Value in"lead""call"
leadId?string
Formatuuid
callId?string
Formatuuid
reasonKey?string
Value in"bad_phone""fake""duplicate""out_of_area""never_applied""no_consent""other"
reason?string
Length5 <= length <= 500
evidenceUrl?string
Formaturi
Lengthlength <= 1000

Response Body

Success

application/json
  1. response
id*string
Formatuuid
kind*string
Value in"lead""call"
code*string
state*string
reason*string
reasonKey*string|null
note*string|null
lead*|null
call*|null
campaign*|null
source*|null
amount*number|null
credited*number|null
resolution*string|null
requestedAt*string
decidedAt*string|null
windowClosesAt*string|null
Example Request
curl -X POST 'https://api.traki.io/v1/buyer/returns' \  -H "Authorization: Bearer $TRAKI_KEY" \  -H 'Content-Type: application/json' \  -H 'Idempotency-Key: a-unique-id-for-this-change' \  -d '{  "kind": "lead"}'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "kind": "lead",  "code": "string",  "state": "string",  "reason": "string",  "reasonKey": "string",  "note": "string",  "lead": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "code": "string"  },  "call": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "code": "string"  },  "campaign": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string"  },  "source": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string"  },  "amount": 0,  "credited": 0,  "resolution": "string",  "requestedAt": "string",  "decidedAt": "string",  "windowClosesAt": "string"}