Description
Used to get a list of the user (affiliate) postbacks.
URL: https://api2.cpapanel.com/api/v3/cpa/user_postbacks/
METHODS: GET
Request
Headers
Key |
Value |
Description |
---|---|---|
Content-Type |
application/json |
Request data type |
Authorization |
Api-key <User api-key> |
Authorization type |
Params
Field |
Required |
Validation rules |
Type |
Min length |
Max length |
Description |
---|---|---|---|---|---|---|
limit |
No |
- |
Integer |
1 digit |
- |
Limit for pagination |
offset |
No |
- |
Integer |
1 digit |
- |
Offset for pagination |
ordering |
No |
UserPostbacksOrdering validation |
String |
- |
- |
Order by field |
created_start |
No |
Date |
String |
- |
- |
Filter by created date (start date) |
created_end |
No |
Date |
String |
- |
- |
Filter by created date (end date) |
offers |
No |
- |
Integer |
- |
- |
Filter by Offer ID |
conversion_id |
No |
- |
String |
- |
- |
Filter by conversion id (UUID) |
url |
No |
- |
String |
1 |
- |
Filter by URL |
fields* |
No |
- |
Array |
0 items |
- |
The array of fields for export |
* only for export |
Ordering supports the following fields/values:
created\-created conversion__offer__id/-conversion__offer__id |
Request example:
https://api2.advendor.net/api/v3/cpa/user_postbacks/?limit=50&ordering=-created&timezone=UTC&created_start=2020-09-01&created_end=2020-09-30 |
You can send statistics to export if specify ".export" suffix in URL
https://api2.advendor.net/api/v3/cpa/user_postbacks.export/?limit=50&ordering=-created&timezone=UTC&created_start=2020-09-01&created_end=2020-09-30 |
Response
Field |
Condition |
Type |
Min length |
Max length |
Description |
---|---|---|---|---|---|
error |
Wrong request |
Integer |
1 digit |
- |
Error code (look below) |
fields |
Wrong request |
Array |
1 item |
- |
Array with field names in request with the error |
message |
Wrong request |
String |
1 char |
- |
Error code description |
results |
Valid request |
Array |
- |
- |
List of UserPostback objects |
count |
Valid request |
Integer |
- |
- |
Count of available elements with filters |
UserPostback object
(results)
Field |
Condition |
Type |
Min length |
Max length |
Description |
---|---|---|---|---|---|
id |
Always present |
Integer |
- |
- |
UserPostback ID |
url |
Always present |
String |
- |
- |
UserPostback URL |
created |
Always present |
String |
27 chars |
27 chars |
UserPostback created date |
conversion |
Always present |
Object |
- |
- |
Conversion object |
conversion_comment |
Always present |
String |
- |
- |
Conversion comment |
http_code |
Always present |
Integer or null |
- |
- |
Response HTTP code |
error |
Always present |
String |
- |
- |
Error message |
old_values |
Always present |
Object or null |
- |
- |
Conversion old values |
new_values |
Always present |
Object |
- |
- |
Conversion new values |
Conversion object
(UserPostback object: conversion)
Field |
Condition |
Type |
Min Length |
Max Length |
Description |
---|---|---|---|---|---|
id |
Always present |
String |
- |
- |
Conversion ID (UUID) |
goal |
Always present |
Object |
- |
- |
Goal object |
offer |
Always present |
Object |
- |
- |
Offer object |
Goal object
(Conversion object: goal)
Field |
Condition |
Type |
Min Length |
Max Length |
Description |
---|---|---|---|---|---|
id |
Always present |
Integer |
- |
- |
Goal ID |
title |
Always present |
Object |
- |
- |
GoalTitle object |
GoalTitle object
(Goal object: title)
Field |
Condition |
Type |
Min Length |
Max Length |
Description |
---|---|---|---|---|---|
id |
Always present |
Integer |
1 |
- |
Goal title ID |
name |
Always present |
String |
1 char |
50 chars |
Offer title name |
abbr |
Always present |
String |
- |
50 |
Goal title abbreviation |
Offer object
(Conversion object: offer)
Field |
Condition |
Type |
Min Length |
Max Length |
Description |
---|---|---|---|---|---|
id |
Always present |
Integer |
- |
- |
Offer ID |
title |
Always present |
String |
1 char |
50 chars |
Offer title |
Values object
(UserPostback object: old_values, new_values)
Field |
Condition |
Type |
Min length |
Max length |
Description |
---|---|---|---|---|---|
payout |
Always present |
Integer |
- |
- |
Conversion payout |
status |
Always present |
Integer |
- |
- |
Status of conversion |
Conversion statuses list:
-
1 - Hold
-
2 - Approved
-
3 - Declined
Valid answer example:
Status code: 200
{ "count": 3, "results": [ { "conversion": { "goal": { "id": 4102, "title": { "abbr": "DOI - PC", "id": 27, "name": "Confirmed Registration (DOI) - Promocode" } }, "id": "7d183882-e3c4-4775-bc3e-859a69160baa", "offer": { "id": 11, "title": "Test offer" } }, "conversion_comment": "", "created": "2020-09-20T10:00:03.003606Z", "error": "Remote server error", "http_code": null, "id": 352911, "new_values": { "payout": 1.0, "status": 2 }, "old_values": { "payout": 1.0, "status": 1 }, "url": "http://example.com" }, { "conversion": { "goal": { "id": 4102, "title": { "abbr": "DOI - PC", "id": 27, "name": "Confirmed Registration (DOI) - Promocode" } }, "id": "7d183882-e3c4-4775-bc3e-859a69160baa", "offer": { "id": 11, "title": "Test offer" } }, "conversion_comment": "", "created": "2020-09-20T10:00:02.313619Z", "error": "Remote server error", "http_code": null, "id": 352910, "new_values": { "payout": 1.0, "status": 2 }, "old_values": { "payout": 1.0, "status": 1 }, "url": "http://example.com" }, { "conversion": { "goal": { "id": 4102, "title": { "abbr": "DOI - PC", "id": 27, "name": "Confirmed Registration (DOI) - Promocode" } }, "id": "7d183882-e3c4-4775-bc3e-859a69160baa", "offer": { "id": 11, "title": "Test offer" } }, "conversion_comment": "", "created": "2020-09-10T09:52:43.478343Z", "error": "Remote server error", "http_code": null, "id": 350943, "new_values": { "payout": 1.0, "status": 1 }, "old_values": null, "url": "http://example.com" } ] } |
Wrong answer example:
Status code: 401
{ "error": -3, "message": "Token invalid or expired", "fields": [ "detail" ] } |