AlliancePay
🇬🇧 English
🇬🇧 English
  • E Commerce platform AlliancePay v2.32.0
  • Authentication
  • Data Encryption
  • Authorization
  • Using an authorization token
  • Key Management Overview
    • PURCHASE Collection Example
    • A2C Collection Example
  • Payment methods H2H
    • PURCHASE
      • PURCHASE Request - Step 1
      • PURCHASE Request - Step 2
    • A2C
    • C2A
      • C2A Transaction Request - Step 1
      • C2A Transaction Request - Step 2
    • ApplePay decrypted
      • PURCHASE
        • Payment Processing Request - Step 1
        • Payment Processing Request - Step 2 (3DS)
      • C2A
        • C2A request Step 1
        • C2A request Step 2 (3DS)
    • ApplePay encrypted
      • Request aPay support on the page
      • Request to receive aPay merchant data
      • Merchant validation request
      • Session Establishment Request in aPay
      • Payment Processing Request
    • GooglePay™ decrypted
      • PURCHASE
        • Payment Processing Request - Step 1
        • Payment Processing Request - Step 2 (3DS)
      • C2A
        • C2A request Step 1
        • C2A request Step 2 (3DS)
    • GooglePay™ encrypted
      • Google Pay™ Documentation
      • Google Pay™ Support Request on the Page
      • Google Pay™ Merchant Data Retrieval Request
      • Payment request
    • REFUND
    • TOKEN
      • PURCHASE
        • Token payment request Step 1
        • 3DS token payment request Step 2
      • C2A
        • Token payment request Step 1
        • 3DS token payment request Step 2
      • Token Creation
      • Retrieve Token by CustomerId
      • Retrieve Token Data
      • Update Token Status
      • Token Statuses
    • Account Verification
      • Card Verification Request Step 1
      • Card verification request Step 2
    • Getting data
      • By OPERATION_ID
      • By merchantRequestId
    • Getting a balance
    • Callback
  • Payment methods HPP
    • PURCHASE
      • Creating an order
      • Receiving order data
    • REFUND
    • Callback
    • Order statuses
  • Dictionary
    • Transaction status
    • Test cases
    • Error codes
    • Value actionCode, responseCode
    • Limits
    • Instructions for reconciliation by registers
      • Fields Description in Registers
    • Whitelist IP addresses and URLs
  • History of changes
Powered by GitBook
On this page
  • Input parameters:
  • Output parameters:
  • Example of a request body
  • Example of response body
  1. Payment methods HPP
  2. PURCHASE

Creating an order

{{url}}/ecom/execute_request/hpp/v1/create-order

Input parameters:

Parameter
Description
Data Format
Required
Example

merchantRequestId

A unique identifier generated by the merchant's system, used to retrieve the operation status in case of an unknown error or disconnection.

string(36)

Yes

137d9304-0368-11ed-b939-0242ac120002

merchantId

Merchant ID generated in Ecom.

string(36)

Yes

137d9304-0368-11ed-b939-0242ac120002

hppPayType

hpp payment type

string

Yes

Доступні значення -PURCHASE

coinAmount

order amount

long

Yes

2000

paymentMethods

payment methods

enum

Yes

Доступні значення - CARD, APPLE_PAY

language

payment widget language. ISO 639-1 2 digits

string (50)

No

Доступні значення - uk

notificationUrl

The URL to which the CallBack will be sent.

string(1000)

No

https://merchant.notification_url

notificationEncryption

Indicates whether CallBack data is encrypted.

string

No

true/false If not provided or set to false, CallBack data will be unencrypted.

successUrl

url, for redirection to the merchant's website upon successful status

string (1000)

Yes

failUrl

url, for redirection to the merchant's website in case of unsuccessful status

string (1000)

Yes

statusPageType

status page type

enum

Yes

доступні значення - statusPage

purpose

Payment purpose provided by the merchant.

string(255)

No

For goods

merchantComment

Additional information or comments from the merchant regarding the order.

string(255) a-zA-Z0-9 ,.;:@#$%'-=+1,256$

No

merchant Comment id 1258728c1

customerData

Object containing customer details.

object

Yes

-

senderCustomerId

Sender's customer ID.

string(255)

Yes

1258728c1

senderFirstName

Sender's first name.

string(30)

  • the value cannot contain only numbers

  • cannot contain periods or other special characters

  • cannot contain “NULL”, “3D SECURE”, “SURNAME”, “CARDHOLDER”, ”UNKNOWN”

  • only alphanumeric values ​​are allowed

  • can accept a space and a hyphen, but can NOT consist exclusively of “ ” or “-“

  • a hyphen or space can be inside, but not at the beginning or end

  • For the apostrophe character, use the only available utf8 character - ' which in: utf 16 - u0027 utf32 - 00000027

No

Ivanenko

senderLastName

Sender's last name.

string(30)

  • the value cannot contain only numbers

  • cannot contain periods or other special characters

  • cannot contain “NULL”, “3D SECURE”, “SURNAME”, “CARDHOLDER”, ”UNKNOWN”

  • only alphanumeric values ​​are allowed

  • can accept a space and a hyphen, but can NOT consist exclusively of “ ” or “-“

  • a hyphen or space can be inside, but not at the beginning or end

  • For the apostrophe character, use the only available utf8 character - ' which in: utf 16 - u0027 utf32 - 00000027

