Get all labels
Purpose
This API is used to list all the labels created under a particular account.
OAuth Scope
Use the scope
MailApps.tags.ALL (or) MailApps.tags.READ
ALL - Full access to labels.
READ - Fetch all labels.
To generate Authtoken, refer here.
Request URL
Method: GET
https://mail360.zoho.com/api/accounts/{account_key}/labels
Path Parameters
- account_key* string
- This key is used to identify the mailbox. It is generated during account addition.
- This parameter can be fetched from Get all accounts API.
Sample Request
Copiedcurl "https://mail360.zoho.com/api/accounts/x7k**EB00s/labels" \
-X GET \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization:Zoho-oauthtoken 80243**b4ac3" \
Sample Response
Copied{
"status": {
"code": 200,
"description": "success"
},
"data": [
{
"labelId": "27684000000021003",
"displayName": "L1",
"color": "#FFD700",
"sequence": 1
},
{
"labelId": "27684000000021006",
"displayName": "L3",
"color": "#0000FF",
"sequence": 2
}
]
}