curl --request POST \
--url https://app.chainpatrol.io/api/v2/dispute/create \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"content": "<string>",
"email": "jsmith@example.com",
"description": "<string>"
}
'{
"id": "<string>",
"content": "<string>",
"message": "<string>"
}Create a new dispute for an asset via the external API. Requires API key.
curl --request POST \
--url https://app.chainpatrol.io/api/v2/dispute/create \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"content": "<string>",
"email": "jsmith@example.com",
"description": "<string>"
}
'{
"id": "<string>",
"content": "<string>",
"message": "<string>"
}X-API-KEY header:
X-API-KEY: <api-key>
const response = await fetch(
"https://app.chainpatrol.io/api/v2/dispute/create",
{
method: "POST",
headers: {
"Content-Type": "application/json",
"X-API-KEY": "YOUR_API_KEY_HERE",
},
body: JSON.stringify({
content: "https://example-phishing-site.com",
email: "contact@yourdomain.com", // Optional if the API key is associated with a user that has an email
description:
"This is not a phishing site, it's our legitimate marketing site.", // Optional
}),
}
);
const data = await response.json();
console.log(data);
| Parameter | Type | Required | Description |
|---|---|---|---|
content | string | Yes | The URL or content identifier that you want to dispute |
email | string | No* | Contact email for the dispute. Required if the API key is not associated with a user that has an email |
description | string | No | Additional details or explanation for the dispute |
{
"id": "12345",
"content": "https://example-phishing-site.com"
}
| Parameter | Type | Description |
|---|---|---|
id | string | The unique identifier for the created dispute |
content | string | The content (URL) that was disputed |
message | string | Optional message providing additional information |
| Status Code | Error Code | Description |
|---|---|---|
| 400 | BAD_REQUEST | Invalid input parameters or a dispute already exists for this asset with the provided email |
| 401 | UNAUTHORIZED | Missing or invalid API key |
| 404 | NOT_FOUND | The specified asset does not exist |
Your API key. This is required by most endpoints to access our API programatically. Reach out to us at support@chainpatrol.io to get an API key for your use.
Was this page helpful?