Creates a location in the organization’s location catalog.
https://api.doboard.com/{account_id}/location_add
account_id is the numeric organization identifier.
GET, POST. POST accepts parameters as application/x-www-form-urlencoded.
Requires a valid session_id. Only ADMIN and PROJECT_MANAGER users can create locations.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
session_id |
string | Yes | — | Authenticated session ID. |
location_name |
string | Yes | — | Location name. Truncated to the first 64 characters. |
country_code |
string | Yes | — | Country code, for example GB. Truncated to the first 2 characters. |
location_code |
string | No | Empty string | Short location code. Truncated to the first 3 characters. |
The required string parameters must be supplied. The current implementation accepts empty strings and does not validate codes against a country or location directory.
POST /42/location_add HTTP/1.1
Host: api.doboard.com
Content-Type: application/x-www-form-urlencoded
session_id=YOUR_SESSION_ID&location_name=London&country_code=GB&location_code=LON
{
"data": {
"operation_status": "SUCCESS",
"location_id": 7
}
}
location_id identifies the created location. The ID in this example is illustrative.
| HTTP Code | error_no |
Message | Description |
|---|---|---|---|
401 |
401 |
session_id Unknown |
Missing or invalid session. |
403 |
403 |
Permission denied |
The user cannot create locations. |
200 |
6101 |
location_name is required |
Location name was not supplied. |
200 |
6102 |
country_code is required |
Country code was not supplied. |
200 |
0 |
Internal API Error |
The location could not be created. |