Skip to main content
POST
/
pg
/
subscriptions
Create UPI Subscription
curl --request POST \
  --url https://api-pacb-uat.eximpe.com/pg/subscriptions/ \
  --header 'Content-Type: application/json' \
  --header 'X-API-Version: <api-key>' \
  --header 'X-Client-ID: <api-key>' \
  --header 'X-Client-Secret: <api-key>' \
  --header 'X-Merchant-ID: <api-key>' \
  --data '
{
  "amount": "<string>",
  "currency": "<string>",
  "reference_id": "<string>",
  "buyer": {
    "name": "<string>",
    "email": "[email protected]",
    "phone": "<string>",
    "address": {
      "line_1": "<string>",
      "city": "<string>",
      "state": "<string>",
      "postal_code": "<string>",
      "line_2": "<string>"
    },
    "ip_address": "<string>",
    "user_agent": "<string>"
  },
  "product": {
    "name": "<string>",
    "type_of_goods": "physical_goods",
    "description": "<string>",
    "hs_code": "<string>",
    "hs_code_description": "<string>"
  },
  "return_url": "<string>",
  "collection_mode": "hosted_payment",
  "mop_type": "upi",
  "upi_flow_type": "intent",
  "invoice": {
    "number": "<string>",
    "date": "2023-12-25"
  },
  "card_details": {
    "number": "<string>",
    "cardholder_name": "<string>",
    "expiry_month": "<string>",
    "expiry_year": "<string>",
    "cvv": "<string>",
    "network": "visa",
    "identifier": "<string>",
    "nickname": "<string>"
  },
  "standing_instruction": {
    "billing_amount": "<string>",
    "billing_currency": "<string>",
    "billing_cycle": "<string>",
    "billing_interval": 123,
    "payment_start_date": "2023-12-25",
    "payment_end_date": "2023-12-25",
    "billing_date": 123,
    "billing_limit": "<string>",
    "billing_rule": "<string>",
    "remarks": "<string>",
    "status": "<string>"
  }
}
'
{
  "success": true,
  "message": "<string>",
  "data": {
    "order_id": "<string>",
    "subscription_type": "<string>",
    "intent_uri": "<string>",
    "acstemplate": "<string>",
    "subscription_id": "<string>",
    "subscription": {
      "billing_amount": "<string>",
      "billing_currency": "<string>",
      "billing_cycle": "<string>",
      "billing_interval": 123,
      "payment_start_date": "2023-12-25",
      "payment_end_date": "2023-12-25",
      "billing_date": 123,
      "billing_limit": "<string>",
      "billing_rule": "<string>",
      "remarks": "<string>",
      "status": "<string>"
    }
  }
}

Authorizations

X-Client-ID
string
header
required

Client Application ID - Your unique application identifier used to authenticate API requests. You can find your Client ID in the Developer Settings section of the merchant dashboard.

X-Client-Secret
string
header
required

Client Secret Key - Your secret key used alongside the Client ID for secure authentication. Keep this confidential and never expose it in client-side code. Available in the Developer Settings section of the merchant dashboard.

X-Merchant-ID
string
header
required

Merchant Identifier - The unique ID for the merchant account. This is required for PSP (Payment Service Provider) merchants who manage multiple merchant accounts. You can find merchant IDs in the Merchant Management section of the dashboard.

X-API-Version
string
header
required

API Version - Specifies which version of the API to use (e.g., '1.X.X' or '2.X.X'). This header allows you to control which API version your integration uses. Default version information is available in the Developer Settings.

Body

application/json

Subscription creation request. Accepts the same fields as Create Order (S2S UPI) plus a standing_instruction block.

amount
string
required

Amount in decimal format (e.g., "100.00")

currency
string
required

3-letter ISO currency code (e.g., INR, USD)

reference_id
string
required

Unique identifier for the order

buyer
object
required
product
object
required
return_url
string<uri>

URL to redirect after payment

collection_mode
enum<string>

Payment collection mode

Available options:
hosted_payment,
s2s
mop_type
enum<string>

Method of payment type (e.g., UPI)

Available options:
upi,
credit_card,
net_banking,
debit_card,
qr
upi_flow_type
enum<string>

UPI flow type (required when collection_mode is s2s and mop_type is UPI)

Available options:
intent,
collection
invoice
object
card_details
object
standing_instruction
object

Standing instruction configuration for a subscription

Response

UPI Subscription created successfully

success
boolean
required
message
string
required
data
object
required