to get a personalized navigation.
to get a personalized navigation.
Hi, trying to update a customer but some of the fields is not updated.
Endpoint: /controller/api/v1/customer/{customerCd}
JSON:
{
"sendInvoicesByEmail" => {
"value" => true
}
}
Response: 204
GUI:
The field I tried to update did not set properly.
I have also tried to update "printInvoices", "acceptAutoInvoices", "printStatements", and most of the other checkboxes that can be found in this window without success. I have also tried to add other fields and these fields do update just fine, e.g. add a char to the name of the customer.
The first update I did today did work, I set "acceptAutoInvoices" to "false", after this no other update call have worked.
Also it seems the field "MailDunningLetters" is missing from the API.
Solved! Go to Solution.
Hi,
The JSON should look like this:
{
"sendInvoicesByEmail" : {
"value" : true
}
}
We have just tested this and the update goes through without issues.
Regarding fields that you wish were exposed, please write a post in the ideas part of the forum. The posts there will be reviewed by the development team.
Thank you.
Just copy pasted the json from PHP without correcting it. The JSON that is sent is correct.
Can you try with setting all the checkboxes to false first? And then updating a single of them to true again? Because with this current customer I cannot set a single of those fields to true via the API.
The result:
1. Set all to false
PUT Customer/10000
{
"printInvoices": {
"value": false
},
"acceptAutoInvoices": {
"value": false
},
"sendInvoicesByEmail": {
"value": false
},
"printStatements": {
"value": false
},
"sendStatementsByEmail": {
"value": false
},
"printMultiCurrencyStatements": {
"value": false
}
}
2. Set all to true
PUT Customer/10000
{
"printInvoices": {
"value": true
},
"acceptAutoInvoices": {
"value": true
},
"sendInvoicesByEmail": {
"value": true
},
"printStatements": {
"value": true
},
"sendStatementsByEmail": {
"value": true
},
"printMultiCurrencyStatements": {
"value": true
}
}
Thank you for testing it. Is there something else, like settings, customer profile, etc, that can stop it from working?
Because running the same query here does not work.
Could you please test to run the query from Postman or swagger? Are you having the same issue on several customers or is it only this one?
There is not setting that comes to mind that should prevent you from ticking any of the boxes.
Copyright © 2022 Visma.com. All rights reserved.