Scripts
Publish Script to Website
Use this API to publish the script configuration options for the specified website.
👍
For more information, see Publishing and Implementing Cookie Consent Scripts.
put/api/cmp/v1/domains/publish
Request
- Base URLhttps://hostname
- URLhttps://hostname/api/cmp/v1/domains/publish
- AuthOAuth 2Client credentialsToken URL: https://{hostname}/api/access/v1/oauth/token scopes: COOKIE, COOKIE_READ
Query parameters
scriptType'production' | 'test'
The type of script either production or test.
websitestring required
The website domain to target for the operation.
Request body
Example request
{
"scriptVersion": "202607.1.0",
"languages": [
"Irish",
"English - United States of America",
"Greek"
],
"publishIndividualLanguages": true,
"requireReconsent": true,
"regionRules": [
{
"ruleId": "f2229953-b4b5-4042-8cb9-b78038cc4c46",
"ruleName": "Global"
},
{
"ruleId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"ruleName": "Europe"
}
],
"gaAssignCategory": "C0001"
}Response
OK
Example response
{
"responseMsg": "Publish initiated successfully!",
"publishVersion": "202503.2.0",
"consentPolicyName": "Default Consent Policy",
"autoBlocking": true,
"reconsentRequired": true,
"publishedDate": "2025-05-29T14:53:00Z",
"userName": "User user"
}Changes
No recorded changes to this operation across all 1 revision of this API.