POST/attachments/remove-icon

Remove an avatar or icon

Removes an avatar, space icon, or workspace icon. Set type to select the icon to remove and include spaceId when removing a space icon.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

2 body fields

JSON object specifying the type of icon to remove. Include spaceId when the type is space_icon.

spaceIdstringoptional
Required when `type` is `space_icon`. Identifies which space icon to remove.
typestringrequired
Type of icon to remove. `avatar`: user profile avatar. `space_icon`: space logo. `workspace_icon`: workspace logo.
Allowed:avatarspace_iconworkspace_icon

3 status codes
200Returns a response confirming that the icon was removed.
dataunknownoptional
Response payload
statusintegeroptional
successbooleanoptional
400Returned when the request fails validation, including when `type` is missing or invalid, or a required `spaceId` is missing.
errorstringoptional
Reason phrase, for example `Bad Request`.
messagestringoptional
statusCodeintegeroptional
403Returned when the authenticated user is not permitted to remove the specified icon.
errorstringoptional
Reason phrase, for example `Bad Request`.
messagestringoptional
statusCodeintegeroptional

Error handling

A 400 is returned when type is missing or is not one of the accepted values: avatar, space_icon, or workspace_icon. Include spaceId when type is space_icon. A 403 is returned when the authenticated user is not permitted to remove the specified icon.