Create a Consent
Create a consent on the Global Payments system to obtain authorization from the payer, allowing Global Payments to collect, use, and disclose their personal information to initiate the payment process.
Authorization
bearerAuth Access token from POST /accesstoken, sent as Authorization: Bearer <token>.
In: header
Header Parameters
The version of the API to execute the request.
1 <= length <= 50"2021-03-22"Request Body
application/json
A meaningful label that better identifies the GPAPI account.
1 <= length <= 50Describes whether the transaction was processed in a face to face(CP) scenario or a Customer Not Present (CNP) scenario.
"CNP"Value in
- "CP"
- "CNP"
A four-digit number used to classify the merchant into an industry or market segment.
1 <= length <= 50Merchant defined field to reference this consent request.
8 <= length <= 50Specifies the list of payment methods the merchant supports for the transaction
Response Body
application/json
curl -X POST "https://example.com/consents" \ -H "X-GP-Version: 2021-03-22" \ -H "Content-Type: application/json" \ -d '{ "account_name": "transaction_processing", "channel": "CNP", "reference": "becf9f3e-4d33-459c-8ed2-0c4affc9555e", "merchant_category_code": "String", "addresses": [ { "functions": [ "BUSINESS" ], "building_name": "Winners", "reference": "Clothing store", "line_1": " string", "line_2": "string", "line_3": "string", "city": "string", "state": "ON", "postal_code": "N1T 0G9", "country": "Canada", "po_box_number": "1234" } ], "order": { "reference": "James_order", "delivery_timeframe": "STANDARD", "shipping_type": "SINGLE", "shipping_cost": "600", "amount": "4100", "currency": "CAD", "tax_amount": "700", "items": [ { "label": "T-shit Red", "reference": "ORD-23455", "type": "OTHER", "amount": "1250", "quantity": "2", "description": "Red t-shirt Zango", "payment_type": "SINGLE" } ] }, "fees": [ { "name": "fast track fee", "amount": "200" }, { "name": "gift wrap fee", "amount": "100" } ], "payment_method": { "digital_wallet": { "provider": "KONEK" } }, "supported_payment_methods": [ "MASTERCARD_CREDIT", "MASTERCARD_DEBIT", "VISA_CREDIT", "VISA_DEBIT", "AMEX_CREDIT", "BANK_TRANSFER_SAVINGS", "BANK_TRANSFER_CHECKING", "BANK_TRANSFER_LINE_OF_CREDIT" ] }'{ "id": "CON_2ee5480308664428bef46d1094f22adc", "time_created": "2021-05-03T21:23:39.718Z", "status": "INITIATED", "merchant_id": "MER_A6A1EC44522F96630ABEA17A", "merchant_name": "ABC INDUSTRIES", "account_id": "TRA_86920f927028745yt34d077d88beb29b", "account_name": "transaction_processing", "reference": "becf9f3e-4d33-459c-8ed2-0c4affc9555e", "dba": "merchantname", "device": { "session_reference": "device_profile_session_id" }, "order": { "amount": "10000", "currency": "CAD", "tax_amount": "600", "item_amount": "6000" }, "payment_method": { "digital_wallet": { "provider": "KONEK", "reference": "2ee5480308664428bef46d1094f22adc", "provider_reference": "2ee54803086tyui4567d1094f22adc" } }, "action": { "id": "ACT_uzFr7t4VOqxdLDI44hHmXIjHtOOE8d", "type": "CONSENT_CREATE", "time_created": "2021-05-03T21:23:39.718Z", "result_code": "SUCCESS", "app_id": "uzFr7t4VOqxdLDI44hHmXIjHtOOE8d", "app_name": "my_lovely_app" }}Get Consents List GET
Get a list of Consents obtained previously with Global Payments using criteria passed in the query string. Page through the result set to access all records.
Get a Consent GET
Retrieve the details for a single consent that was created on the Global payments system during the checkout process.