Create Label
Creates a new label to help categorize and organize your social media posts. Labels can be used to group related content together for better organization and filtering.
Request
The ID of the workspace where the label will be created
Hex color code for the label (e.g., “#ff0000” for red)
{
"workspace_id": 1,
"name": "Product Launch",
"color": "#ff0000"
}
Response
Unique identifier for the created label
The hex color code of the label
Information about the label’s workspace
Creation timestamp in workspace timezone
Last update timestamp in workspace timezone
{
"id": 16,
"name": "Product Launch",
"color": "#ff0000",
"workspace": {
"id": 12,
"name": "abdulmejidshemsuawel",
"slug": "abdulmejidshemsuawel",
"type": "PERSONAL",
"logo": null,
"timezone": "Africa/Addis_Ababa",
"language": "en"
}
}
Code Examples
curl -X POST "https://postsyncer.com/api/v1/labels" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"workspace_id": 1,
"name": "Product Launch",
"color": "#ff0000"
}'
Error Codes
Validation errors or invalid parameters
Missing or invalid API token
Token does not have ‘labels’ permission
Workspace not found or user does not have access to the workspace
Validation errors in request data