Authorize Payment (Apple Pay)

POST/api/pay/v1/orders/{order_id}/payments/{payments_id}/authorize

Use this API to authorize payments initiated through Apple Pay.

Note: You can use this API only if you are decrypting the Apple Pay payment token on your end using the Apple Pay JS SDK.

Requires Bearer token. Get token →

Path Parameters

NameTypeDescription
order_id
stringrequired

Unique identifier of the order in the Pine Labs Online database.

payments_id
stringrequired

Unique identifier of the payment in the Pine Labs Online database. Maximum length: 50 characters.

Request Body

NameTypeDescription
decrypted_card_details
object

An object that contains the decrypted card details.

token
stringrequired

Unique identifier of the card as per the token transaction type. Supported characters: A-Z, a-z, 0-9, . / \ - _ , ( ) '

expiration_month
stringrequired

Card token expiry month. Must be 2 digits.

expiration_year
stringrequired

Card token expiry year. Must be 4 digits.

cryptogram
stringrequired

Unique encrypted text from the Apple Pay token.

cavv
string

Unique encrypted text. Mandatory for Mastercard.

eci
string

Indicates the authentication outcome for the transaction.

card_meta_data
object

An object that contains additional card meta details.

Response

NameTypeDescription
data
object
order_id
string
merchant_order_reference
string
type
CHARGE | REFUND
CHARGEREFUND
status
CREATED | PENDING | PROCESSED | AUTHORIZED | CANCELLED | ATTEMPTED | FAILED | FULLY_REFUNDED | PARTIALLY_REFUNDED
CREATEDPENDINGPROCESSEDAUTHORIZEDCANCELLEDATTEMPTEDFAILEDFULLY_REFUNDEDPARTIALLY_REFUNDED
callback_url
string
failure_callback_url
string
merchant_id
string
order_amount
object
pre_auth
boolean
part_payment
boolean

Whether the transaction is a part payment.

allowed_payment_methods
string[]
purchase_details
object
payments
object[]
created_at
string
updated_at
string
integration_mode
SEAMLESS | REDIRECT
SEAMLESSREDIRECT

Status Codes

200Payment authorized successfully.
400
401
404
422Unprocessable Entity — invalid card details or authorization failed.
500
Request
curl --request POST \
  --url https://pluraluat.v2.pinepg.in/api/pay/v1/orders/v1-4405071524-aa-qlAtAf/payments/v1-5206071124-aa-mpLhF3-cc-l/authorize \
  --header 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  --header 'Content-Type: application/json' \
  --data '{
  "decrypted_card_details": {
    "token": "4111111111111111",
    "expiration_month": "12",
    "expiration_year": "2031",
    "cryptogram": "AceY+igABPs3jdwNaDg3MAACAAA=",
    "cavv": "AceY+igABPs3jdwNaDg3MAACAAA=",
    "eci": "05",
    "card_meta_data": {
      "card_type": "DEBIT",
      "network_name": "VISA"
    }
  }
}'

Run this request

order_id
payments_id
200 OK
{
  "data": {
    "order_id": "v1-251012055723-aa-Vhv53a",
    "merchant_order_reference": "3fb59787-c38b-4986-87da-39be0a585fae",
    "type": "CHARGE",
    "status": "PROCESSED",
    "callback_url": "https://simple-callback.onrender.com/payment/callback",
    "failure_callback_url": "",
    "merchant_id": "106974",
    "order_amount": {
      "value": 10000,
      "currency": "INR"
    },
    "pre_auth": false,
    "part_payment": false,
    "allowed_payment_methods": [
      "CARD",
      "WALLET"
    ],
    "purchase_details": {
      "customer": {
        "billing_address": {
          "address1": "10 Downing Street Westminster London",
          "address2": "Oxford Street Westminster London",
          "address3": "Baker Street Westminster London",
          "pincode": "51524036",
          "city": "Westminster",
          "state": "Westminster",
          "country": "London",
          "full_name": "Kevin Bob",
          "adddress_type": "Home",
          "address_category": "billing"
        },
        "shipping_address": {
          "address1": "10 Downing Street Westminster London",
          "address2": "Oxford Street Westminster London",
          "address3": "Baker Street Westminster London",
          "pincode": "51524036",
          "city": "Westminster",
          "state": "Westminster",
          "country": "London",
          "full_name": "Kevin Bob",
          "adddress_type": "Home",
          "address_category": "billing"
        }
      },
      "merchant_metadata": {
        "clientId": "DD",
        "transactionReferenceNo": "pine-1223",
        "merchantId": "1234",
        "tid": "9000990",
        "acquirerName": "HDFC_FSS",
        "isOfferDisplayRequired": "true",
        "OfferData": "UHJvZHVjdF9Db2RlPSIgIiZQcm9kdWN0X05hbWU9IiImUGF5bWVudF9Nb2RlPUJhbmsgRU1JJkNhcmRfVHlwZT1EZWJpdCBDYXJkJkJhbmtfTmFtZT1IREZDIERlYml0JkVNSV9UZW51cmU9NiZJbnRlcmVzdF9SYXRlPTkuMCZJbnRlcmVzdF9BbW91bnQ9MTM4MTQwJk1vbnRobHlfSW5zdGFsbG1lbnQ9ODk0NjkwJkF1dGhvcml6YXRpb25fQW1vdW50PTEwMCZMb2FuX2Jvb2tpbmdfQW1vdW50PTUyMzAwMDAmSW50ZXJlc3RfQ2FzaGJhY2tfQW1vdW50PTAmSW50ZXJlc3RfQ2FzaGJhY2tfVHlwZT1EZWZlcnJlZCZBZGRpdGlvbmFsX0Nhc2hiYWNrPSIiJkFkZGl0aW9uYWxfQ2FzaGJhY2tfVHlwZT0iIiZEZXNjcmlwdGlvbj1CYW5rIEVNSSZQcm9kdWN0X1ZhbHVlPTUyMzAwMDA",
        "tenant_id": "PGATPOS",
        "is_offer_validation_required": "true"
      }
    },
    "payments": [
      {
        "status": "PENDING",
        "payment_method": "CARD",
        "payment_option": {
          "wallet_details": {
            "wallet_code": "APPLE_PAY",
            "wallet_card_data": {
              "card_type": "DEBIT",
              "token_txn_type": "ALT_TOKEN"
            }
          }
        }
      }
    ],
    "created_at": "2025-06-04T11:00:51.067Z",
    "updated_at": "2025-06-04T11:01:26.656Z",
    "integration_mode": "SEAMLESS"
  }
}
New chat
Responses are generated using AI and may contain mistakes.
Hi! I'm Pine, your AI developer assistant. Ask me anything about Pine Labs APIs, integrations, or troubleshooting.

Tip: you can create a new chat with ⌘ + E