> ## Documentation Index
> Fetch the complete documentation index at: https://api.smartlead.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Add Tags to Lead

> Assign one or more tags to a specific lead

## Request Body

<ParamField body="leadId" type="number" required>
  The lead ID to add tags to
</ParamField>

<ParamField body="tagIds" type="array" required>
  Array of tag IDs to assign to the lead
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://server.smartlead.ai/api/v1/crm/leads/tags?api_key=YOUR_KEY" \
    -H "Content-Type: application/json" \
    -d '{"leadId": 123, "tagIds": [1, 2, 3]}'
  ```
</RequestExample>

## Response Codes

<ResponseField name="200" type="Success">
  Request successful
</ResponseField>

<ResponseField name="400" type="Bad Request">
  Invalid request parameters or malformed request body
</ResponseField>

<ResponseField name="401" type="Unauthorized">
  Invalid or missing API key
</ResponseField>

<ResponseField name="422" type="Validation Error">
  Request validation failed. Check parameter types and constraints.
</ResponseField>

<ResponseExample>
  ```json 200 - Success theme={null}
  {
    "ok": true,
    "message": "Tags added to lead successfully"
  }
  ```

  ```json 401 - Unauthorized theme={null}
  {
    "message": "Invalid API Key"
  }
  ```
</ResponseExample>
