Customer Financial
The PostAddCustomerFinancial endpoint is responsible for registering customer financial information in the MIMS system.
How to register customer financial information
HTTP POST Request
| Request Type | Example URL |
|---|---|
| POST | {{url_base}}/PostAddCustomerFinancial |
| Example | http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddCustomerFinancial" |
Input Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| CustomerNo | String(25) | Yes | External code of the customer |
| CustomerAuxiliaryNo | String(25) | No | Auxiliary external code of the customer |
| BranchNo | String(25) | No | External code of the branch |
| CreditTotal | Float | No | Total credit value of the customer |
| CreditUsage | Float | No | Credit value used by the customer (must be greater than or equal to zero) |
| CreditEspecial | Float | No | Special credit value of the customer |
| CreditEspecialUsage | Float | No | Special credit value used by the customer |
| CreditDisponible | Float | No | Available credit value of the customer (must be greater than or equal to zero) |
| OpenDocuments | Integer | No | Quantity of open documents |
| OverdueDocuments | Integer | No | Quantity of overdue documents |
| OverdueDocumentsTotal | Float | No | Total value of overdue documents |
| LastDocumentPaymentDate | DataHora | No | Last document payment date |
| LastDocumentPaymentNo | String(40) | No | Last paid document number |
| NextDocumentPaymentDate | DataHora | No | Next document payment date |
| NextDocumentPaymentNo | String(40) | No | Next document to pay number |
| CustomerSince | DataHora | No | Date since when the customer is a customer |
| CheckBlocksActive | CheckBlocksActive | No | Active block type: ckNotAssigned (Not Assigned), ckDelay (Block by Delay), ckInsufficientCredit (Block by Insufficient Credit) or ckBoth (Block by Delay and Insufficient Credit) |
| OverwriteIfExists | Boolean | No | Flag indicating that data should be overwritten if the record already exists |
Return
| Parameter | Type | Required | Description |
|---|---|---|---|
| WebServiceReturn | WebServiceReturn | Yes | Standard WebService response information in method execution |
| CustomerFinancialCode | Integer | Yes | Internal customer financial code generated in the MIMS system |
Request Example
curl --location 'http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddCustomerFinancial"' \
--header 'Content-Type: application/json' \
--data '{
"CustomerNo": "CUST001",
"CustomerAuxiliaryNo": "",
"BranchNo": "FIL001",
"CreditTotal": 10000.00,
"CreditUsage": 2500.00,
"CreditEspecial": 5000.00,
"CreditEspecialUsage": 0.00,
"CreditDisponible": 7500.00,
"OpenDocuments": 5,
"OverdueDocuments": 2,
"OverdueDocumentsTotal": 1500.00,
"LastDocumentPaymentDate": "2024-01-10T00:00:00",
"LastDocumentPaymentNo": "DOC001",
"NextDocumentPaymentDate": "2024-02-15T00:00:00",
"NextDocumentPaymentNo": "DOC002",
"CustomerSince": "2020-01-01T00:00:00",
"CheckBlocksActive": "ckNotAssigned",
"OverwriteIfExists": true
}'
Response Example
{
"WebServiceReturn": {
"Status": "wrsSuccess",
"ErrorCode": "",
"Message": "",
"Actor": "",
"ReturnQuestion": null
},
"CustomerFinancialCode": 789
}
🐞 Possible Errors
| Code | Message |
|---|---|
| ACT‑004 | The provided "CustomerFinancial" parameter already exists for this "CustomerNo"! |