Create a Payment
POST /api/vendor/v1/payments.json?api_token={api_token}
Arguments
Name | Parameter Type | Data type | Required/Optional | Description |
---|---|---|---|---|
api_token | query | string | Required | API token of the manager who perform the operation (see API Token Authentication). |
account_id | form | integer | Required | An account ID. |
manager_id | form | integer | Optional | A manager ID who is responsible for managing the payment. |
total | form | decimal | Required | An amount of the payment. |
comment | form | string | Required | Additional information about the payment. |
Response model
Name | Data type | Description |
---|---|---|
id | integer | An order ID. |
account_id | integer | An account ID, which makes the payment. |
total | float | An amount of the payment. |
comment | string | Additional information about the payment. |
created_at | date | A date and time of the payment's creation. |
updated_at | date | A date and time of the changes last time. |
status | string | One of the following statuses of the payment:
|
payment_method_id | integer | A payment method ID. |
document_id | string | A payment document number. The mask of a payment number is set in the platform settings in the "Document ID format" group (see System settings in the ActivePlatform. Operator Control Panel). |
requester IP | string | An IP address of the user who makes the payment. |
manager_id | integer | A manager ID who is responsible for the handling of the payment. |
denominated | An internal parameter which was used during the denomination process of the Belorussian ruble:
| |
expiration_date | data | An expiration date of the payment, which is used for payments with "Post-pay" payment method. This parameter is not used in the current version of ActivePlatform. |
Request example
POST http://billing.activeplatform.com:80/api/vendor/v1/payments.json?api_token=654321
{
"account_id": 2000532,
"total": 100,
"comment": "Cash"
}
Response example
{
"id": 2007039,
"account_id": 2000532,
"total": "100.0",
"comment": "Cash",
"created_at": "2016-10-04T10:52:17.813+03:00",
"updated_at": "2016-10-04T10:52:17.813+03:00",
"status": "waiting_for_payment",
"payment_method_id": null,
"document_id": "P006131",
"requester_ip": "178.159.242.50",
"manager_id": null,
"denominated": false,
"expiration_date": null
}