Update policy trust portal visibility
curl --request POST \
--url https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"showOnTrustPortal": true
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({showOnTrustPortal: true})
};
fetch('https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings"
payload = { "showOnTrustPortal": True }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "pol_abc123",
"name": "Information Security Policy",
"status": "published",
"showOnTrustPortal": false
}Trust Portal
Update policy trust portal visibility | Comp AI API
Shows or hides a policy on the public trust portal, separately from publishing. A switched-on policy appears only while it is published. New policies start.
POST
/
v1
/
trust-portal
/
policies
/
{policyId}
/
trust-settings
Update policy trust portal visibility
curl --request POST \
--url https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"showOnTrustPortal": true
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({showOnTrustPortal: true})
};
fetch('https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.trycomp.ai/v1/trust-portal/policies/{policyId}/trust-settings"
payload = { "showOnTrustPortal": True }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "pol_abc123",
"name": "Information Security Policy",
"status": "published",
"showOnTrustPortal": false
}Authorizations
API key for authentication
Path Parameters
Body
application/json
Whether this policy appears on the public trust portal. It is shown only while it is also published.
Example:
true
Response
200 - application/json
Example:
"pol_abc123"
Example:
"Information Security Policy"
Publishing status. Only published policies appear on the portal.
Available options:
draft, published, needs_review Example:
"published"
Whether the policy is switched on for the public trust portal. New policies start hidden.
Example:
false
Was this page helpful?

