RankPilot API

Send an API key as a Bearer token. Every response carries data_through, coverage and rate-limit headers; limits are shared by every key of a workspace.

Properties

GET/properties

Properties this credential can read

Parameters of GET /properties
NameInTypeRequired
limitqueryinteger 1-1000no
cursorquerystringno

curl

curl -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  "https://rank.hanzla.com/api/v1/properties"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties", {
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
  },
});
console.log(await res.json());

POST/propertiesWrite key, Pro

Put a discovered Search Console property on the dashboard

Parameters of POST /properties
NameInTypeRequired
Idempotency-Keyheaderstringno

curl

curl -X POST -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"site_url":"<site_url>"}' \
  "https://rank.hanzla.com/api/v1/properties"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({"site_url":"<site_url>"}),
});
console.log(await res.json());

GET/properties/{id}

One property

Parameters of GET /properties/{id}
NameInTypeRequired
idpathstringyes

curl

curl -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  "https://rank.hanzla.com/api/v1/properties/<property-id>"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>", {
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
  },
});
console.log(await res.json());

PATCH/properties/{id}Write key, Pro

Rename a property

Parameters of PATCH /properties/{id}
NameInTypeRequired
idpathstringyes

curl

curl -X PATCH -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"display_name":"<display_name>"}' \
  "https://rank.hanzla.com/api/v1/properties/<property-id>"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>", {
  method: "PATCH",
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({"display_name":"<display_name>"}),
});
console.log(await res.json());

GET/properties/{id}/annotations

Annotations of a property

Parameters of GET /properties/{id}/annotations
NameInTypeRequired
idpathstringyes
limitqueryinteger 1-1000no
cursorquerystringno
fromquerystring (date)no
toquerystring (date)no

curl

curl -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  "https://rank.hanzla.com/api/v1/properties/<property-id>/annotations"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>/annotations", {
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
  },
});
console.log(await res.json());

POST/properties/{id}/annotationsWrite key, Pro

Add an annotation

Parameters of POST /properties/{id}/annotations
NameInTypeRequired
idpathstringyes
Idempotency-Keyheaderstringno

curl

curl -X POST -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"date":"<date>","end_date":"<end_date>","title":"<title>","body":"<body>","category":"<category>"}' \
  "https://rank.hanzla.com/api/v1/properties/<property-id>/annotations"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>/annotations", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({"date":"<date>","end_date":"<end_date>","title":"<title>","body":"<body>","category":"<category>"}),
});
console.log(await res.json());

DELETE/properties/{id}/annotations/{annotationId}Write key, Pro

Delete an annotation

Parameters of DELETE /properties/{id}/annotations/{annotationId}
NameInTypeRequired
idpathstringyes
annotationIdpathstringyes

curl

curl -X DELETE -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  "https://rank.hanzla.com/api/v1/properties/<property-id>/annotations/<annotationId>"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>/annotations/<annotationId>", {
  method: "DELETE",
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
  },
});
console.log(await res.json());

POST/properties/{id}/syncWrite key, Pro

Ask for a fresh Search Console pull (once per 15 minutes per property)

Parameters of POST /properties/{id}/sync
NameInTypeRequired
idpathstringyes

curl

curl -X POST -H "Authorization: Bearer $RANKPILOT_API_KEY" \
  "https://rank.hanzla.com/api/v1/properties/<property-id>/sync"

Node

const res = await fetch("https://rank.hanzla.com/api/v1/properties/<property-id>/sync", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.RANKPILOT_API_KEY}`,
  },
});
console.log(await res.json());