Skip to main content

Updating a Specific Cookie

To modify a specific cookie, you can use a PATCH request sent to the following endpoint:

https://api.platform.illow.io/open-api/v1/cookies/{siteId}/cookie/{cookieName}

This endpoint accepts the following attributes as query parameters:

Query Parameters

PropertyTypeDescription
siteIdstringThe unique site ID assigned by illow.
cookieNamestringThe name of the cookie to be updated.

Request Body

The request body should be in JSON format and should include only the specific cookie information you wish to update. The structure of the request body should match this definition

Response

The API will return one of the following HTTP status codes:

  • 200: Successfully updated the company's cookies for the site.

Response Format: JSON

See cookie definition.

  • 404: The requested cookie was not found.
  • 500: Internal server error. The request has failed.

Example

The following example illustrates a PATCH request for updating the 'session_id' cookie, specifically changing its domain:

Request Body

{
"name": "session_id",
"domain": "example.com"
}

Response body

{
"name": "session_id",
"domain": "example.com",
"expires": 1689467134,
"category": "Statistics",
"description": "This cookie collects statistical data for website analytics.",
"isOptIn": true,
"wildcardMatch": false
}