Skip to content

This method returns the current status of a payout by the identifier from the initiation response (order_id) or by your user_data if order_id was not saved. Use it to poll status after creating a payout, and when callback delivery fails.

Request and signature format — see API request format.

How it works

  1. Identification — pass order_id (from the payout creation response) or user_data (payout ID on your side).
  2. Request — the server sends a signed request to the status_payout endpoint.
  3. Response — the API returns JSON with the current status, amounts, recipient details, and if needed additional fields paid_amount or init_amount.

See Transaction statuses for status and status_description codes.

Technical details

Endpointhttps://api.1payment.com/status_payout
MethodsGET, POST
Response formatJSON
Type in responsepayout_type field — see Payout types

Request parameters

Required

ParameterTypeDescription
partner_idIntegerYour unique ID in the 1Payment system.
project_idIntegerYour project identifier.
signStringRequest signature (see the Signature section).

Payout identification

Pass one of the following parameters:

ParameterTypeDescription
order_idStringPayout ID in 1Payment (from the initiation response).
user_dataStringYour payout ID; used when order_id is not specified.

Signature (sign)

Signature: MD5, lowercase (hex). General rules — API request format.

Formula:

MD5(status_payout + <params_excluding_sign_in_alphabetical_order_joined_with_&> + <API_KEY>)

Example string before hashing (lookup by order_id):

status_payoutorder_id=8p3brmb19gfg0sg8gcwhws8kgc748s87&partner_id=1234&project_id=5678secret_key

Verify signature in the documentation

Signature check for {{method}}

Paste the request parameters (JSON), API key, and signature. The widget verifies them automatically.

Parameter string: order_id=8p3brmb19gfg0sg8gcwhws8kgc748s87&partner_id=1234&project_id=5678
String for MD5: status_payoutorder_id=8p3brmb19gfg0sg8gcwhws8kgc748s87&partner_id=1234&project_id=5678
Expected signature: 63dab4a5c770f75266745dc10644dfaa
Signature does not match

Request examples

const crypto = require('crypto');
const axios = require('axios');

async function getPayoutStatus(apiKey, params) {
  // 1. Сортируем параметры по алфавиту
  const sortedKeys = Object.keys(params).sort();
  const queryString = sortedKeys.map((key) => `${key}=${params[key]}`).join('&');

  // 2. Подпись с префиксом status_payout
  const baseString = `status_payout${queryString}${apiKey}`;
  params.sign = crypto.createHash('md5').update(baseString).digest('hex');

  // 3. GET-запрос
  const response = await axios.get('https://api.1payment.com/status_payout', { params });
  return response.data;
}

const apiKey = process.env.ONEPAYMENT_API_KEY;
const data = {
  partner_id: 1234,
  project_id: 5678,
  order_id: '8p3brmb19gfg0sg8gcwhws8kgc748s87',
};

getPayoutStatus(apiKey, data).then(console.log);

API response

Successful response (200):

{
  "payout_type": "card",
  "project_id": 5678,
  "order_id": "8p3brmb19gfg0sg8gcwhws8kgc748s87",
  "user_data": "12345",
  "status": 3,
  "status_description": "SUCCESS",
  "init_time": "2019-04-01 18:01:55",
  "status_time": "2019-04-01 18:02:59",
  "amount": "100",
  "balance_amount": "102.5",
  "destination": "411111******1111",
  "status_code": 0
}
FieldDescription
payout_typePayout type (see Payout types).
project_idYour project ID.
order_idPayout ID in the 1Payment system.
user_dataIdentifier passed when creating the payout.
statusNumeric code: 2 — pending, 3 — success, 4 — declined.
status_descriptionPENDING, SUCCESS, or FAILURE.
init_timePayout creation time.
status_timeTime the current status was received.
amountPayout amount.
balance_amountAmount debited from balance.
currencyPayout currency (ISO 4217).
destinationRecipient; for card payouts — masked card number.
status_codeDecline reason code (when status = 4).
paid_amountOnly when status = 2 (PENDING) and partial payout: cumulative partial payout amount at the moment.
init_amountOnly when status = 3 (SUCCESS) and initiation amount differs from payout amount: initiation amount; amount and balance_amount contain actual processed amounts.

Request error (400):

{
  "error_code": 2
}

Was this article helpful?