Overview

The Dispute Create endpoint allows you to create a new dispute for an asset that has been reported or blocked. This is useful when you believe an asset has been incorrectly flagged or if you want to contest a blocking decision.

Authentication

This endpoint requires an API key. Include your API key in the request headers.

X-API-KEY: your_api_key_here

Request

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: "[email protected]", // 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);

Request Parameters

ParameterTypeRequiredDescription
contentstringYesThe URL or content identifier that you want to dispute
emailstringNo*Contact email for the dispute. Required if the API key is not associated with a user that has an email
descriptionstringNoAdditional details or explanation for the dispute

Response

{
  "id": "12345",
  "content": "https://example-phishing-site.com"
}

Response Parameters

ParameterTypeDescription
idstringThe unique identifier for the created dispute
contentstringThe content (URL) that was disputed
messagestringOptional message providing additional information

Errors

Status CodeError CodeDescription
400BAD_REQUESTInvalid input parameters or a dispute already exists for this asset with the provided email
401UNAUTHORIZEDMissing or invalid API key
404NOT_FOUNDThe specified asset does not exist

Notes

  • A dispute can only be created once per email address for a specific asset
  • If the asset is only blocked in EthPhishingDetect but not in ChainPatrol, a note will automatically be added to the dispute
  • All disputes created via the API will have a system note indicating they were created via the API