Партнерская программа
Информация о партнерской программе
GET
/account/partner
Получаем детали партнерской программы
Headers
Name
Value
Content-Type
application/json
Authorization
Bearer
<YOUR_API_KEY>
Example request
use Illuminate\Support\Facades\Http;
$api_key = 'YOUR_API_KEY';
$base_url = '{ваш_домен}/api/v2'
$response = Http::baseUrl($base_url)->withToken($api_key)->asJson()
->get('/account/partner')->json();
Response
{
"type": "referral",
"attributes": {
"percent_referral": 0.5,
"count_referral": 2,
"iso_code": "rub",
"referral_hash": "Gz",
"balance": 1190.36,
"totals": {
"balance": 190.36000061035,
"withdrawal": 0
}
}
}
Партнерский выводы
GET
/account/partner/withdrawal
Получаем список партнерских выводов
Headers
Name
Value
Content-Type
application/json
Authorization
Bearer
<YOUR_API_KEY>
Example Request
use Illuminate\Support\Facades\Http;
$api_key = 'YOUR_API_KEY';
$base_url = '{ваш_домен}/api/v2'
$response = Http::baseUrl($base_url)->withToken($api_key)->asJson()
->get('/account/partner/withdrawal')->json();
Response
{
"data": [
{
"id": 1,
"type": "referral_charge",
"attributes": {
"created_at": "11 мая 2024 09:42",
"payout_status": "unpaid",
"charged_amount": {
"amount": "1190.36",
"currency": "RUB",
"name": "Сбербанк RUB"
}
}
}
],
"links": {
"first": "{ваш_домен}/api/v2/account/partner/withdrawal?page=1",
"last": null,
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"path": "{ваш_домен}/api/v2/account/partner/withdrawal",
"per_page": 20,
"to": 1
}
}
Партнерские обмены
Получаем список партнерских обменов
GET
/account/partner/exchanges
Headers
Name
Value
Content-Type
application/json
Authorization
Bearer
<YOUR_API_KEY>
Example request
use Illuminate\Support\Facades\Http;
$api_key = 'YOUR_API_KEY';
$base_url = '{ваш_домен}/api/v2'
$response = Http::baseUrl($base_url)->withToken($api_key)->asJson()
->get('/account/partner/exchanges')->json();
Response
{
"data": [
{
"id": 2,
"type": "referral_charge",
"attributes": {
"status": "referral",
"created_at": "3 недели назад",
"amount": 95.18,
"currency": "rub",
"order_id": 1713350854300
}
}
],
"links": {
"first": "{ваш_домен}/api/v2/account/partner/exchanges?page=1",
"last": null,
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"path": "{ваш_домен}/api/v2/account/partner/exchanges",
"per_page": 20,
"to": 2
}
}
Last updated
Was this helpful?