Table of Contents | ||
---|---|---|
|
Error Overview
Flexiti uses conventional HTTP response codes to indicate the success or failure of an API request. In general:
Codes in the
2xx
range indicate success.Codes in the
4xx
range indicate an error that failed given the information provided (e.g., a required parameter was omitted, a transaction failed, etc.).Codes in the
5xx
range indicates an error with Flexiti's servers.
Some 4xx
errors that could be handled programmatically include an error code that briefly explains the error reported.
HTTP Status Code Summary
HTTP Status Codes | Type | Status |
200 | Success | Everything worked as expected. |
401 | Unauthorized | An error with the Merchant authentication. |
402 | Request Failed | The parameters were valid but the request failed. |
404 | Not Found | The requested resource doesn't exist. |
409 | Bad Request | The request was unacceptable, often due to missing a required parameter or wrong format. |
500, 502, 503, 504 | Server Errors | Something went wrong on the Flexiti side. (These are rare.) |
General Errors
...
Code
...
Error
...
Scenario
...
400
...
invalid_client
...
Wrong or missing client id or client_secret
...
400
...
invalid_request
...
Invalid or missing grant_type parameter
...
400
...
not_found
...
Authorization ID not found
...
400
...
invalid_account
...
Wrong account number (if requested)
...
401
...
invalid_token
...
Wrong or expired access token.
...
401
...
Unauthorized
...
Wrong or missing Merchant authorization
...
404
...
not_found
...
Customer Account not found
...
409
...
authentication_failure
...
Missing or wrong Merchant authentication parameters
...
409
...
tos_agreement_required
...
Terms and Conditions missing or not agreed
...
409
...
customer_already_exists
...
Customer applying already has an account
...
409
...
application_declined, application_declined_2, application_declined_3
...
Customer application declined
...
409
...
creditapp_id_not_found
...
Credit Application ID was not found
...
409
...
application_marked_pending_1, application_marked_pending_2
...
Customer application pending
...
409
...
application_create_error
...
There was an error creating the Credit Application
...
409
...
user_not_active
...
Customer Account is not activated
...
409
...
not_found
...
Customer could not be found
...
409
...
user_not_able_to_purchase
...
Customer account status different to normal (NNOR)
...
409
...
not_found
...
Customer Account number could not be found
...
409
...
secret_answer_mismatch
...
Security question answer does not match what is on file for the customer
...
409
...
merchant_override_is_not_allowed
...
Merchant is not configured for Merchant Override
...
409
...
piw_mismatch
...
Personal Identification word entered does not match what is on file for the customer
...
409
...
Driver License's not supported
...
409
...
wrong_verification_code
...
Verification code entered is incorrect
...
409
...
verification_code_required
...
Verification code is a required parameter.
...
409
...
invalid_transaction_type
...
wrong value for transaction type in the request
...
409
...
not_enough_credit
...
Customer does not have enough open to buy for transaction amount
...
409
...
limit_payment_amount_24
...
409
...
refunds_limit_exceeded_amount
...
TBD
...
auth_not_allowed
...
Merchant has not configured pre-auth in Lexi.
...
TBD
...
plan_term_not_set
...
Merchant has not configured the financing option (Plan and Term or Regular Purchase) in Lexi.
...
TBD
...
plan_term_not_available
...
Plan and Term for prime category for a non-prime customer.
Plan "DP - SAC Interest Accrues" for a QC customer.
Plan "DP - SAC No Payments + No Interest Accrued" for a ROC customer.
...
TBD
...
credit_exceeded
...
Amount requested plus fees is greater than the available credit of the customer account.
...
customer_identity_not_found
...
The customer didn’t pass through the widget or was not authenticated properly
Input Errors
Input errors will tend to follow this model:
message: "Some inputs are wrong or missing!"
error: "wrong_inputs"
error_fields:
"param": "parameter_name",
“msg”: “error message”
"value":"parameter_value",
"type":"validation_type",
Example Response
Code Block | ||
---|---|---|
| ||
{
"url": "/flexiti/pos-api/v2.5/client-id/flexitidemo/customers/828930/verify",
"message": "Some inputs are wrong!",
"error": "wrong_input",
"field_errors": [
{
"param": "email",
"msg": "invalid",
"value": "johndoe@"
}
]
} |
Validation Type | Scenario |
---|---|
Required | Mandatory parameter not sent in the request. |
Invalid | Date with wrong format. |
Type | Mismatch data type |
Length | Data length exceeded. |
Parameter Validations
account_number
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
address_1
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
address_2
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
amount
Case | Error Type |
Value different to a number. | type |
Decimal point different to period. | invalid |
Value zero or negative. | invalid |
Value with higher precision and/or scale | length |
amount_requested
Case | Error Type |
Decimal point different to period. | invalid |
Value zero or negative. | invalid |
Value with higher precision and/or scale | length |
Value different to a number. | type |
authorization_id
Case | Error Type |
Value different to a number | invalid |
Not sent | required |
auto_capture
Case | Error Type |
Different to the available values. | invalid |
bearer token
Case | Error Type |
Value not started with "Bearer" followed by a space | invalid |
Token length different to 1000 characters | invalid |
Token not valid. | invalid |
Token expired. | invalid |
Not sent | required |
capture_id
Case | Error Type |
Client not valid. | invalid |
Not sent | required |
city
Case | Error Type |
Value with higher length | length |
Not sent | required |
Value different to a string. | type |
client_id
Case | Error Type |
Client ID not valid | invalid |
Not sent | required |
client_secret
Case | Error Type |
Value with higher length | length |
Not sent | required |
customer_id
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
date
Case | Error Type |
Value with wrong format | invalid |
dob
Case | Error Type |
Value with wrong format | invalid |
Not sent | required |
Case | Error Type |
Value with wrong format | invalid |
Not sent | required |
employer_name
Case | Error Type |
Value with wrong format | invalid |
employer_phone
Case | Error Type |
Value with wrong format | invalid |
ending_date
Case | Error Type |
Value with wrong format | invalid |
first_name
Case | Error Type |
Value with higher length | length |
Not sent | required |
Value different to a string. | type |
full_release
Case | Error Type |
Different to the available values. | invalid |
full_return
Case | Error Type |
Different to the available values. | invalid |
govid_expiry
Case | Error Type |
Value with wrong format | invalid |
Value with a date less than the current date | invalid |
Not sent | required |
govid_issuedby
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
govid_number
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
govid_type
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
grant_type
Case | Error Type |
Different to the available values. | invalid |
household_income
Case | Error Type |
Value negative. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
housing_type
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
input_type
Case | Error Type |
Different to the available values. | invalid |
lang
Case | Error Type |
Different to the available values. | invalid |
last_name
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
location_id
Case | Error Type |
Value different to a number | invalid |
merchant_id
Case | Error Type |
Value different to a number | invalid |
merchant_password
Case | Error Type |
Not sent | required |
Value different to a string. | type |
Value with higher length | length |
merchant_username
Case | Error Type |
Value with higher length | length |
Not sent | required |
Value different to a string. | type |
middle_name
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
monthly_housing_expenses
Case | Error Type |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
occupation_id
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
occupation_title
Case | Error Type |
Value with higher length | length |
Not sent | required |
Value different to a string. | type |
page_number
Case | Error Type |
Not sent | required |
Value different to a number. | type |
page_size
Case | Error Type |
Value different to a number. | type |
personal_income
Case | Error Type |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
phone_number
Case | Error Type |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
piw
Case | Error Type |
Value with higher length | length |
Not sent | required |
Value different to a string. | type |
plan_id
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
postal_code
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
preferred_language
Case | Error Type |
Different to the available values. | invalid |
province
Case | Error Type |
Different to the available values. | invalid |
Value different to a string. | type |
reference
Case | Error Type |
Value with higher length | length |
Value different to a string. | type |
salutation
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
Value different to a string. | type |
security_answer
Case | Error Type |
Not sent | required |
Value different to a string. | type |
Value with higher length | length |
security_qid
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
sin
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Value different to a number. | type |
term
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Not sent | required |
Value different to a number. | type |
tos_agreement
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
transaction_type
Case | Error Type |
Different to the available values. | invalid |
Not sent | required |
vcc_number
Case | Error Type |
Value zero or negative. | invalid |
Value with decimals. | invalid |
Value with higher precision | length |
Value different to a number. | type |
verification_code
...
Case
...
Error Type
...
Value zero or negative.
...
invalid
...
Value with decimals.
...
invalid
...
Value with higher precision
...
invalid
...
Not sent
...
required
...
Value different to a number.
...
Table of Contents | ||||
---|---|---|---|---|
|
Error Overview
Flexiti uses conventional HTTP response codes to indicate the success or failure of an API request. In general:
Codes in the
2xx
range indicate success.Codes in the
4xx
range indicate an error that failed given the information provided (e.g., a required parameter was omitted, a transaction failed, etc.).Codes in the
5xx
range indicates an error with Flexiti's servers.
Some 4xx
errors that could be handled programmatically include an error code that briefly explains the error reported.
HTTP Status Code Summary
HTTP Status Code | Type | Status |
200 | Success | Everything worked as expected. |
401 | Unauthorized | An error with the Merchant authentication. Wrong or expired access token. |
403 | Forbidden | Request is forbidden for the level of access granted. |
404 | Not Found | The requested resource doesn't exist. |
409 | Bad Request | The request was unacceptable, often due to missing a required parameter or wrong format. |
465 | Blocked | Blocked a request that contained a malicious payload. |
466 | Blocked | Blocked a request due to an ACL rule. |
467 | Blocked | Blocked a request because it was Geo-blocked. |
500 | Server Errors | Something went wrong on the Flexiti side. (These are rare.) |
*465/466/467 Status codes can be treated the same way as 403.
General Debugging Notes
If at anytime you receive an error for “general_error”, please email implementation@flexiti.com, as the issue is likely related to your account set-up.
General Input Errors
Input errors will tend to follow this model:
message: "Some inputs are wrong or missing!"
error: "wrong_inputs"
error_fields:
"param": "parameter_name",
“msg”: “error message”
"value":"parameter_value",
Example Response
Code Block |
---|
{
"url": "/flexiti/pos-api/v2.5/client-id/flexitidemo/customers/828930/verify",
"message": "Some inputs are wrong!",
"error": "wrong_input",
"field_errors": [
{
"param": "email",
"msg": "invalid",
"value": "johndoe@"
}
]
} |
...
Merchant Integration Endpoint Errors
POST /oauth/token
Code | Error | Scenario |
400 | invalid_client | Wrong or missing client id or client_secret |
400 | invalid_request | Invalid or missing grant_type parameter |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | wrong_inputs | Invalid parameter |
GET /client-id/{clientId}/i18n
Code | Error | Scenario |
409 | general_error | A generic error covering back-end process issues |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{clientId}/widget/init
Code | Error | Scenario |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | wrong_inputs | Invalid parameter |
...
Credit Application Endpoint Errors
POST /client-id/{client_id}/apply
Code | Error | Scenario |
400 | general_error | A generic error covering back-end process issues |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | application_create_error | There was an error creating the Credit Application due to a 3rd party timeout |
409 | tos_agreement_required | Terms and Conditions missing or not agreed |
409 | customer_already_exists | Customer applying already has an account |
409 | not_verified | For the online channel, the /apply payload contains different personal information than the /init payload using the same token, or incorrect widget_session_id |
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | account_type_not_permitted | The merchant is not able to support applications for this account type. |
409 | wrong_inputs | Invalid parameter |
...
Customer Endpoint Errors
GET /client-id/{client_id}/customers/lookup
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | user_not_able_to_purchase | Customer account status different to normal (NNOR) |
409 | user_not_active | Customer Account is not activated |
409 | merchant_not_support_nonprime_regularpurchase | Customer is non-prime and the Merchant does not accept non-prime or have the appropriate plans. |
409 | wrong_inputs | Invalid parameter |
GET /client-id/{client_id}/customers/search
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{client_id}/account/{account_number}/verify
Code | Error | Scenario |
400 | sms_not_valid_phone | Phone number on file invalid/missing |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account or VCC is not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | merchant_override_is_not_allowed | Merchant is not configured for Merchant Override |
409 | regular_purchase_bypass_is_not_allowed |
|
409 | piw_mismatch | Personal Identification word entered does not match what is on file for the customer |
409 | secret_answer_mismatch | Security question answer does not match what is on file for the customer |
409 | wrong_inputs | Invalid parameter |
409 | tries_exceed | The wrong security answer has been attempted on this account more than three times in the last 48 hours. |
POST /client-id/{client_id}/accounts/{account_number}/close
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
POST /pos-api/client-id/{client_id}/accounts/{account_number}/calculate-interest
Code | Error | Scenario |
404 | not_found | Customer Account not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | wrong_inputs | Invalid parameter |
...
Transaction Endpoint Errors
POST /client-id/{client_id}/transactions
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account, VCC, or transaction not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | invalid_transaction_type | wrong value for transaction type in the request |
409 | wrong_verification_code | Verification code entered is incorrect |
409 | verification_code_required | Verification code is a required parameter. |
409 | user_not_active | Customer Account is not activated |
409 | user_not_able_to_purchase | Customer account status different to normal (NNOR) |
409 | limit_payment_amount_24 | Payments made on the account exceed the $10,000/day limit |
409 | not_enough_credit | Customer does not have enough open to buy for transaction amount |
409 | not_verified | For in-store channel the request_id does not match the one passed in the /verify endpoint |
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | account_type_not_permitted | The merchant is not able to support this account type (open/closed loop scenarios) |
409 | vcc_account_mismatch | The vcc number being passed in the request does not belong to the account number. |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{client-id}/authorization
Code | Error | Scenario |
404 | not_found | Customer Account or VCC not found |
404 | customer_identity_not_found | the customer didn’t pass through the widget or was not authenticated properly |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | credit_exceeded | Amount requested plus interest is greater than the available credit of the customer account. |
409 | not_permitted | API credentials do not have sufficient permissions to perform an authorization |
409 | general_error | A generic error covering back-end process issues |
409 | auth_not_allowed | Merchant has not been configured for preauthorization |
409 | plan_term_not_set | Merchant has not been configured for the financing option (Plan and Term or Regular Purchase). |
409 | plan_term_not_available |
|
409 | user_not_able_to_purchase | Customer account status different than normal (NNOR) |
409 | not_verified |
|
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | account_type_not_permitted | The merchant is not able to support this account type (open/closed loop scenarios) |
409 | vcc_account_mismatch | The vcc number being passed in the request does not belong to the account number. |
409 | wrong_inputs | Invalid parameter |
GET /client-id/{clientId}/authorizations
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | date_from_bigger_than_date_to | The From date is later than the To date |
409 | wrong_inputs | Invalid parameter |
GET /client-id/{clientId}/authorization/{authorizationId}
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
400 | not_found | Authorization ID not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{clientId}/authorization/{authorizationId}/release
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Authorization ID not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | generic_error | A generic error covering back-end process issues |
409 | authorization_ended | Credit authorization has “closed” status |
409 | auth_amount_exceeded | Release amount is greater than the remaining credit authorization amount. |
409 | not_permitted | The employee doesn’t have enough permissions to perform the release |
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{clientId}/authorization/{authorizationId}/capture
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Authorization ID not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | authorization_ended | Credit authorization has “closed” status |
409 | auth_amount_exceeded | Capture amount is greater than the remaining credit authorization amount. |
409 | not_permitted |
|
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{clientId}/authorization/{authorizationId}/capture/{captureId}/return
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Authorization ID, Capture ID, or VCC not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | capture_amount_exceeded | Return amount is greater than the remaining captured amount. |
409 | return_date_exceeded | Capture creation date is more than 100 days old. |
409 | wrong_transaction_type | The capture is not related to a promotional purchase |
409 | not_permitted | The employee doesn’t have enough permissions to perform the return |
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | account_type_not_permitted | The merchant is not able to support this account type (open/closed loop scenarios) |
409 | vcc_account_mismatch | The vcc number being passed in the request does not belong to the account number. |
409 | wrong_inputs | Invalid parameter |
POST /client-id/{client_id}/accounts/{account_number}/refund
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
404 | not_found | Customer Account, VCC, or Capture ID not found |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | refunds_limit_exceeded_amount | Refund amount exceeds account balance limit. |
409 | external_location_id_not_found | The external location ID being passed is not registered with Flexiti |
409 | account_type_not_permitted | The merchant is not able to support this account type (open/closed loop scenarios) |
409 | vcc_account_mismatch | The vcc number being passed in the request does not belong to the account number. |
409 | capture_amount_exceeded | Return amount is greater than the remaining captured amount. |
409 | wrong_inputs | Invalid parameter |
GET /client-id/{clientId}/captures
Code | Error | Scenario |
403 | Insufficient scope: authorized scope is insufficient | Scope of the token is not sufficient to access the endpoint |
409 | invalid_role | The Developer Portal account being used is not provisioned for the API being accessed. Please contact Flexiti Implementation Support. |
409 | general_error | A generic error covering back-end process issues |
409 | date_from_bigger_than_date_to | The From date is later than the To date |
409 | wrong_inputs | Invalid parameter |