Skip to main content
POST
/
asset
/
list
List assets
curl --request POST \
  --url https://app.chainpatrol.io/api/v2/asset/list \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '
{
  "type": "URL",
  "status": "BLOCKED",
  "startDate": "<string>",
  "endDate": "<string>",
  "per_page": 100,
  "next_page": "<string>"
}
'
{
  "assets": [
    {
      "content": "<string>",
      "type": "URL",
      "status": "UNKNOWN",
      "watchStatus": "ENABLED",
      "updatedAt": "<string>"
    }
  ],
  "next_page": "<string>"
}

Quick Start

Authentication

Include your API key in the X-API-KEY header:
X-API-KEY: <api-key>

Sync Strategy and Removals

When using time-based filtering (e.g., fetching only the last 5 minutes of blocklist data), you may miss asset removals from the blocklist. To ensure complete data consistency, use one of these approaches:
  1. Monitor allowlist and unknown list for removals: Check both the allowlist and unknown list endpoints periodically to detect assets that have been removed from the blocklist.
  2. Periodic full sync: Perform a complete sync of the full blocklist at regular intervals (e.g., hourly or daily) to catch any missed changes.
  3. Hybrid approach: Use time-based filtering for frequent updates combined with periodic full syncs for comprehensive coverage.

Why This Matters

Asset status changes can move assets between different lists (blocklist, allowlist, unknown). Time-based queries on a single endpoint may not capture these transitions, potentially leaving your local cache with outdated information about blocked assets that should no longer be blocked.

Pagination

To use pagination, include the per_page and next_page parameters in your request:
  • per_page <number>: Number of items to return per page (max: 10000)
  • next_page <string>: Cursor for the next page of results

Example implementation for pagination:

async function fetchAllAssets(type, status) {
  let allAssets = [];
  let nextPage = null;
  while (true) {
    const response = await fetch(
      "https://app.chainpatrol.io/api/v2/asset/list",
      {
        method: "POST",
        headers: {
          "Content-Type": "application/json",
          "X-API-KEY": "YOUR_API_KEY_HERE",
        },
        body: JSON.stringify({
          type,
          status,
          per_page: 500,
          next_page: nextPage,
        }),
      }
    );
    const data = await response.json();
    allAssets = allAssets.concat(data.assets);
    nextPage = data.next_page;
    if (!nextPage) {
      break;
    }
  }
  return allAssets;
}
fetchAllAssets("URL", "BLOCKED")
  .then((assets) => console.log("All assets:", assets))
  .catch((error) => console.error("Error fetching assets:", error));

Authorizations

X-API-KEY
string
header
required

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.

Body

application/json
type
enum<string>
required
Available options:
URL,
PAGE,
ADDRESS,
DISCORD,
LINKEDIN,
TWITTER,
FACEBOOK,
YOUTUBE,
REDDIT,
TELEGRAM,
GOOGLE_APP_STORE,
APPLE_APP_STORE,
AMAZON_APP_STORE,
MICROSOFT_APP_STORE,
TIKTOK,
INSTAGRAM,
THREADS,
MEDIUM,
CHROME_WEB_STORE,
MOZILLA_ADDONS,
OPERA_ADDONS,
EMAIL,
PATREON,
OPENSEA,
FARCASTER,
IPFS,
GOOGLE_FORM,
WHATSAPP,
DISCORD_USER,
QUORA,
GITHUB,
TEACHABLE,
SUBSTACK,
DEBANK,
TAWK_TO,
JOTFORM,
PRIMAL,
BLUESKY,
SNAPCHAT,
DESO,
PINTEREST,
FLICKR,
GALXE,
VELOG,
NPM,
PYPI,
HEX,
DOCKER_HUB,
VOCAL_MEDIA,
TECKFINE,
TENDERLY,
HACKMD,
ETSY,
ZAZZLE,
BASENAME,
BILIBILI_TV,
VIMEO,
DAILYMOTION,
PHONE_NUMBER,
SLACK,
CALENDLY,
NGROK,
RARIBLE,
RUST_PACKAGE,
FLATHUB,
VIDLII,
VEVIOZ,
ISSUU,
SOUNDCLOUD,
ZAPPER,
REDNOTE,
SAMSUNG_APP_STORE,
HUAWEI_APP_STORE,
XIAOMI_APP_STORE,
TENCENT_APP_STORE,
OPPO_APP_STORE,
VIVO_APP_STORE,
F_DROID,
GOOGLE_AD,
BING_AD,
TWITCH,
BEHANCE
status
enum<string>
default:BLOCKED
Available options:
UNKNOWN,
ALLOWED,
BLOCKED
startDate
string
endDate
string
per_page
integer
default:100
Required range: 1 <= x <= 10000
next_page
string | null

Response

Successful response

assets
object[]
required
next_page
string | null