Capability Sources

Archive, unarchive, mark read or unread, star or change Gmail message labels

Changed on

Changes labels on one message. Archive removes INBOX; unarchive adds INBOX; mark read removes UNREAD; mark unread adds UNREAD; star adds STARRED; unstar removes STARRED. Supports user label IDs from gmail-labels. Requires gmail.modify, not gmail.labels or gmail.compose. Uses only the calling member's selected connected Google account. Perform writes only when explicitly requested by the user; capability discovery or selection is not authorization. Never automatically retry an uncertain write.

post/v1/capabilities/google-workspace/gmail-message/{messageId}/modify

Request

  • Base URL
    https://api.openworklabs.com
  • URL
    https://api.openworklabs.com/v1/capabilities/google-workspace/gmail-message/{messageId}/modify
  • Auth
    • API key in header x-api-key
    • or HTTP bearer

Path parameters

messageIdstring required

Request body

addLabelIdsstring[]

Add INBOX to unarchive, UNREAD to mark unread, STARRED to star, or user label IDs. Use the dedicated trash action for TRASH.

removeLabelIdsstring[]

Remove INBOX to archive, UNREAD to mark read, STARRED to unstar, or user label IDs. Use the dedicated untrash action for TRASH.

Response

Google's validated response.

idstring required
threadIdstring required

Changes

    • info

      response property details/items/path/items/ list-of-types was narrowed by removing types number from media type application/json of response 400

    • info

      added the optional property to the response with the status