Referrals

Parameters

HTTP method

Access rights

URL

Parameters

Note

GET referrals https://api.admitad.com/referrals/
  • offset**
  • limit**
  • date_start***
  • date_end***

Returns the list of referrals*.

GET referrals https://api.admitad.com/referrals/{id}  

Returns the referral, where id is the referral ID.*

  • * Returns the result in the JSON format.

  • ** Sets skipping and the number of records returned. For example limit=5&offset=2.

  • *** Filter by date. For example date_start=01.01.2011&date_end=01.01.2012. Date values should be in the following format ‘%d.%m.%Y’ - ‘01.05.2012’.

Example of use

Example of a request with utility ``curl``:

curl -L -H 'Authorization: Bearer access_token' -X GET
https://api.admitad.com/referrals/

curl -L -H 'Authorization: Bearer access_token' -X GET
https://api.admitad.com/referrals/8/

Example of the response from the API server in the JSON format:

{
"results": [
{
"username": "qweasdqwe",
"id": 8,
"payment": null
},
{
"username": "webmaster1_ref1",
"id": 6,
"payment": null
}
],
"_meta": {
"count": 2,
"limit": 20,
"offset": 0
}
}

Description of API server response fields

Name

Description

id

Referral ID

username

Referral username

payment

Amount