No

Ivan

senderMiddleName

Sender's middle name.

string(30)

  • the value cannot contain only numbers

  • cannot contain periods or other special characters

  • cannot contain “NULL”, “3D SECURE”, “SURNAME”, “CARDHOLDER”, ”UNKNOWN”

  • only alphanumeric values ​​are allowed

  • can accept a space and a hyphen, but can NOT consist exclusively of “ ” or “-“

  • a hyphen or space can be inside, but not at the beginning or end

  • For the apostrophe character, use the only available utf8 character - ' which in: utf 16 - u0027 utf32 - 00000027

No

Ivanovich

senderEmail

Sender's email.

string(256)

No

mail@gmail.com

senderCountry

Sender's country code.

string(3) (ISO 3166, e.g., 804 for Ukraine)

No

804

senderRegion

Sender's region.

string(255)

No

Kyivska

senderCity

Sender's city.

string(25)

No

Kyiv

senderStreet

Sender's street.

string(35)

No

Sichovykh Striltsiv

senderAdditionalAddress

Additional sender address details (floor, house number, apartment).

string(255)

No

23

senderItn

Sender's tax identification number.

string(20)

No

1,2E+08

senderPassport

Sender's passport number.

string(255)

No

AN123456

senderIp

Sender's IP address.

string(50)

No

123.12.12.12

senderPhone

Sender's phone number.

string(20)

No

3,8E+11

senderBirthday

Sender's date of birth.

string(50)

No

#######

senderGender

Sender's gender.

string(50)

No

Male

senderZipCode

Sender's postal code.

string(50)

No

49000

Output parameters:

Parameter
Description
Data Format
Example

hppOrderId

HPP order id

string

37d9304-0368-11ed-b939-0242ac120002

merchantRequestId

unique request identifier from the merchant

string

64d9304-0368-11ed-b939-0242ac1221458

hppPayType

HPP payment type

string

PURCHASE

paymentMethods

payment methods

enum

CARD

orderStatus

order status

string

SUCCESS, FAIL, PENDING, REQUIRED_3DS, CANCELED, PARTIAL_REFUND

coinAmount

order amount

long

2000

merchantId

Merchant ID generated in Ekom

string

37d9304-0368-11ed-b939-0242ac120002

expiredOrderDate

date and time of order validity

string

2024-09-05 18:35:18.210+03:00

redirectUrl

link to redirect the customer to the payment page

string

createDate

date and time of order creation

string

2024-09-05 18:35:18.210+03:00

statusUrl

url to redirect to the status page

string

Example of a request body

{
    "merchantId": "137d9304-0368-11ed-b939-0242ac120002",
    "hppPayType": "PURCHASE",
    "failUrl": "https://example.com/fail",
    "successUrl": "https://example.com/success",
    "merchantRequestId": "137d9304-0368-11ed-b939-0241ac220104",
    "statusPageType": "STATUS_PAGE",
    "paymentMethods": [
        "CARD"
    ],
    "customerData": {
        "senderCustomerId": "Id ",
        "senderEmail": "aaaa@gmail.com",
        "senderMiddleName": "s",
        "senderRegion": "senderRegion",
        "senderCountry": "804",
        "senderAdditionalAddress": "senderAdditionalAddress",
        "senderStreet": "senderStret",
        "senderCity": "senderCity",
        "senderIp": "255.255.244.255",
        "senderBirthday": "22081989",
        "senderGender": "Female",
        "senderZipCode": "12345",
        "senderPassport": "passport",
        "senderItn": "5555557777",
        "senderPhone": "380957388888"
    },
    "coinAmount": 1000,
    "purpose": "Payment for Order №123456",
    "language": "uk",
    "notificationUrl": "https://example.com/notify"
}

Example of response body

{
    "coinAmount": 1000,
    "merchantId": "137d9304-0368-11ed-b939-0242ac120002",
    "statusUrl": "http://pgi-status-ecom-release.develop.bankalliance.ua/?hpp_id=1728551936236-DAfCP7wrKT",
    "hppOrderId": "1728551936236-DAfCP7wrKT",
    "redirectUrl": "http://pgi-ecom-release.develop.bankalliance.ua/?hpp_id=1728551936236-DAfCP7wrKT",
    "hppPayType": "PURCHASE",
    "merchantRequestId": "137d9304-0368-11ed-b939-0241ac220104",
    "orderStatus": "PENDING",
    "paymentMethods": [
        "CARD"
    ],
    "createDate": "2024-10-10 12:18:56.19+03:00",
    "expiredOrderDate": "2024-10-10 12:33:56.23+03:00"
}
PreviousPURCHASENextReceiving order data

Last updated 2 months ago

​https://example.com/success​
​https://example.com/fail​
​http://pgi-status-ecom-release.develop.bankalliance.ua/?hpp_id=1728551936236-DAfCP7wrKT​
​http://pgi-status-ecom-release.develop.bankalliance.ua/?hpp_id=1728551936236-DAfCP7wrKT​