Edits GL Subcode definitions (name, type, and pick-list values) for one or more subcodes
Use this endpoint to update the names, types (freeform or list), and pick-list values for GL subcodes.
Multiple subcodes can be edited in a single request. Subcode names must be unique across all 20 subcodes.
For list-type subcodes, at least one pick-list value is required and values cannot exceed 25 characters.
Requires AccountingSettings Manage permission.
Request Headers
| Header | Value | Required | Description |
|---|---|---|---|
| ECI-ApiKey | string | Yes | Your API key. See Authentication. |
| Content-Type | application/json | Yes | All requests must specify JSON content type, including the request body. |
Request Body
Array of:
GLSubcodeRequest
| Property | Description | Type |
|---|---|---|
| subCodeIndex | Index of this subcode (1-20) Required Must be between 1 and 20 | integer (int32) |
| subCodeName | Name for this SubCode Required Must be between 0 and 32 characters | string |
| subCodeType | SubCodeType - should be “list”(fixed=1 in DB) or “text” (fixed=0 in DB) Required One of ’list’, ’text’ | string |
| subCodeValues | An array of pick list values when this subcode is a “list” Required when subCodeType is set to list | string[] |
Example Request Body
[
{ "subCodeIndex": 1, "subCodeName": "string", "subCodeType": "string", "subCodeValues": [
"string"
]
}
]
Responses
200
OK
The request succeeded and the response body contains the requested data.
Response Body Parameters
Array of:
GLSubcodeResponse
| Property | Description | Type |
|---|---|---|
| subCodeIndex | Index of this subcode (01-20) | string |
| subCodeName | Name for this SubCode | string |
| subCodeType | SubCodeType - will be “list”(if fixed=1 in DB) or “text” (if fixed=0) in DB | string |
| subCodeValues | An array of pick list values when this subcode is a “list” | string[] |
Example Response
[
{ "subCodeIndex": "string", "subCodeName": "string", "subCodeType": "string", "subCodeValues": [
"string"
]
}
]
400
Bad Request
The request was malformed or contains invalid parameters. Check the request body and query parameters.
404
Not Found
The requested resource was not found. Verify the ID or path is correct.