Module avatars_api

Module avatars_api 

Source

Enums§

DeleteAvatarError
struct for typed errors of method delete_avatar
GetAllSystemAvatarsError
struct for typed errors of method get_all_system_avatars
GetAvatarsError
struct for typed errors of method get_avatars
StoreAvatarError
struct for typed errors of method store_avatar

Functions§

delete_avatar
Deletes an avatar from a project or issue type. Permissions required: Administer Jira global permission.
get_all_system_avatars
Returns a list of system avatar details by owner type, where the owner types are issue type, project, or user. This operation can be accessed anonymously. Permissions required: None.
get_avatars
Returns the system and custom avatars for a project or issue type. This operation can be accessed anonymously. Permissions required: * for custom project avatars, Browse projects project permission for the project the avatar belongs to. * for custom issue type avatars, Browse projects project permission for at least one project the issue type is used in. * for system avatars, none.
store_avatar
Loads a custom avatar for a project or issue type. Specify the avatar’s local file location in the body of the request. Also, include the following headers: * X-Atlassian-Token: no-check To prevent XSRF protection blocking the request, for more information see Special Headers. * Content-Type: image/image type Valid image types are JPEG, GIF, or PNG. For example: curl --request POST --user email@example.com:<api_token> --header 'X-Atlassian-Token: no-check' --header 'Content-Type: image/< image_type>' --data-binary \"<@/path/to/file/with/your/avatar>\" --url 'https://your-domain.atlassian.net/rest/api/2/universal_avatar/type/{type}/owner/{entityId}' The avatar is cropped to a square. If no crop parameters are specified, the square originates at the top left of the image. The length of the square’s sides is set to the smaller of the height or width of the image. The cropped image is then used to create avatars of 16x16, 24x24, 32x32, and 48x48 in size. After creating the avatar use: * Update issue type to set it as the issue type’s displayed avatar. * Set project avatar to set it as the project’s displayed avatar. Permissions required: Administer Jira global permission.