Use this API to manage the custom attributes set on users, groups, and projects.

These endpoints require administrator access to the instance.

List all custom attributes for a group

GET /api/v4/groups/{id}/custom_attributes

Lists all custom attributes for a specified group.

Parameters

NameTypeDescription
id
Path, required
String or integerThe ID or URL-encoded path of the group

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Retrieve a custom attribute for a group

GET /api/v4/groups/{id}/custom_attributes/{key}

Retrieves a specified custom attribute for a group.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the group
Example: 11

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Creates or updates a custom attribute for a group

PUT /api/v4/groups/{id}/custom_attributes/{key}

Creates or updates a custom attribute for a specified group. If the attribute already exists, it is updated, otherwise a new attribute is created.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the group
Example: 11

Request body (application/json)

PropertyTypeDescription
value
Required
StringThe value of the custom attribute

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Delete a custom attribute for a group

DELETE /api/v4/groups/{id}/custom_attributes/{key}

Deletes a specified custom attribute for a group.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the group
Example: 11

Responses

CodeDescriptionSchema
204No Content—
400Bad Request—
404Not Found—

List all custom attributes for a project

GET /api/v4/projects/{id}/custom_attributes

Lists all custom attributes for a specified project.

Parameters

NameTypeDescription
id
Path, required
String or integerThe ID or URL-encoded path of the project

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Retrieve a custom attribute for a project

GET /api/v4/projects/{id}/custom_attributes/{key}

Retrieves a specified custom attribute for a project.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the project
Example: 11

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Creates or updates a custom attribute for a project

PUT /api/v4/projects/{id}/custom_attributes/{key}

Creates or updates a custom attribute for a specified project. If the attribute already exists, it is updated, otherwise a new attribute is created.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the project
Example: 11

Request body (application/json)

PropertyTypeDescription
value
Required
StringThe value of the custom attribute

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Delete a custom attribute for a project

DELETE /api/v4/projects/{id}/custom_attributes/{key}

Deletes a specified custom attribute for a project.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the project
Example: 11

Responses

CodeDescriptionSchema
204No Content—
400Bad Request—
404Not Found—

List all custom attributes for a user

GET /api/v4/users/{id}/custom_attributes

Lists all custom attributes for a specified user.

Parameters

NameTypeDescription
id
Path, required
String or integerThe ID or URL-encoded path of the user

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Retrieve a custom attribute for a user

GET /api/v4/users/{id}/custom_attributes/{key}

Retrieves a specified custom attribute for a user.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the user

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Creates or updates a custom attribute for a user

PUT /api/v4/users/{id}/custom_attributes/{key}

Creates or updates a custom attribute for a specified user. If the attribute already exists, it is updated, otherwise a new attribute is created.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the user

Request body (application/json)

PropertyTypeDescription
value
Required
StringThe value of the custom attribute

Responses

CodeDescriptionSchema
200OKAPIEntitiesCustomAttribute
400Bad Request—
404Not Found—

Delete a custom attribute for a user

DELETE /api/v4/users/{id}/custom_attributes/{key}

Deletes a specified custom attribute for a user.

Parameters

NameTypeDescription
key
Path, required
StringThe key of the custom attribute
id
Path, required
String or integerThe ID or URL-encoded path of the user

Responses

CodeDescriptionSchema
204No Content—
400Bad Request—
404Not Found—

Schemas

Objects returned by the operations above and objects nested in their request bodies.

APIEntitiesCustomAttribute

PropertyTypeDescription
keyStringExample: foo
valueStringExample: bar