Assign or Remove Tags Beta
Attach or detach tags on up to 1,000 resources.
https://api.foxreach.io/ api/ v1/ tags/ toggleRequires an API key with the write scope.
Attaches (assign: true) or detaches (assign: false) up to 10 tags on up to 1,000 leads, campaigns or email accounts in one call. Every tag must be of the matching type: lead tags for lead, campaign tags for campaign, account tags for email_account. A warmup tag, a tag of another workspace or a tag of the wrong type returns 422 and nothing changes. Resource ids that are not in the workspace (or are deleted leads) do not fail the call: they are listed in notFound and the rest apply. Attaching a tag that is already on a resource changes nothing. For more than 1,000 leads use Bulk Tag Leads. An audit.tag.assigned or audit.tag.unassigned entry records the tags and the counts.
Request Body
tagIds string[] body required resourceType string body required lead, campaign or email_account.resourceIds string[] body required assign boolean body required true attaches, false detaches.Response
assigned (or unassigned) is how many tag and resource pairs changed, matched how many of the ids were found, notFound the ids that were not.
Errors
| Status | Description |
|---|---|
401 | Missing, invalid, revoked or expired API key |
403 | API key does not have the required scope: write |
422 | A tag is not a tag of this type in the workspace, a list is empty, or more than 1,000 resource ids were sent |
Rate Limit
- 120 requests per minute, shared by every
writecall in your workspace. Fixed 60-second window. - Every response includes
X-RateLimit-Limit,X-RateLimit-Remaining,X-RateLimit-Reset(unix epoch seconds) andX-RateLimit-Bucket(write). - A
429response includes aRetry-Afterheader (seconds until the bucket resets).
For client-side patterns, see Rate Limiting.