Configuration
BETA: This functionality is under development and there may be changes not reflected in this help.
This section handles the domains configuration.
GET /domains
This method returns the list of domains.
Request parameters:
- company [mandatory]: the company name or id.
- session [mandatory]: the Id of the active session.
Response:
- status: returns "0" on success, and an error code in any other case.
- data: returns the list of domains.
- message: "Success" or a descriptive information of the error in any other case.
Request: { "session": "cJvqHJcEssmpGukxrZF73migL5M4LVUZniyesQHBatOvTkrbpkYgrHKvfVpP", "company": "demo01", } Response: { "status": "0", "data": [ { "Id": "clients", "Desc": "Clientes" }, { "Id": "No", "Desc": "" }, { "Id": "P1", "Desc": "P1" } ], "message": "Success" } |
POST /domains/{id}
This method creates a domain. The user must have the administrator role.
Request attribute:
- id [mandatory]: the Id of the domain.
Request parameters:
- company [mandatory]: the company name or id.
- session [mandatory]: the Id of the active session.
- name [mandatory]: the name of the measure unit.
- description [mandatory]:the description of the domain.
Response:
- status: returns "0" on success, and an error code in any other case.
- data: "success" on success, and empty in case of error.
- message: "success" or a descriptive information of the error in any other case.
Request: { "session": "cJvqHJcEssmpGukxrZF73migL5M4LVUZniyesQHBatOvTkrbpkYgrHKvfVpP", "company": "demo01", "idcomb": "test", "desc": "testcomb" } Response: { "status": 0, "data": true, "message": "Success" } |
PUT/domains/{id}
This method modify a domain. The user must have the administrator role.
Request attribute:
- id [mandatory]: the Id of the domain.
Request parameters:
- company [mandatory]: the company name or id.
- session [mandatory]: the Id of the active session.
- description [mandatory]:the description of the combo.
Response:
- status: returns "0" on success, and an error code in any other case.
- data: "success" on success, and empty in case of error.
- message: "success" or a descriptive information of the error in any other case.
Request: { "session": "cJvqHJcEssmpGukxrZF73migL5M4LVUZniyesQHBatOvTkrbpkYgrHKvfVpP", "company": "demo01", "idcomb": "test", "desc": "testcomb" } Response: { "status": 0, "data": true, "message": "Success" } |
DELETE /domains/{id}
This method deletes a domain. The user must have the administrator role.
Request attribute:
- id [mandatory]: the Id of the domain.
Request parameters:
- company [mandatory]: the company name or id.
- session [mandatory]: the Id of the active session.
Response:
- status: returns "0" on success, and an error code in any other case.
- data: "success" on success, and empty in case of error.
- message: "success" or a descriptive information of the error in any other case.
Request: { "session": "cJvqHJcEssmpGukxrZF73migL5M4LVUZniyesQHBatOvTkrbpkYgrHKvfVpP", "company": "demo01", "idcomb": "test" } Response: { "status": 0, "data": true, "message": "Success" } |