Updates a document type
PUT /api/configuration/document-types/{documentTypeId}
Success: 200 OK
- Products: Operator (
FOH) - Features: Front of House Generic Access (
FOHGENERIC)
Overview
Updates a document type — the category a file uploaded against a member is filed under, such as a medical certificate or a signed waiver.
This is a full replacement, not a partial update. name, description, isSensitive and isAttachment are all overwritten from your body, so omitting name or description clears the existing text, and omitting either boolean stores false. Read the current values with Get document type by ID and send the whole object back.
Two rules restrict what you can change:
- System document types cannot be changed at all. These are the types the platform ships and depends on; any update to one is rejected with
409.isSystemon the retrieval response tells you which they are. - A type that a member document already uses can be changed, but not renamed. If any member document is filed under this type,
namemust match the stored name exactly — everything else is still editable. Rename attempts are rejected with409.
Names must also be unique across document types, so reusing another type's name is rejected with 409.
Note the response. A successful update returns 204 No Content with an empty body, not the updated document type. Do not write code that parses a body from this call; fetch the type again if you need to see the result.
Endpoint
PUT {base_url}/api/configuration/document-types/{documentTypeId}
{base_url} is the environment URL issued to your integration. See Authenticating with Gladstone APIs.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
documentTypeId | integer (int32) | Yes | The document type's identifier, as returned in [].id by List document types. This is the type's id, not the id of any member document filed under it. An id that matches nothing fails with 404. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | The document type's name — the label staff pick from when filing a member document. Maximum 255 characters, and unique across document types: reusing another type's name fails with 409. Always overwritten, so omitting it clears the name. If any member document already uses this type, the value must match the stored name exactly (comparison is case-sensitive) or the call fails with 409. |
description | string | No | Longer explanatory text about what belongs under this type. Maximum 500 characters. Always overwritten, so omitting it or sending null clears the stored text. Unlike name, this can be changed freely even while the type is in use. |
isSensitive | boolean | No | Marks documents of this type as sensitive, restricting who may view them. Omitting it or sending null sets it to false, which would widen access to every document already filed under the type. Always send the value you want. |
isAttachment | boolean | No | Marks the type as one whose documents are handled as file attachments. Omitting it or sending null sets it to false. |
Sample request
curl -X PUT '{base_url}/api/configuration/document-types/{documentTypeId}' \
-H 'Authorization: Bearer {accessToken}' \
-H 'X-Use-SSO: true' \
-H 'Content-Type: application/json' \
-d '{
"name": "string",
"description": "string",
"isSensitive": true,
"isAttachment": true
}'Response fields
| Field | Type | Description |
|---|---|---|
id | integer (int32) | The document type's identifier — the value you pass as documentTypeId. Assigned by the platform and never reused. |
key | string | The type's stable code, maximum 55 characters. Unlike name it is not editable through this endpoint, which makes it the safer thing for your integration to match on. |
name | string | The type's display name, unique across document types. |
description | string | The longer explanatory text, up to 500 characters. Null when never set or cleared. |
isSensitive | boolean | Whether documents of this type are treated as sensitive. |
isAttachment | boolean | Whether documents of this type are handled as file attachments. |
isSystem | boolean | Whether the platform owns this type. true means it cannot be updated or deleted — check this before offering it for editing. It is read-only: there is no request field that sets it. |
Sample response
{
"id": 12345,
"key": "string",
"name": "string",
"description": "string",
"isSensitive": true,
"isAttachment": true,
"isSystem": true
}Errors
| Status | Meaning | When |
|---|---|---|
400 | Bad request | The body is not valid JSON for this request, or a value exceeds its maximum length. The body is a validation error object keyed by field name. |
404 | Not found | No document type has that documentTypeId — Document Type ID {id} cannot be found. |
409 | Conflict | The type is a system type — Document Type ID {id} cannot be changed because it is system. No part of the update is applied, including the editable fields. |
409 | Conflict | A member document already uses this type and name differs from the stored name — Document Type ID {id} cannot be changed because it is in use by a member. Resend the stored name to change the other fields. |
409 | Conflict | Another document type already has that name — The document type name {name} already exists. |
500 | Internal server error | An unexpected server-side failure. The response body is empty. |