Accounts
Below section describes error response codes from Client-API for account operations.
- Error Response: POST/v1/{clientId}/create_accounts
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. currency 2. products → productReference 3. debtors → debtorReference 4. debtors → contactInformation → country | {"messages":["body/['<entityId>'] should have required property '<field>'"],"messageIds":[],"success":false} |
| 400 Bad Request | Partial Values in JSON payload | -Check conditional mandatory fields are part of payload 1. scores → type & value 2. ledgerEntries → ledgerEntryReference 3. ledgerEntries → context 4. ledgerEntries → invoiceDetails → amount 5. ledgerEntries → invoiceDetails → dueDate 6. ledgerEntries → feeDetails → amount 7. ledgerEntries → paymentDetails → amount 8. ledgerEntries → adjustmentDetails → amount 9. ledgerEntries → chargebackDetails → amount 10. ledgerEntries → discountDetails → amount 11. ledgerEntries → reportingDetails → amount | {"messages":["body/['ENTITY_ID'].ENTITY should have required property 'field'"],"messageIds":[],"success":false} |
| 200 OK Transaction status: failed | Duplicate ID | -Entity is already created. Check the field mentioned for duplicate resource created 1. AccountID 2. ledgerEntries → ledgerEntryReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4007] t: Already defined ledger entry"],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/add_account_debtors
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. debtorReference 3. contactInformation → country | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4003] t: Already defined ledger entry"],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/set_account_scores
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. type 3. value | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference |
- Error Response: POST/v1/{clientId}/update_account_debtors
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. debtorReference 3. contactInformation → country | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for accuracy. 1. accountReference 2. debtorReference | {"ENTITY_ID":{"success":false,"messageIds":[],"messages":["Error updating debtor <DEBTOR_ID> to the Account: [4000] t: Error processing message "cmd.accountDebtor.update.v1"\n* [object Object]"]}} |
- Error Response: POST/v1/{clientId}/add_account_debtors
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. debtorReference 3. contactInformation → country | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4003] t: Already defined ledger entry"],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/update_account_debtors
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. debtorReference 3. contactInformation → country | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference 2. debtorReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4003] t: Already defined ledger entry"],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/add_account_ledger_entries
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. ledgerEntryReference | {"messages":["body/[0]. |
| 400 Bad Request | Partial Values in JSON payload | -Check conditional mandatory fields are part of payload 1. invoiceDetails → amount 2. invoiceDetails → dueDate 3. feeDetails → amount 4. paymentDetails → amount 5. adjustmentDetails → amount 6. chargebackDetails → amount 7. discountDetails → amount 8. reportingDetails → amount | {"messages":["body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'feeDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'invoiceDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'paymentDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'chargebackDetails'","body/[0].context should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'discountDetails'","body/[0].context should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'reportingDetails'","body/[0] should match exactly one schema in oneOf"],"messageIds":[],"success":false} |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4003] t: Already defined ledger entry"],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/update_account_ledger_entries_amounts
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. ledgerEntryReference | {"messages":["body/[0]. |
| 400 Bad Request | Partial Values in JSON payload | -Check conditional mandatory fields are part of payload 1. invoiceDetails → amount 2. invoiceDetails → dueDate 3. feeDetails → amount 4. paymentDetails → amount 5. adjustmentDetails → amount 6. chargebackDetails → amount 7. discountDetails → amount 8. reportingDetails → amount | {"messages":["body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'feeDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'invoiceDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'paymentDetails'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'chargebackDetails'","body/[0].context should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'discountDetails'","body/[0].context should have required property 'ledgerEntryReference'","body/[0] should have required property 'ledgerEntryReference'","body/[0] should have required property 'reportingDetails'","body/[0] should match exactly one schema in oneOf"],"messageIds":[],"success":false} |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference 2. ledgerEntryReference | {"ENTITY_ID":{"success":false,"messageIds":[],"messages":["Error updating Account Ledger Entries amounts: [4006] t: Ledger Entry Not Found"]}} |
- Error Response: POST/v1/{clientId}/update_account_meta
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference | {"ENTITY_ID":{"success":false,"messageIds":[],"messages":["Error updating Account Ledger Entries amounts: [4006] t: Ledger Entry Not Found"]}} |
- Error Response: POST/v1/{clientId}/add_account_products
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. productReference | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference | {"entityId":{"messages":["Error creating the Account <entityId>: [4003] t: "],"messageIds":[],"data":{"scores":[],"debtors":[],"products":[],"ledgerEntries":[]},"success":false}} |
- Error Response: POST/v1/{clientId}/update_account_products
| HTTP Status Code | Meaning | Resolution Tip | Error Response |
| 400 Bad Request | Missing values in JSON payload | -Check mandatory fields are part of payload -Mandatory values are 1. accountReference 2. productReference | {"messages":["body/[0]. |
| 200 OK Transaction status: failed | Invalid ID | -Entity doesn't exist Check the field mentioned for existence. 1. accountReference 2. productReference | {"ACCOUNTID":{"success":false,"messages":["Error updating the Product PRODUCTID to the Account: [4005] t: Product Not Found","Error updating the Product PRODUCTREF to the Account: [4005] t: Product Not Found"],"messageIds":[]}} |