{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/unifapi-com/json-schema/unifapi-com-seo-backlinks-domain-pages-request-schema.json",
  "title": "SeoBacklinksDomainPagesRequest",
  "x-generated": "2026-11-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/unifapi-com-openapi.yml#/components/schemas/SeoBacklinksDomainPagesRequest",
  "type": "object",
  "properties": {
    "target": {
      "type": "string",
      "minLength": 1,
      "maxLength": 2048,
      "description": "Domain, subdomain, or page to analyze. A domain or subdomain is specified without https:// and www. (example.com); a page is specified as an absolute URL (https://example.com/blog/)."
    },
    "backlinks_status_type": {
      "$ref": "#/$defs/SeoBacklinksStatusType"
    },
    "include_subdomains": {
      "type": "boolean",
      "description": "Include backlinks pointing to the target's subdomains. Defaults to true."
    },
    "exclude_internal_backlinks": {
      "type": "boolean",
      "description": "Exclude internal backlinks from the target's own subdomains. Defaults to true."
    },
    "internal_list_limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 1000,
      "description": "Maximum number of entries kept in each referring_links_* breakdown map. Defaults to 10."
    },
    "rank_scale": {
      "$ref": "#/$defs/SeoBacklinksRankScale"
    },
    "filters": {
      "anyOf": [
        {
          "$ref": "#/$defs/DataForSeoFilterCondition"
        },
        {
          "type": "object",
          "properties": {
            "and": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions that must all match."
            }
          },
          "required": [
            "and"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "or": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions where at least one must match."
            }
          },
          "required": [
            "or"
          ],
          "additionalProperties": false
        }
      ],
      "description": "Filter the returned target pages. Provide a single condition {\"field\",\"op\",\"value\"} or an {\"and\":[…]} / {\"or\":[…]} group of conditions (nest groups for mixed logic), up to 8 conditions. Operators: =, <>, <, <=, >, >=, in, not_in, like, not_like, ilike, not_ilike, match, not_match (use an array value with in / not_in). Filterable fields: url (page URL on the target); status_code (last HTTP status code of the page); size (page size in bytes); media_type (media type, e.g. text/html); first_visited (ISO date first crawled); fetch_time (ISO date last crawled); rank (backlink rank, 0-1000); backlinks (number of backlinks); backlinks_spam_score (average spam score, 0-100); referring_domains (referring domains count); referring_main_domains (referring root domains count); referring_pages (referring pages count); referring_ips (referring IPs count); referring_subnets (referring subnets count); broken_backlinks (backlinks to broken pages); broken_pages (broken pages still receiving backlinks); first_seen (ISO date the first backlink was found); lost_date (ISO date the last backlink was lost). Example: {\"and\":[{\"field\":\"referring_domains\",\"op\":\">\",\"value\":5},{\"field\":\"status_code\",\"op\":\"=\",\"value\":200}]}"
    },
    "backlinks_filters": {
      "anyOf": [
        {
          "$ref": "#/$defs/DataForSeoFilterCondition"
        },
        {
          "type": "object",
          "properties": {
            "and": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions that must all match."
            }
          },
          "required": [
            "and"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "or": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions where at least one must match."
            }
          },
          "required": [
            "or"
          ],
          "additionalProperties": false
        }
      ],
      "description": "Filter the underlying individual backlinks before the aggregate metrics are computed. Provide a single condition {\"field\",\"op\",\"value\"} or an {\"and\":[…]} / {\"or\":[…]} group of conditions (nest groups for mixed logic), up to 8 conditions. Operators: =, <>, <, <=, >, >=, in, not_in, like, not_like, ilike, not_ilike, match, not_match (use an array value with in / not_in). Filterable fields: dofollow (boolean, link is dofollow); is_new (boolean, appeared since the last check); is_lost (boolean, lost since the last check); is_broken (boolean, points to a broken page); rank (referring page rank, 0-1000); page_from_rank (referring page rank, 0-1000); domain_from_rank (referring domain rank, 0-1000); backlink_spam_score (spam score of the referring page, 0-100); item_type (anchor, image, link, redirect, or canonical); anchor (anchor text); tld_from (top-level domain of the referring page); semantic_location (link location, e.g. article, footer); first_seen (ISO date the backlink was first seen); last_seen (ISO date the backlink was last seen). Example: {\"and\":[{\"field\":\"dofollow\",\"op\":\"=\",\"value\":true},{\"field\":\"backlink_spam_score\",\"op\":\"<\",\"value\":10}]}"
    },
    "order_by": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/DataForSeoOrderByRule"
      },
      "minItems": 1,
      "maxItems": 3,
      "description": "Sort the returned target pages. Each rule is {\"field\",\"dir\"} with dir asc or desc; up to 3 rules, applied in order. Sortable fields: url, status_code, size, media_type, first_visited, fetch_time, rank, backlinks, backlinks_spam_score, referring_domains, referring_main_domains, referring_pages, referring_ips, referring_subnets, broken_backlinks, broken_pages, first_seen, lost_date."
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 1000,
      "description": "Maximum number of records to return. Defaults to 100."
    },
    "offset": {
      "type": "integer",
      "minimum": 0,
      "description": "Number of records to skip from the start of the results."
    },
    "view": {
      "allOf": [
        {
          "$ref": "#/$defs/SeoBacklinksView"
        },
        {
          "description": "Controls metric depth. summary keeps the headline counters; full adds nofollow variants and the referring_links_* breakdown maps. Defaults to summary."
        }
      ]
    }
  },
  "required": [
    "target"
  ],
  "$defs": {
    "DataForSeoFilter": {
      "anyOf": [
        {
          "$ref": "#/$defs/DataForSeoFilterCondition"
        },
        {
          "type": "object",
          "properties": {
            "and": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions that must all match."
            }
          },
          "required": [
            "and"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "or": {
              "type": "array",
              "items": {
                "$ref": "#/$defs/DataForSeoFilter"
              },
              "minItems": 2,
              "description": "Sub-expressions where at least one must match."
            }
          },
          "required": [
            "or"
          ],
          "additionalProperties": false
        }
      ]
    },
    "DataForSeoFilterCondition": {
      "type": "object",
      "properties": {
        "field": {
          "type": "string",
          "minLength": 1,
          "description": "Field to filter on. See the endpoint's list of filterable fields."
        },
        "op": {
          "type": "string",
          "enum": [
            "=",
            "<>",
            "<",
            "<=",
            ">",
            ">=",
            "in",
            "not_in",
            "like",
            "not_like",
            "ilike",
            "not_ilike",
            "match",
            "not_match"
          ],
          "description": "Comparison operator."
        },
        "value": {
          "$ref": "#/$defs/DataForSeoFilterValue"
        }
      },
      "required": [
        "field",
        "op",
        "value"
      ],
      "additionalProperties": false
    },
    "DataForSeoFilterValue": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "boolean"
        },
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              },
              {
                "type": "boolean"
              }
            ]
          },
          "minItems": 1
        }
      ],
      "description": "Comparison value: a string, number, or boolean for scalar operators, or a non-empty array for \"in\" / \"not_in\"."
    },
    "DataForSeoOrderByRule": {
      "type": "object",
      "properties": {
        "field": {
          "type": "string",
          "minLength": 1,
          "description": "Field to sort by. See the endpoint's list of sortable fields."
        },
        "dir": {
          "type": "string",
          "enum": [
            "asc",
            "desc"
          ],
          "default": "desc",
          "description": "Sort direction: asc or desc. Defaults to desc."
        }
      },
      "required": [
        "field"
      ],
      "additionalProperties": false
    },
    "SeoBacklinksRankScale": {
      "type": "string",
      "enum": [
        "one_hundred",
        "one_thousand"
      ],
      "description": "Scale for rank values: one_thousand (0-1000, default) or one_hundred (0-100)."
    },
    "SeoBacklinksStatusType": {
      "type": "string",
      "enum": [
        "live",
        "all",
        "lost"
      ],
      "description": "Which backlinks to count: live (found on the last check, default), all, or lost."
    },
    "SeoBacklinksView": {
      "type": "string",
      "enum": [
        "summary",
        "full"
      ]
    }
  }
}