Create Unified Issuance (GPR/Gift/Forex/Wallet) - v2
🌟 RECOMMENDED - Unified issuance endpoint for all product types and channels.
This is the recommended API for all new integrations. It provides a simplified, unified structure for Corporate, Branch, Forex, and Wallet issuance channels.
Key Features
- Single endpoint for all channels (Corporate, Branch, Forex, Wallet)
- Simplified structure with
accounts[]array for multi-kit support - Unified maker-checker workflow across all product types
- Product types: GPR, Gift, Forex, Wallet
- Issuance types: Single, Bulk
- Kit support: PRIMARY and BACKUP kits (BACKUP not supported for Gift)
Flow
- Submit issuance request → status =
CREATED - Maker-checker approval via state-transition → status =
APPROVED - System processes issuance → status =
SUCCESS(cards created) - Fetch by ID to get full response with card details
Request Structure
issuanceChannel: Corporate, Branch, Forex, Walletcustomer: Customer details withaccounts[]arrayaccounts[].product: Product config (productId, productType)accounts[].kits[]: Kit details (PRIMARY/BACKUP, embossingType, deliveryType)transaction: Fee and load amount summary
Response Structure
result.id: MongoDB ObjectId for state-transition and fetch operationsresult.currentStatus: CREATED → PENDING_APPROVAL → APPROVED → SUCCESSresult.customer.accounts[].entityId: Entity ID after provisioningresult.customer.accounts[].kits[].cardNumber: Masked card numberresult.customer.accounts[].kits[].encCardNumber: Encrypted card data
Server
Use the corporate server URLs for this endpoint.
📖 Integration Guide: Unified Issuance API - GPR & Gift
Authorization
bearerAuth tenantId JWT Bearer token from the Authentication API
In: header
Your unique tenant identifier assigned during onboarding
In: header
Header Parameters
Your unique tenant identifier
Request Body
multipart/form-data
JSON string containing the issuance request
Optional document uploads (passport, visa, etc.)
Response Body
application/json
application/json
application/json
curl -X POST "https://sandbox-api.m2pprepaid.com/prepaid/middleware/v2/issuances" \ -H "X-TENANT-ID: ACME_CORP" \ -F body="{\n \"applicationNumber\": \"897886\",\n \"issuanceChannel\": \"Corporate\",\n \"issuanceType\": \"Single\",\n \"noOfCardsRequested\": 2,\n \"customer\": {\n \"firstName\": \"Sachin\",\n \"lastName\": \"T\",\n \"email\": \"sachint@example.com\",\n \"mobile\": {\n \"value\": \"9876543210\",\n \"countryCode\": 91\n },\n \"customerType\": \"NTB\",\n \"kycLevel\": \"Full KYC\",\n \"accounts\": [\n {\n \"product\": {\n \"productId\": \"productid123\",\n \"productType\": \"GPR\"\n },\n \"kits\": [\n {\n \"kitType\": \"PRIMARY\",\n \"embossingType\": \"Perso\",\n \"cardType\": \"Physical\",\n \"nameOnCard\": \"Sachin T\"\n },\n {\n \"kitType\": \"BACKUP\",\n \"embossingType\": \"Perso\",\n \"cardType\": \"Physical\",\n \"nameOnCard\": \"Sachin T\"\n }\n ]\n }\n ]\n },\n \"transaction\": {\n \"summary\": {\n \"netValue\": 1.00,\n \"totalFees\": 20.0,\n \"totalTax\": 3.60,\n \"totalAmount\": 24.60\n }\n },\n \"issuer\": {\n \"hierarchyId\": \"qappregaprl7mddznsiw\"\n }\n}\n"{
"result": {
"id": "6a0431f65de0228d6be3575c",
"applicationNumber": "532470",
"currentStatus": "CREATED",
"issuanceChannel": "Corporate",
"issuanceType": "Single",
"noOfCards": 0,
"noOfCardsRequested": 1
},
"pagination": null
}{
"status": "FAILED",
"errorCode": "VALIDATION_ERROR",
"message": "applicationNumber is required"
}{
"status": "FAILED",
"errorCode": "DUPLICATE_APPLICATION",
"message": "An issuance with applicationNumber 532470 already exists"
}Approve/Reject Wallet Issuance POST
Approves or rejects a pending wallet issuance request as part of the maker-checker compliance workflow. ### Transitions | From Status | To Status | Description | |-------------|-----------|-------------| | `CREATED` | `APPROVED` | Checker approves the request | | `CREATED` | `REJECTED` | Checker rejects the request | | `PENDING_APPROVAL` | `APPROVED` | Checker approves | | `PENDING_APPROVAL` | `REJECTED` | Checker rejects | ### Invalid Transitions Attempting an invalid transition (e.g., approving an already rejected request) returns error code `PP_CORP_187`.
Fetch Unified Issuance by ID (v2) GET
Fetch complete issuance details by MongoDB ObjectId. Use this to get the full issuance record including card details after approval. ### Server Use the **corporate** server URLs for this endpoint.
