### CactusPay API Payment Creation Response Example Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/sozdanie-platezha This JSON object represents a successful response from the CactusPay API after creating a payment. It includes a status, a URL for the payment, and details about the payment requisites if applicable, such as an expiration time and a QR code for specific payment methods. ```json { "status": "success", "response": { "url": "https://pay.cactuspay.pro/2117529", "requisite": { "status": "success", "response": { "until": "Wed, 12 Feb 2025 22:50:52 +0300", "until_timestamp": 1739389852, "amount": 1625, "receiverQR": "https://qr.nspk.ru/AD20006HE9CEMV769MF8RA2HI4K9QD5B?type=02&bank=100000000123&sum=175500&cur=RUB&crc=ADE2", "order_id": "5b9a6715fe93a8a1cff1f64de4f5da" } } } } ``` -------------------------------- ### POST Request for Payment Export Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/eksport-platezhei This snippet demonstrates how to make a POST request to the CactusPay API to export payment data. It requires a JSON body containing the shop token, and the start and end dates for the export period. The response will contain payment details and aggregated statistics. ```HTTP POST https://lk.cactuspay.pro/client/shop/export Content-Type: application/json { "token": "your_shop_token", "dateFrom": "2024-01-01T00:00:00Z", "dateTo": "2024-12-31T23:59:59Z" } ``` -------------------------------- ### POST /client/payment/dispute/create Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/sozdanie-spora-po-platezhu Initiates a payment dispute by providing the order ID and a dispute file (e.g., a check). ```APIDOC ## POST /client/payment/dispute/create ### Description This endpoint allows you to create a dispute for a specific payment. You need to provide the order ID and upload a file, such as a check, as evidence for the dispute. ### Method POST ### Endpoint https://lk.cactuspay.pro/client/payment/dispute/create ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **order_id** (STRING) - Required - Unique identifier for the payment details. - **file** (FILE) - Required - The evidence file for the dispute (e.g., a check). ### Request Example ``` --form "order_id=12345" --form "file=@/path/to/your/check.pdf" ``` ### Response #### Success Response (200) - **status** (STRING) - Indicates the status of the dispute creation request. Expected value is "success". #### Response Example ```json { "status": "success" } ``` ``` -------------------------------- ### POST /api/?method=get Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/informaciya-po-platezhu Retrieves detailed information about a payment, including its ID, order ID, amount, and status. ```APIDOC ## POST /api/?method=get ### Description Retrieves detailed information about a payment, including its ID, order ID, amount, and status. ### Method POST ### Endpoint https://lk.cactuspay.pro/api/?method=get ### Parameters #### Request Body - **token** (STRING) - Required - The secret key of your store. - **order_id** (STRING) - Required - The unique payment identifier in your system. ### Request Example ```json { "token": "YOUR_STORE_TOKEN", "order_id": "YOUR_ORDER_ID" } ``` ### Response #### Success Response (200) - **id** (NUMBER) - The unique payment identifier in our system. - **order_id** (STRING) - The unique payment identifier in your system. - **amount** (STRING) - The payment amount. - **status** (STRING) - The payment status: ACCEPT, WAIT. #### Response Example ```json { "id": 12345, "order_id": "YOUR_ORDER_ID", "amount": "100.50", "status": "ACCEPT" } ``` ``` -------------------------------- ### CactusPay API Payment Creation Request Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/sozdanie-platezha This snippet demonstrates a `POST` request to the CactusPay API to create a payment. It requires parameters such as `token`, `amount`, and optionally `order_id`, `description`, `h2h`, `user_ip`, and `method`. The `method` parameter supports values like 'card', 'sbp', 'yoomoney', 'crypto', and 'nspk'. ```http POST https://lk.cactuspay.pro/api/?method=create Content-Type: application/json { "token": "YOUR_STORE_KEY", "order_id": "unique_payment_id", "amount": 100.50, "description": "Payment for order #123", "h2h": false, "user_ip": "192.168.1.1", "method": "yoomoney" } ``` -------------------------------- ### Payment Creation API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api API endpoint for creating new payments within the CactusPay Pro system. This allows for programmatic initiation of payment transactions. ```APIDOC ## POST /dobro-pozhalovat/api/sozdanie-platezha.md ### Description API endpoint for creating new payments. ### Method POST ### Endpoint /dobro-pozhalovat/api/sozdanie-platezha.md ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **amount** (number) - Required - The amount of the payment. - **currency** (string) - Required - The currency of the payment (e.g., 'USD', 'EUR'). - **description** (string) - Optional - A description for the payment. ### Request Example ```json { "amount": 100.50, "currency": "USD", "description": "Payment for services" } ``` ### Response #### Success Response (200) - **payment_id** (string) - The unique identifier for the created payment. - **status** (string) - The current status of the payment (e.g., 'pending', 'completed'). #### Response Example ```json { "payment_id": "pay_123abc456def", "status": "pending" } ``` ``` -------------------------------- ### POST /api/?method=create Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/sozdanie-platezha Endpoint for creating a new payment through the CactusPay API. Allows specifying payment details such as amount, order ID, and payment method. ```APIDOC ## POST /api/?method=create ### Description Endpoint for creating a new payment through the CactusPay API. Allows specifying payment details such as amount, order ID, and payment method. ### Method POST ### Endpoint https://lk.cactuspay.pro/api/?method=create ### Parameters #### Query Parameters - **method** (STRING) - Required - Specifies the payment method (e.g., card, sbp, yoomoney, crypto, nspk) #### Request Body - **token** (STRING) - Required - Your store's key, keep it secret - **order_id** (STRING) - Optional - Unique payment number in your system - **amount** (FLOAT) - Required - Payment amount - **description** (STRING) - Optional - Payment description - **h2h** (BOOL) - Optional - Enable h2h method - **user_ip** (STRING) - Optional - User's IP address for h2h method (Required when h2h is enabled) ### Request Example ```json { "token": "your_store_token", "order_id": "unique_order_123", "amount": 100.50, "description": "Test payment", "h2h": false, "user_ip": "192.168.1.1", "method": "card" } ``` ### Response #### Success Response (200) - **status** (STRING) - Indicates the status of the operation ('success' or 'error') - **response** (OBJECT) - Contains the details of the payment response - **url** (STRING) - The URL to redirect the user for payment - **requisite** (OBJECT) - Details related to payment requisites - **status** (STRING) - Status of the requisite details - **response** (OBJECT) - Specific response details for requisites - **until** (STRING) - Expiration date and time for the payment - **until_timestamp** (INTEGER) - Expiration timestamp for the payment - **amount** (FLOAT) - The amount of the payment - **receiverQR** (STRING) - QR code URL for payment - **order_id** (STRING) - The order ID associated with the payment #### Response Example ```json { "status": "success", "response": { "url": "https://pay.cactuspay.pro/2117529", "requisite": { "status": "success", "response": { "until": "Wed, 12 Feb 2025 22:50:52 +0300", "until_timestamp": 1739389852, "amount": 1625, "receiverQR": "https://qr.nspk.ru/AD20006HE9CEMV769MF8RA2HI4K9QD5B?type=02&bank=100000000123&sum=175500&cur=RUB&crc=ADE2", "order_id": "5b9a6715fe93a8a1cff1f64de4f5da" } } } } ``` ``` -------------------------------- ### Webhook API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api Configure webhook endpoints to receive real-time notifications about payment events and status changes. ```APIDOC ## POST /dobro-pozhalovat/api/webhook.md ### Description API endpoint for configuring webhook endpoints to receive real-time notifications. ### Method POST ### Endpoint /dobro-pozhalovat/api/webhook.md ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **url** (string) - Required - The URL to which webhook notifications will be sent. - **event_types** (array) - Optional - A list of event types to subscribe to (e.g., ['payment.succeeded', 'payment.failed']). If not provided, all events are sent. ### Request Example ```json { "url": "https://your-domain.com/webhook-handler", "event_types": ["payment.succeeded", "payment.failed"] } ``` ### Response #### Success Response (200) - **message** (string) - Confirmation message indicating the webhook has been configured. #### Response Example ```json { "message": "Webhook configured successfully." } ``` ``` -------------------------------- ### Payment Dispute Creation API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api Endpoint to create a dispute for an existing payment. This is used when a customer contests a transaction. ```APIDOC ## POST /dobro-pozhalovat/api/sozdanie-spora-po-platezhu.md ### Description API endpoint for creating a dispute for an existing payment. ### Method POST ### Endpoint /dobro-pozhalovat/api/sozdanie-spora-po-platezhu.md ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **payment_id** (string) - Required - The ID of the payment to dispute. - **reason** (string) - Required - The reason for the dispute. ### Request Example ```json { "payment_id": "pay_123abc456def", "reason": "Unauthorized transaction" } ``` ### Response #### Success Response (200) - **dispute_id** (string) - The unique identifier for the created dispute. - **status** (string) - The status of the dispute (e.g., 'open', 'closed'). #### Response Example ```json { "dispute_id": "disp_789ghi012jkl", "status": "open" } ``` ``` -------------------------------- ### Payment Information API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api Retrieve detailed information about a specific payment using its unique identifier. ```APIDOC ## GET /dobro-pozhalovat/api/informaciya-po-platezhu.md ### Description API endpoint to retrieve detailed information about a specific payment. ### Method GET ### Endpoint /dobro-pozhalovat/api/informaciya-po-platezhu.md ### Parameters #### Path Parameters None #### Query Parameters - **payment_id** (string) - Required - The ID of the payment to retrieve information for. #### Request Body None ### Request Example ``` GET /dobro-pozhalovat/api/informaciya-po-platezhu.md?payment_id=pay_123abc456def ``` ### Response #### Success Response (200) - **payment_id** (string) - The unique identifier for the payment. - **amount** (number) - The amount of the payment. - **currency** (string) - The currency of the payment. - **status** (string) - The current status of the payment. - **created_at** (string) - Timestamp when the payment was created. #### Response Example ```json { "payment_id": "pay_123abc456def", "amount": 100.50, "currency": "USD", "status": "completed", "created_at": "2023-10-27T10:00:00Z" } ``` ``` -------------------------------- ### POST /webhook Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/webhook This endpoint receives notifications about payment statuses. Upon successful payment, you will receive a webhook with payment details. It is crucial to verify the payment status by sending a subsequent request to the provided API endpoint. ```APIDOC ## POST /webhook ### Description Receives notifications for payment status updates. You will be notified upon successful payment completion. ### Method POST ### Endpoint /webhook ### Parameters #### Request Body - **id** (STRING) - Required - Unique payment identifier in the CactusPay system. - **order_id** (STRING) - Required - Unique payment identifier in your system. - **amount** (FLOAT) - Required - The amount of the payment. ### Request Example ``` id=pay_123abc&order_id=your_order_456&amount=100.50 ``` ### Response #### Success Response (200) This endpoint typically returns a 200 OK status to acknowledge receipt of the webhook. Specific response body details are not provided as the primary action is on your end to verify the payment. #### Response Example ``` OK ``` ### Further Information After receiving a webhook, it is recommended to verify the payment status by sending a request to: `https://lk.cactuspay.pro/api/?method=get` ``` -------------------------------- ### Payment Export API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api Endpoint for exporting payment data. Allows retrieval of historical payment records in a structured format. ```APIDOC ## GET /dobro-pozhalovat/api/eksport-platezhei.md ### Description API endpoint for exporting payment data. ### Method GET ### Endpoint /dobro-pozhalovat/api/eksport-platezhei.md ### Parameters #### Path Parameters None #### Query Parameters - **start_date** (string) - Optional - The start date for the export (YYYY-MM-DD). - **end_date** (string) - Optional - The end date for the export (YYYY-MM-DD). - **format** (string) - Optional - The desired export format (e.g., 'csv', 'json'). Defaults to 'csv'. ### Request Example ``` GET /dobro-pozhalovat/api/eksport-platezhei.md?start_date=2023-01-01&end_date=2023-12-31&format=csv ``` ### Response #### Success Response (200) - **data** (string) - The exported payment data in the requested format. #### Response Example ``` (CSV formatted data will be returned here) ``` ``` -------------------------------- ### POST /client/shop/export Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/eksport-platezhei Exports payment data based on the provided date range and shop token. Supports JSON request bodies. ```APIDOC ## POST /client/shop/export ### Description Exports payment data within a specified date range using a shop token. The request is made in JSON format. ### Method POST ### Endpoint https://lk.cactuspay.pro/client/shop/export ### Parameters #### Request Body - **token** (STRING) - Required - The shop's API key. - **dateFrom** (NUMBER / STRING) - Required - The start date for the export, can be in UNIX timestamp or ISO 8601 format. - **dateTo** (NUMBER / STRING) - Required - The end date for the export, can be in UNIX timestamp or ISO 8601 format. ### Request Example ```json { "token": "your_shop_token", "dateFrom": 1678886400, "dateTo": 1710422400 } ``` ### Response #### Success Response (200) - **status** (STRING) - Indicates the success of the operation ('success'). - **response** (OBJECT) - Contains the exported data and statistics. - **payments** (ARRAY) - A list of payment objects. - **id** (NUMBER) - Payment ID. - **type** (STRING) - Type of payment (ONE-TIME, MULTIPLY). - **orderId** (STRING) - Order ID. - **amount** (NUMBER) - Payment amount. - **profit** (NUMBER) - Payment profit. - **formattedDate** (STRING) - Formatted date of the payment. - **timestampDate** (NUMBER) - Timestamp of the payment. - **requisites** (STRING) - Payment requisites. - **rate** (NUMBER) - Exchange rate. - **status** (STRING) - Status of the payment (WAIT, ACCEPT). - **statistics** (OBJECT) - Summary statistics of the exported payments. - **totalAmount** (NUMBER) - Total amount of payments. - **totalProfit** (NUMBER) - Total profit from payments. - **totalCount** (NUMBER) - Total number of payments. #### Response Example ```json { "status": "success", "response": { "payments": [ { "id": 0, "type": "ONE-TIME", "orderId": "***", "amount": 0, "profit": 0, "formattedDate": "15.05.2025 15:57:34", "timestampDate": 1747313854, "requisites": "***", "rate": 94.304, "status": "WAIT" } ], "statistics": { "totalAmount": 0, "totalProfit": 0, "totalCount": 0 } } } ``` ``` -------------------------------- ### Payment Object Structure Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/eksport-platezhei This JSON structure represents a single payment record returned by the CactusPay API. It includes details such as payment ID, type, order ID, amount, profit, formatted date, timestamp, requisites, rate, and status. ```json { "id": 0, "type": "ONE-TIME", "orderId": "***", "amount": 0, "profit": 0, "formattedDate": "15.05.2025 15:57:34", "timestampDate": 1747313854, "requisites": "***", "rate": 94.304, "status": "WAIT" } ``` -------------------------------- ### Payment Export Response Structure Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/eksport-platezhei This JSON structure represents the overall response from the CactusPay payment export API. It includes a 'status' field, and a 'response' object containing an array of 'payments' and an object with 'statistics' for the exported period. ```json { "status": "success", "response": { "payments": [], "statistics": { "totalAmount": 0, "totalProfit": 0, "totalCount": 0 } } } ``` -------------------------------- ### Cancel Transaction Details API Request (JSON) Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/otmena-rekvizitov-tranzakcii-h2h This snippet demonstrates the structure of a JSON request to cancel transaction details via the CactusPay API. It requires a shop token and the unique order ID for the payment. ```json { "token": "YOUR_SHOP_TOKEN", "order_id": "YOUR_ORDER_ID" } ``` -------------------------------- ### CactusPay API Success Response (JSON) Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/otmena-rekvizitov-tranzakcii-h2h This snippet shows the expected JSON response from the CactusPay API upon successful cancellation of transaction details. It indicates a 'success' status. ```json { "status": "success" } ``` -------------------------------- ### Cancel H2H Transaction Details API Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api API to cancel requested H2H (Hand-to-Hand) transaction details before their expiration time. ```APIDOC ## POST /dobro-pozhalovat/api/otmena-rekvizitov-tranzakcii-h2h.md ### Description API to cancel requested H2H transaction details before their expiration time. ### Method POST ### Endpoint /dobro-pozhalovat/api/otmena-rekvizitov-tranzakcii-h2h.md ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **transaction_id** (string) - Required - The ID of the H2H transaction to cancel. ### Request Example ```json { "transaction_id": "h2h_tx_987zyx654wvu" } ``` ### Response #### Success Response (200) - **status** (string) - The status of the cancellation request (e.g., 'cancelled', 'failed'). #### Response Example ```json { "status": "cancelled" } ``` ``` -------------------------------- ### POST /api/?method=CANCEL_DETAILS Source: https://wiki.cactuspay.pro/dobro-pozhalovat/api/otmena-rekvizitov-tranzakcii-h2h Cancels the transaction details for a given order ID. Requires a valid store token. ```APIDOC ## POST /api/?method=CANCEL_DETAILS ### Description This endpoint allows you to cancel the transaction details associated with a specific order. ### Method POST ### Endpoint https://lk.cactuspay.pro/api/?method=CANCEL_DETAILS ### Parameters #### Request Body - **token** (STRING) - Required - The API key or token for your store. - **order_id** (STRING) - Required - The unique identifier for the transaction (payment) in your system. ### Request Example ```json { "token": "your_store_token", "order_id": "your_order_id" } ``` ### Response #### Success Response (200) - **status** (STRING) - Indicates the status of the cancellation request. Expected value is 'success'. #### Response Example ```json { "status": "success" } ``` ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.