Skip to content
ZytePedevelopersDashboard
DocsAPI reference
API reference

Initiate Payout

Creates a payout/disbursement request from the merchant wallet or payout deposit balance.

POST/api/v1/payouts/external/initiateMerchant HMAC
Use your enabled merchant account. Examples run on your server, never in this documentation.

Payout requests can move real funds. Confirm merchant enablement and business approval before sending an instruction. This page does not execute requests.

Authentication

Use merchant HMAC headers and sign the exact path, query and raw body.

See authentication.

Workflow notes

  • Idempotency-Key must be at least 16 characters long.
  • If the same Idempotency-Key is replayed for the same merchant, ZytePe returns the original payout transaction instead of creating a new one.

Before you send

Check the field labels and use your enabled merchant account. Examples illustrate the API contract; confirm deployment-specific limits and error handling before launch. This page never sends a request.

Request example

Choose Node.js, Python, PHP, Ruby, Java or cURL. Run signed requests on your backend. PHP, Ruby and Java include signing directly. Java requires JDK 17 or newer.

import { signedHeaders } from './signing.mjs';
const path = `/api/v1/payouts/external/initiate`;
const query = '';
const payload = {
  "payee_id": "d965aa45-1952-4749-aa52-2bed21470ffd",
  "amount": 1500,
  "currency": "INR",
  "external_ref": "PAYOUT-2026-00041",
  "payout_method": "IMPS",
  "purpose": "Vendor settlement",
  "custom_notes": {
    "invoice_no": "INV-882",
    "batch": "MAY-SETTLEMENT"
  }
};
const body = JSON.stringify(payload);
const headers = signedHeaders({
  method: 'POST', path, query, body,
  keyId: process.env.ZYTEPE_API_KEY_ID,
  secret: process.env.ZYTEPE_API_SECRET,
});
// Save this key before sending; reuse it for the same payment retry.
const idempotencyKey = process.env.ZYTEPE_IDEMPOTENCY_KEY;
if (!idempotencyKey || idempotencyKey.length < 16) throw new Error('Set a saved idempotency key of at least 16 characters');
headers['Idempotency-Key'] = idempotencyKey;
headers['Content-Type'] = 'application/json';
const url = 'https://api.zytepe.com' + path + (query ? '?' + query : '');
const response = await fetch(url, { method: 'POST', headers, body });
if (!response.ok) throw new Error('Request failed: HTTP ' + response.status);
const result = await response.json();
// Store the returned identifiers securely. Do not log customer data.

Request fields

Optional fields can be omitted. Conditional fields depend on the payment method. Labels reflect the reviewed API schemas and handler checks.

payee_idRequired

The saved and verified payee identifier.

amountRequired

Payment amount in the documented currency.

external_refRequired

Your unique business payout reference.

currencyOptional

Defaults to INR.

payout_methodOptional

Defaults to IMPS. Verify the payee for your chosen method.

purposeOptional

Business reason for the payout.

custom_notesOptional

Additional business context.

Path, query and headers

Idempotency-KeyRequiredheader

Required. Reuse the same key for retries of the same payout.

Request body

JSON · request.json
{
  "payee_id": "d965aa45-1952-4749-aa52-2bed21470ffd",
  "amount": 1500,
  "currency": "INR",
  "external_ref": "PAYOUT-2026-00041",
  "payout_method": "IMPS",
  "purpose": "Vendor settlement",
  "custom_notes": {
    "invoice_no": "INV-882",
    "batch": "MAY-SETTLEMENT"
  }
}

Example response

JSON · response
{
  "success": true,
  "message": "Payout initiated successfully.",
  "data": {
    "message": "Payout initiated successfully.",
    "transaction_id": "ca9a58aa-d578-4fc2-a9f4-fb8d090d4b5f",
    "status": "processing"
  }
}