Set Addison user credentials
Setting an Addison user credentials in Basecone.
POST users/:userId/accountingsystems/:accountingSystemId/addison
Request properties
| Property | Type | Length | Description | Required |
|---|---|---|---|---|
| Secret | String | 255 | User access secret. | It is required if token authentication is used. Not required if basic authentication (username and password) is provided. |
| Username | String | 100 | User username. | It is required if basic authentication (username and password) is used. Not required if token authentication is provided. |
| Password | String | 100 | User password. | It is required if basic authentication (username and password) is used. Not required if token authentication is provided. |
Please note that unlike other API requests, pagination and sorting are not supported.
Example request
{
secret: 'some super secret',
username: 'username',
password: 'super secret password'
}
Success response
Upon successful operation a 200 status code will be returned, containing the created accounting system identifier.
Error response
Case an error occurs, a 400 status code will be returned, containing error message(s).
Example response:
{
"message": "One or more validation errors occurred.",
"code": "validation_error",
"_metadata":[
{
"field": "Password",
"message": "Password is required",
"code": null
}
],
"_moreInfo": "http://developers.basecone.com/lookup/validation_error"
}
Possible error responses
| Status code | Error code | Details |
|---|---|---|
| 400 | user_is_not_allowed_to_change_addison_user_credentials | User trying to set the other user credentials is not allowed to execute the operation. |
| 400 | accounting_system_does_not_belong_to_office | Accounting system does not belong to the user's office. |
| 400 | accounting_system_is_not_addison | It is not Addison Accounting system. |
| 400 | accounting_system_credentials_incorrect | Accounting system does not belongs to the user's office. |
