configure()
The configure function is used to prepare the Checkout library for a payment. It must be called before either showEmbeddedPage() or showPaymentPage() to store payment details.
Usage
Checkout.configure(configuration);
Example
Checkout.configure({ session: { id: '<your_session_id>' } });
Arguments
The configuration object describes the merchant, customer, payment, and checkout appearance and behaviour. Fields in the object can contain literal values or a function that returns the value. Functions will be invoked before showing the payment interface.
Validation problems with the configuration object will be delivered to the error callback.
Details of the payer's billing address.
The payer's billing address.
The city portion of the address.
The name of the company associated with this address.
The 3 letter ISO standard alpha country code of the address.
The post code or zip code of the address.
The state or province of the address.
The first line of the address.
The second line of the address (if provided).
Information about any constraints that apply to this transaction.
Information about the customer, including their contact details.
The email address of the customer.
The payer's first name.
The payer's last or surname.
The contact person's mobile phone or cell phone number.
The phone number of the person to whom the order is being billed.
Information associated with the device's source of transaction.
The telephone number captured by ANI (Automatic Number Identification) when the customer calls to place the order.
The 2 digit ANI information identifier provided by the telephone company to indicate the call type, for example, cellular (61-63), toll free (24,25), etc.
The mobile phone manufacturer's identifier for the model of the mobile device used to initiate the payment.
Additional information about the external token repository you are configured with.
Provide the site code required to save card details against a token.
Information that controls the payer's checkout interaction.
The property ID for your shop site provided by Google Analytics in the form UA-XXXXX-Y.
A group of objects that control the visibility of, and payer-interaction with, displayed information.
Indicates if you require the payer to provide their billing address during the payment interaction.
HIDE
Hides data fields from the payer.MANDATORY
Displays data fields and allows the payer to enter data into these fields.OPTIONAL
Displays data fields and allows the payer to opt out of data entry for these fields.READ_ONLY
Data is displayed but cannot be modified.Indicates if you wish to display a 'Confirm Account Number' field for the ACH Account Number entry.
HIDE
Do not display confirm account number.SHOW
Display confirm account number.Indicates if you require the payer to provide their email address on the payment interaction.
HIDE
Hides data fields from the payer.MANDATORY
Displays data fields and allows the payer to enter data into these fields.OPTIONAL
Displays data fields and allows the payer to opt out of data entry for these fields.READ_ONLY
Data is displayed but cannot be modified.Indicates if you wish to display a summary of the order before the payer submits their payment.
HIDE
Do not display order summary.SHOW
Display order summary, which may include payment details.SHOW_PARTIAL
Display order summary which may not include payment details.Indicates if you want the payer to confirm the payment details before they submit the payment.
HIDE
Do not display payment confirmation.SHOW
Display payment confirmation.Indicates whether you wish to hide payment terms for a payment plan during the payment interaction.
HIDE
Hides the payment terms from the payer. Note that offering Plan AMEX in some regions may require you to inform the payer of the payment terms before processing the payment.SHOW_IF_SUPPORTED
Displays the payment terms, if available, to the payer.Indicates if you wish to hide the shipping details on the payment interaction.
HIDE
Hides data fields from the payer.READ_ONLY
Data is displayed but cannot be modified.A language identifier or IETF language tag to control the language of the payment interaction with the payer (e.g. en_US, es, fr-CA).
Information that allows you to display your brand and business details during the payment interaction.
Information on your business address.
The first line of your business address for display to the payer during the payment interaction.
The second line of your business address for display to the payer during the payment interaction.
The third line of your business address for display to the payer during the payment interaction.
The fourth line of your business address for display to the payer during the payment interaction.
The email address of your business for display to the payer during the payment interaction (e.g. an email address for customer service).
The URL of your business logo for display to the payer during the payment interaction.
The name of your business for display to the payer on the payment interaction.
The phone number of your business for display to the payer during the payment interaction.
The theme used to control the look and feel of your checkout interaction.
Your payment service provider might have configured your merchant profile to support several lines of business.
For example, lineOfBusiness = TICKET_SALES can have a different bank account from lineOfBusiness = MERCHANDISING. One line of business on your profile might be "null". To use that, do not provide the lineOfBusiness field.
The unique identifier issued to you by your payment provider.
Information about the order associated with this transaction.
A unique identifier for this order to distinguish it from any other order you create.
The total amount for the order.
The currency of the order expressed as an ISO 4217 alpha code, e.g. USD.
Information about this order that is of interest to you.
A note from the payer about this order.
The date the payer placed the order.
The payer's own reference for the order.
Short textual description of the contents of the order.
Information about the items the payer purchases with the order.
The brand of the item.
Your category for the item.
Description for the item with information such as size, color, etc.
Provide the industry category to send this line item to your acquirer for specialized processing as industry data.
(order.item.unitPrice + order.item.tax) * order.item.quantity
A short name describing the item.
The quantity of the item.
The SKU (Stock Keeping Unit) or the item identifier for this item.
The cost price for the item.
The tax amount for the item.
The total item amount for the order.
If you provide both this value and line item data, then the order.itemAmount MUST equal the total item amount.
Your identifier for the part of your organization that is responsible for the order.
Your reference to the contract or agreement you have with the payer to process recurring payments.
The identifier of the order.
The name of the person who requested the goods or services.
The total shipping and handling amount for the order.
Provide these parameters if you are a payment aggregator or facilitator and process payments on behalf of other merchants.
The sub-merchant's address.
The city portion of the address.
The name of the company associated with this address.
The 3 letter ISO standard alpha country code of the address.
The post code or zip code of the address.
The state or province of the address.
The first line of the address.
The second line of the address (if provided).
Code used by acquirer to describe the business or industry the sub-merchant operates in.
The sub-merchant's email address.
Your identifier for the sub-merchant.
The sub-merchant's phone number
The legal name of the sub-merchant.
The trading name of the sub merchant, also known as doing business as (DBA), operating as or trading as.
Use this parameter group to provide a breakdown of tax types, amount per tax type, and rate per tax type included in order.taxAmount.
The tax amount included in this order for the tax type.
The type of tax included in the order amount.
The total tax amount for the order.
If you provide both this value and line item data, then the order.taxAmount MUST equal the total tax amount.
Your tax registration identifier provided by the Federal/National tax authority (for example, federal tax identification number, ABN).
If, when integrating with the gateway, you are using a solution (e.g. a shopping cart or e-commerce solution) provided, supported or certified by your payment service provider, enter the solution ID issued by your payment service provider here.
Identifier of the payment session containing values for any of the request fields to be used in this operation.
Use this field to implement optimistic locking of the session content.
To use optimistic locking, record session.version when you make your decisions, and then pass that value in session.version when you submit your request operation to the gateway.
If session.version provided by you does not match that stored against the session, the gateway will reject the operation with error.cause=INVALID_REQUEST.
See Making Business Decisions Based on Session Content.
Information on the shipping address including the contact details of the addressee.
The address to which the goods contained in this order are being shipped.
The city portion of the address.
The name of the company associated with this address.
The 3 letter ISO standard alpha country code of the address.
The post code or zip code of the address.
The state or province of the address.
The first line of the address.
The second line of the address (if provided).
Details of the contact person at the address the goods will be shipped to.
The contact person's email address.
The first name of the person to whom the order is being shipped.
The last name or surname of the person to whom the order is being shipped.
The contact person's mobile phone or cell phone number.
The phone number of the person to whom the order is being shipped.
The shipping method code to indicate the time frame and the priority of the order.
ELECTRONIC
Electronic delivery.GROUND
Ground (4 or more days).OVERNIGHT
Overnight (next day).PRIORITY
Priority (2-3 days).SAME_DAY
Same day.Information about this transaction.
Additional information to be passed to acquirer.
Additional information requested by the acquirer which cannot be passed using other available data fields.
This is the value provided to the acquirer to identify the order.
Indicates the frequency of the transaction offered to the payer.
INSTALLMENT
Indicates an installment transaction where the payer authorizes you to deduct multiple payments over an agreed period of time for a single purchase.RECURRING
Indicates a recurring transaction where the payer authorizes you to automatically debit their accounts for bill or invoice payments.SINGLE
Indicates a single transaction where a single payment is used to complete the order.Your note about this transaction.
An optional identifier for this transaction.
The person who initiated this transaction.
Return Value
None