Skip to content
Start here

Get queries

client.brandProtection.v2.queries.get(QueryGetParams { account_id, id } params, RequestOptionsoptions?): QueryGetResponse { created, parameters, query_id, 3 more }
GET/accounts/{account_id}/cloudforce-one/v2/brand-protection/domain/queries

Get all saved brand protection queries for an account

Security

API Token

The preferred authorization scheme for interacting with the Cloudflare API. Create a token.

Example:Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY
Accepted Permissions (at least one required)
Cloudforce One WriteCloudforce One Read
ParametersExpand Collapse
params: QueryGetParams { account_id, id }
account_id: string

Path param

minLength1
id?: string

Query param

ReturnsExpand Collapse
QueryGetResponse = Array<QueryGetResponseItem>
created: string
parameters: Parameters | null
string_matches: Array<StringMatch>
max_edit_distance: number
maximum1
minimum0
pattern: string
minLength1
max_time?: string
min_time?: string
query_id: number
query_tag: string
scan: boolean
updated: string

Get queries

import Cloudflare from 'cloudflare';

const client = new Cloudflare({
  apiToken: process.env['CLOUDFLARE_API_TOKEN'], // This is the default and can be omitted
});

const queries = await client.brandProtection.v2.queries.get({ account_id: 'x' });

console.log(queries);
[
  {
    "created": "created",
    "parameters": {
      "string_matches": [
        {
          "max_edit_distance": 0,
          "pattern": "x"
        }
      ],
      "max_time": "max_time",
      "min_time": "min_time"
    },
    "query_id": 0,
    "query_tag": "query_tag",
    "scan": true,
    "updated": "updated"
  }
]
Returns Examples
[
  {
    "created": "created",
    "parameters": {
      "string_matches": [
        {
          "max_edit_distance": 0,
          "pattern": "x"
        }
      ],
      "max_time": "max_time",
      "min_time": "min_time"
    },
    "query_id": 0,
    "query_tag": "query_tag",
    "scan": true,
    "updated": "updated"
  }
]