Content Security Policy (CSP) Endpoint
The Content Security Policy (CSP) endpoint allows you to view a list of configured CSPs or view an individual CSP for a specific site.
List CSPs for One Site
Returns a list of all CSPs configured for one site with the specified prefix.
Endpoint
GET /content-security-policies?prefix=[:prefix]
Required Parameters
Example
curl -X GET "https://api.bluetriangletech.com/content-security-policies?prefix=demo" \
-H "X-API-Email: email@company.com" \
-H "X-API-Key: 2831ac6dffec75a48fe712345e000481" \
-H "Content-Type: application/json" \
View CSP by ID
Returns the CSP with the specified ID.
Endpoint
GET /content-security-policies?id=[:id]
Required Parameters
Example
curl -X GET "https://api.bluetriangletech.com/content-security-policies?id=123" \
-H "X-API-Email: email@company.com" \
-H "X-API-Key: 2831ac6dffec75a48fe712345e000481" \
-H "Content-Type: application/json" \
Example Response
[
{
"id": "1539186539",
"name": "asdf",
"version": "1",
"metaTag": null,
"responseHeader": null
},
...]
View CSP by Version
Returns the CSP with the specified version.
Endpoint
GET /content-security-policies?version=[:version]
Required Parameters
Example
curl -X GET "https://api.bluetriangletech.com/content-security-policies?id=123&version=15 " \
-H "X-API-Email: email@company.com" \
-H "X-API-Key: 2831ac6dffec75a48fe712345e000481" \
-H "Content-Type: application/json" \
Please sign in to leave a comment.
Comments
0 comments