API Documentation

Domain Rating History API

Preview available months or retrieve monthly Domain Rating history.

Test API

For rating history use cases and a live test, see the Domain Rating History API product page.

Domain Rating History API product page →

Endpoint

GET https://api.goanyapi.com/api/v1/dr-history

…

Authentication

Authorization: Bearer YOUR_API_KEY

Request Parameters

Parameter Type Required Description
domain string Yes Target domain, such as kviku.com
includeDr boolean No Defaults to false; set to true to return and charge for DR data

Additional query parameters are rejected. Boolean values must be exactly true or false.

Preview Available Months

Use preview mode to see the available months and the exact credits required for the full result. Preview mode deducts 0 credits.

GET /api/v1/dr-history?domain=kviku.com&includeDr=false
Authorization: Bearer YOUR_API_KEY
{
  "code": "ok",
  "message": "ok",
  "data": {
    "endpoint": "dr-history",
    "costCredits": 0,
    "query": {
      "domain": "kviku.com",
      "includeDr": false
    },
    "itemCount": 7,
    "history": [
      { "month": 202511 },
      { "month": 202512 },
      { "month": 202601 },
      { "month": 202602 },
      { "month": 202607 },
      { "month": 202608 },
      { "month": 202609 }
    ]
  }
}

The response also includes unitCostCredits, requiredCredits, and remainingCredits. requiredCredits is the exact amount needed to retrieve all ratings currently available for the domain.

Retrieve Domain Ratings

Set includeDr=true to retrieve each rating. The API calculates the exact required credits, checks the balance, deducts credits transactionally, and only then returns DR values.

GET /api/v1/dr-history?domain=kviku.com&includeDr=true
Authorization: Bearer YOUR_API_KEY
{
  "code": "ok",
  "message": "ok",
  "data": {
    "endpoint": "dr-history",
    "query": {
      "domain": "kviku.com",
      "includeDr": true
    },
    "itemCount": 7,
    "history": [
      { "month": 202511, "dr": 4.9 },
      { "month": 202512, "dr": 24 },
      { "month": 202601, "dr": 12 },
      { "month": 202602, "dr": 11 },
      { "month": 202607, "dr": 11 },
      { "month": 202608, "dr": 11 },
      { "month": 202609, "dr": 8 }
    ]
  }
}

The paid response also includes unitCostCredits, requiredCredits, costCredits, and remainingCredits. DR values can be decimals. If no history is available, the response contains itemCount: 0 and history: [], with 0 required and deducted credits.

Billing and Balance Protection

  • requiredCredits equals the current DR unit cost multiplied by the number of valid unique months
  • includeDr=false returns months and the exact requirement with costCredits=0
  • includeDr=true deducts requiredCredits and then returns ratings
  • An empty valid history costs 0 credits
  • If the balance is below requiredCredits, both modes return HTTP 402 with insufficient_credits and no months, counts, costs, or ratings

Response Fields

Field Description
data.endpoint Fixed value: dr-history
data.costCredits Credits deducted by this request
data.remainingCredits Credits remaining after this request
data.query.domain Normalized domain
data.query.includeDr Resolved boolean request mode
data.itemCount Number of valid unique months
data.unitCostCredits Current DR credit cost per returned month
data.requiredCredits Exact credits required for the complete result
data.history[].month Month in YYYYMM numeric format
data.history[].dr Domain Rating; present only when includeDr=true