Assess a payment
/risk/assessmentsAssesses the risk of a payment and returns the recommended outcome. Available only to accounts with Standalone Risk enabled; other accounts get 403.
The assessment cannot be retrieved later, so store the response.
Headers
AuthorizationstringRequiredidempotency-keystringA unique key, such as a UUID, that makes a POST or DELETE request safe to retry. Pay.com keeps each key for 24 hours, separately for each workspace.
- A retry with the same key, endpoint and body gets the first request's stored status and body, without running the request again.
- If the first request is still being processed, a retry gets 409
idempotency_error(request_in_progress). - The same key on another endpoint, or with another body, gets 400
idempotency_error(invalid_parameters). - GET, PUT and PATCH requests ignore the key.
The response repeats the key in its Idempotency-Key header.
Parameters
risk_session_idstringRequiredA unique identifier for the risk session.
amountintegerRequiredAmount to assess, in the smallest currency unit.
currencystringRequiredThree-letter ISO currency code, in lowercase.
shippingobjectShipping information of the payment.
Show 3 child parametersHide child parameters
addressobjectAddress details.
Show 6 child parametersHide child parameters
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
namestringFull name of the recipient.
phonestringPhone number of the recipient, preferably in E.164 format. The leading + is optional.
source_dataobjectObject providing the raw details of the payment method. Mutually exclusive with payment_method_data. Exactly one of the two must be provided.
Show 8 child parametersHide child parameters
typestringRequiredThe type of the payment method to be used as the source for the payment. Most types need an object with the same name as the type (for example card, token, source, network_token, googlepay, applepay, us_bank_account, ideal, volt, netbanking, blik_one_click or the t365_* types); the other types are redirect-based alternative payment methods that only need billing_details.
applepay is converted to a card payment before it is processed. Raw in_bank_account, au_bank_account, nz_bank_account, eu_bank_account and uk_bank_account details are not supported on charges and holds.
billing_detailsobjectBilling information for the payment.
Show 11 child parametersHide child parameters
addressobjectAddress details.
Show 6 child parametersHide child parameters
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
namestringFull name of the billing contact.
emailstringEmail address of the billing contact.
phonestringPhone number of the billing contact, preferably in E.164 format. The leading + is optional, and an empty string is accepted.
dobstringDate of birth in YYYY-MM-DD format.
national_identification_numberstringNational identification number of the billing contact.
ip_addressstringIP address (IPv4 or IPv6) of the customer. Used for tax calculation when no address is available.
tax_idsarray of objectsTax identifiers of the customer. Used for tax calculation.
Show 2 child parametersHide child parameters
typestringRequiredType of the tax identifier. One of eu_vat, gb_vat, us_ein, ca_gst_hst, ca_bn, au_abn, in_gst, or pl_nip.
valuestringRequiredValue of the tax identifier.
kyc_datestringTime at which the customer's KYC check was completed, in ISO 8601 format.
screening_datestringTime at which the customer was last screened, in ISO 8601 format.
signature_datestringTime at which the customer signed the agreement, in ISO 8601 format.
cardobjectRaw details of a card. Requires an API key enabled for raw card data (PCI). 3D Secure results (three_ds, three_ri) are not accepted.
Show 7 child parametersHide child parameters
numberstringRequiredThe card number, as a string without any separators.
expiry_monthstringRequiredTwo-digit number representing the card's expiration month.
expiry_yearstringRequiredTwo or four-digit number representing the card's expiration year.
cvvstringCard security code. cvc is accepted as an alias.
namestringCardholder's full name.
billing_addressobjectBilling address of the card.
Show 6 child parametersHide child parameters
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
sourceobjectShow 2 child parametersHide child parameters
idstringRequiredUnique identifier for a stored payment method to assess.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
tokenobjectShow 3 child parametersHide child parameters
idstringRequiredA token that identifies the payment method in Pay.com's Tokenization Vault.
cvvstringCard security code.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
network_tokenobjectRaw network token details. 3D Secure results (three_ds, three_ri) are not accepted.
Show 7 child parametersHide child parameters
tokenstringRequiredThe network token (token PAN).
token_typestringRequiredOrigin of the network token. Use applepay or googlepay for a decrypted wallet token.
expiry_monthstringRequiredExpiry month of the token.
expiry_yearstringRequiredExpiry year of the token.
namestringCardholder's full name.
cryptogramstringCryptogram for the token.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
googlepayobjectGoogle Pay payment token, sent exactly as Google Pay returns it in paymentMethodData.tokenizationData.token (parsed from its JSON string). Field names keep Google's camelCase.
Show 5 child parametersHide child parameters
signaturestringRequiredSignature that verifies the message came from Google.
protocolVersionstringRequiredVersion of the Google Pay encryption protocol used to create the token.
signedMessagestringRequiredThe encrypted payment data and its metadata, as a serialized JSON string.
intermediateSigningKeyobjectRequiredIntermediate signing key from Google, used with protocolVersion ECv2.
Show 2 child parametersHide child parameters
signedKeystringRequiredThe intermediate signing key, as a serialized JSON string.
signaturesarray of stringsSignatures that verify the intermediate signing key came from Google.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
applepayobjectApple Pay payment token. Send the paymentData object of the PKPaymentToken exactly as Apple returns it (field names keep Apple's camelCase), and optionally the token's paymentMethod object.
Show 6 child parametersHide child parameters
signaturestringRequiredSignature of the payment and header data, as a Base64-encoded string.
versionstringRequiredVersion of the Apple Pay payment token.
datastringRequiredEncrypted payment data, as a Base64-encoded string.
headerobjectRequiredAdditional version-dependent information used to decrypt and verify the payment.
Show 3 child parametersHide child parameters
publicKeyHashstringRequiredHash of the X.509 encoded public key bytes of the merchant's certificate, as a Base64-encoded string.
ephemeralPublicKeystringRequiredEphemeral public key bytes, as a Base64-encoded string.
transactionIdstringRequiredTransaction identifier generated on the device, as a hexadecimal string.
paymentMethodobjectThe paymentMethod object of the Apple Pay token, if available.
Show 3 child parametersHide child parameters
displayNamestringDescription of the card, suitable for display.
networkstringPayment network of the card.
typestringType of the card.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
payment_method_dataobjectAlias for source_data. Mutually exclusive with source_data. Exactly one of the two must be provided.
Show 8 child parametersHide child parameters
typestringRequiredThe type of the payment method to be used as the source for the payment. Most types need an object with the same name as the type (for example card, token, source, network_token, googlepay, applepay, us_bank_account, ideal, volt, netbanking, blik_one_click or the t365_* types); the other types are redirect-based alternative payment methods that only need billing_details.
applepay is converted to a card payment before it is processed. Raw in_bank_account, au_bank_account, nz_bank_account, eu_bank_account and uk_bank_account details are not supported on charges and holds.
billing_detailsobjectBilling information for the payment.
Show 11 child parametersHide child parameters
addressobjectAddress details.
Show 6 child parametersHide child parameters
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
namestringFull name of the billing contact.
emailstringEmail address of the billing contact.
phonestringPhone number of the billing contact, preferably in E.164 format. The leading + is optional, and an empty string is accepted.
dobstringDate of birth in YYYY-MM-DD format.
national_identification_numberstringNational identification number of the billing contact.
ip_addressstringIP address (IPv4 or IPv6) of the customer. Used for tax calculation when no address is available.
tax_idsarray of objectsTax identifiers of the customer. Used for tax calculation.
Show 2 child parametersHide child parameters
typestringRequiredType of the tax identifier. One of eu_vat, gb_vat, us_ein, ca_gst_hst, ca_bn, au_abn, in_gst, or pl_nip.
valuestringRequiredValue of the tax identifier.
kyc_datestringTime at which the customer's KYC check was completed, in ISO 8601 format.
screening_datestringTime at which the customer was last screened, in ISO 8601 format.
signature_datestringTime at which the customer signed the agreement, in ISO 8601 format.
cardobjectRaw details of a card. Requires an API key enabled for raw card data (PCI). 3D Secure results (three_ds, three_ri) are not accepted.
Show 7 child parametersHide child parameters
numberstringRequiredThe card number, as a string without any separators.
expiry_monthstringRequiredTwo-digit number representing the card's expiration month.
expiry_yearstringRequiredTwo or four-digit number representing the card's expiration year.
cvvstringCard security code. cvc is accepted as an alias.
namestringCardholder's full name.
billing_addressobjectBilling address of the card.
Show 6 child parametersHide child parameters
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
sourceobjectShow 2 child parametersHide child parameters
idstringRequiredUnique identifier for a stored payment method to assess.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
tokenobjectShow 3 child parametersHide child parameters
idstringRequiredA token that identifies the payment method in Pay.com's Tokenization Vault.
cvvstringCard security code.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
network_tokenobjectRaw network token details. 3D Secure results (three_ds, three_ri) are not accepted.
Show 7 child parametersHide child parameters
tokenstringRequiredThe network token (token PAN).
token_typestringRequiredOrigin of the network token. Use applepay or googlepay for a decrypted wallet token.
expiry_monthstringRequiredExpiry month of the token.
expiry_yearstringRequiredExpiry year of the token.
namestringCardholder's full name.
cryptogramstringCryptogram for the token.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
googlepayobjectGoogle Pay payment token, sent exactly as Google Pay returns it in paymentMethodData.tokenizationData.token (parsed from its JSON string). Field names keep Google's camelCase.
Show 5 child parametersHide child parameters
signaturestringRequiredSignature that verifies the message came from Google.
protocolVersionstringRequiredVersion of the Google Pay encryption protocol used to create the token.
signedMessagestringRequiredThe encrypted payment data and its metadata, as a serialized JSON string.
intermediateSigningKeyobjectRequiredIntermediate signing key from Google, used with protocolVersion ECv2.
Show 2 child parametersHide child parameters
signedKeystringRequiredThe intermediate signing key, as a serialized JSON string.
signaturesarray of stringsSignatures that verify the intermediate signing key came from Google.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
applepayobjectApple Pay payment token. Send the paymentData object of the PKPaymentToken exactly as Apple returns it (field names keep Apple's camelCase), and optionally the token's paymentMethod object.
Show 6 child parametersHide child parameters
signaturestringRequiredSignature of the payment and header data, as a Base64-encoded string.
versionstringRequiredVersion of the Apple Pay payment token.
datastringRequiredEncrypted payment data, as a Base64-encoded string.
headerobjectRequiredAdditional version-dependent information used to decrypt and verify the payment.
Show 3 child parametersHide child parameters
publicKeyHashstringRequiredHash of the X.509 encoded public key bytes of the merchant's certificate, as a Base64-encoded string.
ephemeralPublicKeystringRequiredEphemeral public key bytes, as a Base64-encoded string.
transactionIdstringRequiredTransaction identifier generated on the device, as a hexadecimal string.
paymentMethodobjectThe paymentMethod object of the Apple Pay token, if available.
Show 3 child parametersHide child parameters
displayNamestringDescription of the card, suitable for display.
networkstringPayment network of the card.
typestringType of the card.
authentication_contextobjectRequiredShow 2 child parametersHide child parameters
customer_ip_addressstringCustomer IP address.
browser_detailsobjectCustomer browser details.
Show 9 child parametersHide child parameters
accept_headerstringRequiredExact content of the HTTP accept headers.
javascript_enabledbooleanRequiredWhether Javascript is enabled in browser.
languagestringRequiredBrowser language. Returned from navigator.language property from the HTML DOM API.
user_agentstringRequiredExact content of the HTTP user-agent header.
screen_widthintegerRequiredScreen width of a device. Obtained from cardholder browser using the screen.width property.
screen_heightintegerRequiredScreen height of a device. Obtained from cardholder browser using the screen.height property.
timezone_offsetstringRequiredOffset from UTC timezone in minutes. Obtained from cardholder browser using the getTimezoneOffset() method.
java_enabledbooleanRequiredWhether Java is enabled in browser. Obtained from cardholder browser using the navigator.javaEnabled property.
color_depthintegerRequiredColor depth of a device screen. Obtained from cardholder browser using the screen.colorDepth property.
optionsobjectOptions for the risk assessment.
Show 1 child parameterHide child parameters
risk_score_thresholdsarray of objectsRisk score ranges and the outcome to apply to each range. The ranges must include an allow range, cover every score from 0 to 100 with no gaps or overlaps (each start is the previous end + 1), and be ordered by severity: a range with a higher score cannot have a less severe outcome than a lower range. Otherwise the request returns 400, for example "Risk range intersection not allowed" or "Outcome was not provided for all possible ranges".
Show 3 child parametersHide child parameters
startintegerRequiredFirst score of the range, inclusive.
endintegerRequiredLast score of the range, inclusive. The next range must start at end + 1.
outcomestringRequiredOutcome to apply to scores in the range. One of three_ds_exemption, three_ds_not_required, allow, require_three_ds, three_ds_challenge, or block (ordered from least to most severe).
Returns
Returns the created assessment object.
idstringUnique identifier for the risk assessment.
resourcestringString representing the object's type.
amountnumberAmount assessed, in the smallest currency unit.
amount_human_readablestringAmount in human-readable format.
currencystringThree-letter ISO currency code, in lowercase.
billing_detailsobject or nullBilling information associated with the assessment. Null when no billing details were sent.
Show 2 child attributesHide child attributes
Option 1objectShow 1 child attributeHide child attributes
addressobjectAddress details.
Show 6 child attributesHide child attributes
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
Option 2nullshippingobject or nullShipping information associated with the assessment. Null when no shipping details were sent.
Show 2 child attributesHide child attributes
Option 1objectShipping information for the payment.
Show 3 child attributesHide child attributes
addressobjectAddress details.
Show 6 child attributesHide child attributes
citystringCity, district, suburb, town, or village.
countrystringTwo-letter country code (ISO 3166-1 alpha-2).
line1stringAddress line 1 (for example, street, PO Box, or company name).
line2string or nullAddress line 2 (for example, apartment, suite, unit, or building). Responses return null when not set.
postal_codestringZIP or postal code.
statestring or nullState, county, province, or region. Null is accepted and returned when not set.
namestringFull name of the recipient.
phonestringPhone number of the recipient, preferably in E.164 format. The leading + is optional.
Option 2nullpayment_method_detailsobjectDetails about the payment method being assessed. No card details are returned.
Show 3 child attributesHide child attributes
typestringThe type of the payment method. card_token for card, token, network token and wallet payment methods.
setup_future_usagenullAlways null for assessments.
third_party_tokensarray of objectsAlways empty for assessments.
Show 8 more attributesShow fewer attributes
createdstringTime at which the object was created, in ISO 8601 format.
test_modebooleanWhether the assessment was created in the sandbox.
optionsobjectOptions used for this risk assessment.
Show 1 child attributeHide child attributes
risk_score_thresholdsarray of objectsRisk score ranges and the outcome applied to each range.
Show 3 child attributesHide child attributes
startnumberLower bound of the risk score range.
endnumberUpper bound of the risk score range.
outcomestringOutcome to apply when the risk score falls within the range.
outcome_sourcestringSource of the risk assessment outcome, if applicable. One of score, rule (one rule matched; see rule_id), or rules (several rules matched). Omitted when outcome is omitted.
rule_idstringUnique identifier for the rule that triggered the outcome, when exactly one rule matched. Omitted otherwise.
scorenumberRisk score assigned to this assessment, if available. Omitted when no score was computed.
outcomestringFinal outcome of the risk assessment. One of three_ds_exemption, three_ds_not_required, allow, block, require_three_ds, or three_ds_challenge. Omitted when the decision is allow and no rule, score or flag applied: a missing outcome means allow.
flagsarray of stringsList of risk flags identified during assessment.
Errors
400401invalid_key, invalid_token, legacy_keys_ended, legacy_keys_off or permission_denied).403code says why.409idempotency-key is still being processed (request_in_progress). Wait, then retry with the same key.500503Retry-After, or after a few seconds when there's none.