Skip to content

This method returns the current status of a bank card payment by the identifier from the initialization response (order_id) or by your user_data if order_id was not saved. Use it to poll status after creating a payment via form or host2host (GATE), and when callback delivery fails.

How it works

  1. Identification — in the request, specify order_id (from the init_form / init_payment response) or user_data (order ID on your side).
  2. Request — the server sends a signed request to the status_payment endpoint.
  3. Response — the API returns JSON with the current status, amounts, masked card number, and if needed fields for 3-D Secure (redirect_url, 3ds_url, pa_req, creq, md).

Interpretation of status and status_description codes — see Transaction statuses.

Technical information

Endpointhttps://api.1payment.com/status_payment
MethodsGET, POST
Response formatJSON
Payment type in responseFor cards, payment_type equals card

Request parameters

Required

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

Payment identification

Pass one of the following parameters:

ParameterTypeDescription
order_idStringPayment ID in 1Payment (from the initialization response).
user_dataStringYour order ID; used if order_id is not specified.

Signature generation (sign)

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

Formula:

MD5(status_payment + <параметры_без_sign_в_алфавитном_порядке_через_&> + <API_KEY>)

Example string before hashing (lookup by order_id):

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

Signature verification 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_paymentorder_id=8p3brmb19gfg0sg8gcwhws8kgc748s87&partner_id=1234&project_id=5678
Expected signature: a33a3e5a9bd5dedd4a397513abd74094
Signature does not match

Request examples

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

async function getCardPaymentStatus(apiKey, params) {
  const sortedKeys = Object.keys(params).sort();
  const queryString = sortedKeys.map((key) => `${key}=${params[key]}`).join('&');

  const baseString = `status_payment${queryString}${apiKey}`;
  params.sign = crypto.createHash('md5').update(baseString).digest('hex');

  const response = await axios.get('https://api.1payment.com/status_payment', { params });
  return response.data;
}

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

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

API response

Successful response (200):

{
  "payment_type": "card",
  "project_id": 5678,
  "order_id": "8p3brmb19gfg0sg8gcwhws8kgc748s87",
  "user_data": "order_777",
  "status": 3,
  "status_description": "SUCCESS",
  "init_time": "2026-05-05T18:23:11Z",
  "status_time": "2026-05-05T18:23:42Z",
  "merchant_price": 50,
  "init_price": 50,
  "user_price": 48.5,
  "currency": "RUB",
  "account": "411111******1111",
  "token": "card_t_1a2b3c"
}
FieldDescription
payment_typePayment type; for cards — card.
project_idYour project ID.
order_idPayment ID in the 1Payment system.
user_dataIdentifier passed when creating the payment.
statusNumeric code: 2 — pending, 3 — success, 4 — declined.
status_descriptionPENDING, SUCCESS, or FAILURE.
init_timePayment creation time (UTC).
status_timeTime the current status was received (UTC).
merchant_pricePayment amount for the payer.
init_priceAmount at initialization.
user_pricePartner payout amount.
currencyPayment currency (ISO 4217).
accountMasked card number.
status_codeDecline reason code (when status = 4; see decline codes).
tokenSaved card identifier after successful payment (if enabled; see subscriptions).
test1 for test transactions.

3-D Secure fields

When status is pending and 3-D Secure is required, the response may include:

FieldDescription
redirect_urlURL to redirect the payer to the bank ACS.
3ds_urlBank ACS URL for 3-D Secure.
pa_reqParameter for 3-D Secure v1.x.
creqParameter for 3-D Secure v2.x.
md3-D Secure service parameter.

If the response contains redirect_url or 3ds_url, redirect the payer to complete payment (see also host2host (GATE)).

Request error (400):

{
  "error_code": 2
}

Was this article helpful?