Перейти к содержимому

Создать запрос на отправку денег

POST
/api/v1/social/money/send
curl --request POST \
--url https://core.example.com/api/v1/social/money/send \
--header 'Content-Type: application/json' \
--header 'session-token: <session-token>' \
--data '{ "send": { "to_profile_id": 1, "to_profile": "example", "to_account_id": 1, "amount": 1, "currency": "example", "message": "example", "privacy": "example", "country_code": "example", "pic_ids": [ 1 ] } }'
segregated_account_id
integer

ID business account, к которому имеет доступ текущий пользователь

Media typeapplication/json
object
send
required
object
to_profile_id
integer
to_profile
string
to_account_id

Передаётся banking-клиентом, но отсутствует в strong params Core и фактически игнорируется

integer
amount
required
number format: double
currency
required
string
message
string
privacy
string
country_code
string
pic_ids
Array<integer>
Examplegenerated
{
"send": {
"to_profile_id": 1,
"to_profile": "example",
"to_account_id": 1,
"amount": 1,
"currency": "example",
"message": "example",
"privacy": "example",
"country_code": "example",
"pic_ids": [
1
]
}
}

Успешный ответ

Media typeapplication/json
object
success
required
boolean
status
required
integer
key
additional properties
any
Example
{
"success": true,
"status": 200
}

Ошибка авторизации, валидации или бизнес-правила

Media typeapplication/json
object
success
required
boolean
status
required
integer
errors
required
One of:
Array<object>
object
code
string
kind
string
nullable
expiration
string
nullable
session
string
nullable
key
additional properties
any
key
additional properties
any
Example
{
"success": false,
"status": 403
}