Creating an order
The method for creating an order
For this method, we require the implementation of all the fields listed in the table, as they make up the entirety of the InPost Pay service. Some of the following fields in the 'Required' column are marked as 'O', i.e. optional, due to the fact that not all products/baskets in online stores have all parameters assigned, so a basket can be created and an order placed without them. However, the implementation/deployment of all fields is REQUIRED from a business perspective.
POST /v1/izi/order
Parameters - none
Request
Field name | Description | Type | Requirement status | Additional remarks |
| The data for creating an order | object | Y |
|
| Additional information about an order | string | O |
|
| Identifier of the basket assigned by the Merchant based on which the order is to be created | string | Y |
|
| Currency. Currently, only PLN | string | Y |
|
| The total estimated value of the basket along with the delivery costs | object | Y |
|
| Net | number ($decimal) | Y |
|
| Gross | number ($decimal) | Y | |
| VAT | number ($decimal) | Y | |
| The payment form chosen by the user. Enum forms available: [ CARD, CARD_TOKEN, GOOGLE_PAY, APPLE_PAY, BLIK_CODE, BLIK_TOKEN, PAY_BY_LINK, SHOPPING_LIMIT, DEFERRED_PAYMENT, CASH_ON_DELIVERY ] | string | Y |
|
| An object used to pass additional basket parameters that are saved in the basket details during basket creation/update. The Merchant can use this object, for example, to save parameters that will enable identification/association of the basket with a campaign. Additional parameters are not displayed in the application. | array | O |
|
| Key | string | Y |
|
| Value | string | Y |
|
| Information about the account used | object | Y |
|
| First name | string | Y |
|
| Last name | string | Y |
|
| Telephone number | object | Y |
|
| Prefix | string | Y |
|
| User's phone number | string | Y | |
| If the user logs in to InPost Pay with the use of Apple, the e-mail address of the account includes the hash assigned by Apple, and has the form of, for instance, abc@privaterelay.appleid.com. For the Merchant to communicate with the customers using this address, the Merchant's domain must be added on the InPost account in Apple. Apple limits the number of domains assigned to an account down to 100. Hence, InPost transfers the e-mail address abc@mail.inpostpay.pl to the Merchant with the same hash, but in the mail.inpostpay.pl domain. | string | Y |
|
| User's address | object | Y |
|
| Country code | string | Y |
|
| Address | string | Y | |
| City | string | Y | |
| Postal code | string | Y | |
| An object for transferring an unparsed address | object | O | |
| Street | string | O | |
| Building number | string | O | |
| Apartment number | string | O | |
| Invoice data | object | O |
|
| Legal form Enum: [PERSON, COMPANY] | string | O |
|
| Country code | string | O | |
| Id prefix | string | O | |
| tax identifier | string | O | |
| Company name | string | O | |
| First name | string | O | |
| Last name | string | O | |
| City | string | O | |
| Street | string | O | |
| Building number | string | O | |
| Apartment number | string | O | |
| Postal code | string | O | |
| string | O | ||
| Registration date | string | O | |
| Additional information | string | O | |
| Delivery Information | object | Y |
|
| Delivery method. Enum:[ APM, COURIER,DIGITAL ]. APM – parcel locker device, COURIER – Inpost courier, DIGITAL – digital delivery | string | Y |
|
| Selected delivery options - list | array | O |
|
| If the user logs in to InPost Pay with the use of Apple, the e-mail address of the account includes the hash assigned by Apple, and has the form of, for instance, abc@privaterelay.appleid.com. For the Merchant to communicate with the customers using this address, the Merchant's domain must be added on the InPost account in Apple. Apple limits the number of domains assigned to an account down to 100. Hence, InPost transfers the e-mail address abc@mail.inpostpay.pl to the Merchant with the same hash, but in the mail.inpostpay.pl domain. | string | O |
|
| The email address to which the digital product should be sent | string | O |
|
| Telephone number | object | O |
|
| Prefix | string | Y |
|
| Number | string | Y | |
| Automatic parcel locker delivery site | string | O |
|
| Delivery address | object | O |
|
| Name | string | Y |
|
| Country code | string | O |
|
| Address | string | Y |
|
| City | string | Y |
|
| Postal code | string | Y |
|
| Unparsed address | object | O |
|
| Street | string | O |
|
| Building number | string | O | |
| Premises number | string | O | |
| Notes for the courier | string | O |
|
| An object intended to transfer information related to the consents expressed by the customer for a given order | array | Y |
|
| consent Id | string | Y |
|
| Consent version | string | O |
|
| Info, whether or not the consent has been expressed | boolean | Y |
|
Response
Field name | Description | Type | Requirement status | Additional remarks |
| Order details | object | Y |
|
| Comments about the order | string | O |
|
| Order ID assigned by the Merchant | string | Y |
|
| Order ID presented to the customer and used for payment. If missing, the order_id is used | string | O |
|
| POS id | string | Y |
|
| Date when the order was created | string($date-time) | Y |
|
| Basket ID on the basis of which the order was created | string | Y |
|
| Selected payment method. Enum: [ CARD, CARD_TOKEN, GOOGLE_PAY, APPLE_PAY, BLIK_CODE, BLIK_TOKEN, PAY_BY_LINK, SHOPPING_LIMIT, DEFERRED_PAYMENT, CASH_ON_DELIVERY ] | string | Y |
|
| Descriptive status presented to the customer in the InPost Pay app - each Merchant can transfer the status so that the statuses presented in InPost Mobile are consistent with the statuses presented to the customer in the Merchant's store. | string | Y |
|
| Price for the order excluding delivery costs | object | Y |
|
| Net | number ($decimal) | Y |
|
| Gross | number ($decimal) | Y | |
| VAT | number ($decimal) | Y | |
| Price per order including delivery costs | object | Y |
|
| Net | number ($decimal) | Y |
|
| Gross | number ($decimal) | Y | |
| VAT | number ($decimal) | Y | |
| Value of discount codes applied to the order | number($decimal) | Y |
|
| Order currency (currently only PLN) | string | Y |
|
| List of assigned order shipment numbers | array | O |
|
| An object used to pass additional order parameters that are saved in order details. Merchant can use the object, for example, to save parameters that will allow to identify/link the order to the campaign. The additional parameters are not presented in the application. | array | O |
|
| Key | string | Y |
|
| Value | string | Y |
|
| User account information | object | Y |
|
| First name | string |