CompetitorUpdate Competitor

Update Competitor

Change a competitor of a domain. Rename it, replace its name variations, or change its active or dedicated state.

curl --request POST \
  --url 'https://api.aiclicks.io/api/v1/competitors/update' \
  --header 'Authorization: Bearer ak_live_xxx' \
  --header 'Content-Type: application/json' \
  --data '{
    "competitor_id": "f6a7b8c9-3333-4eee-8fff-000000000001",
    "competitor_name": "Acme Rival",
    "competitor_variations": ["Acme", "AcmeRival Inc"],
    "is_dedicated": true,
    "active": true
  }'
{
  "data": {
    "message": "Competitor updated successfully",
    "competitor": {
      "id": "f6a7b8c9-3333-4eee-8fff-000000000001",
      "created_at": "2026-08-18T10:00:11.218Z",
      "domain_id": "8f1d3c0a-2f9b-4c11-9b80-7a82e1f0c3f3",
      "name": "Acme Rival",
      "website": "acmerival.com",
      "is_dedicated": true,
      "active": true,
      "updated_at": "2026-11-09T09:12:40.511Z",
      "variations": ["Acme", "AcmeRival Inc"]
    }
  },
  "generated_at": "2026-11-09T09:12:40.602Z"
}

This endpoint changes one competitor row. Send the competitor_id and only the fields to change. The endpoint does not change fields that you do not send.

Get the competitor_id from GET /api/v1/competitors. The endpoint finds the domain from the competitor, so you do not send a domain_id.

A competitor is tracked when is_dedicated and active are both true. If an update makes an untracked competitor tracked, the endpoint checks the dedicated-competitor limit of the domain. If the domain is at the limit, the endpoint returns 400.

You cannot change the website of a competitor with this endpoint. To change the website, add a new competitor with POST /api/v1/competitors.

Authorizations

header
Authorizationstring
Required

Your API key in the format Bearer ak_live_<your-key>. Create a key in the dashboard under Settings → Developers.

header
X-Request-Idstring

An optional UUID for log correlation. If you do not send one, the server makes one and returns it in the response.

Body parameters

body
competitor_idstring
Required

The UUID of the competitor to change. Get it from GET /api/v1/competitors.

body
competitor_namestring

The new display name, for example "Acme Rival".

body
competitor_variationsarray

The new list of alternative names and spellings. This list replaces the old list. The server removes duplicates without regard to letter case. Send [] to remove all variations.

body
is_dedicatedboolean

Set true to make the competitor a dedicated brand. Set false to make it a plain entry.

body
activeboolean

Set true to track the competitor. Set false to stop tracking it. The row and its history stay.

Send at least one field in addition to competitor_id. If you send no field to change, the endpoint returns 400.

Response

dataobject
Required

The result of the update.

messagestring
Required

The status text, "Competitor updated successfully".

competitorobject
Required

The competitor row after the update. It has the same fields as the competitor object in POST /api/v1/competitors: id, created_at, domain_id, name, website, is_dedicated, active, updated_at and variations.

generated_atstring
Required

The ISO-8601 time when the server made this response.

Response headers

HeaderDescription
X-Request-IdThe request id. If you sent one, the server returns it.
X-RateLimit-LimitThe maximum number of requests per minute for this key.
X-RateLimit-RemainingThe number of requests that remain in this minute.
X-RateLimit-ResetThe Unix time in seconds when the window starts again.

Caching

This endpoint is not cached. A successful update clears the cached competitor data of the domain. The next read shows the change.

Errors

400 Bad Requesterror

The request has no field to change. Or the update makes the competitor tracked and the domain is at its dedicated-competitor limit. If a field has the wrong type, the endpoint returns 422.

401 Unauthorizederror

The API key is missing, malformed or revoked.

403 Forbiddenerror

The developer_access flag of the team is off. Or the domain of the competitor is not in the scope of your key. Or your user is not a member of the team that owns the domain.

404 Not Founderror

No competitor has this competitor_id.

429 Too Many Requestserror

You sent too many requests. Read the Retry-After header to know how long to wait.