---
title: "POST /api/v1/link-gaps/quote"
method: POST
path: "/api/v1/link-gaps/quote"
---

# POST /api/v1/link-gaps/quote

`POST /api/v1/link-gaps/quote`

## Request

- Base URL: `https://12backlinks.com`
- URL: `https://12backlinks.com/api/v1/link-gaps/quote`
- Auth: HTTP bearer

Quote a competitor link export: which referring domains (sites linking) your competitors have and your site does not. Free, nothing is launched. Three entries: analysis_id (competitors taken from an analysis of one of your batches), batch_id (competitors taken from all the done analyses of one of your batches, each site once) or an explicit list of competitors; without analysis_id or batch_id the quote calls the backlink provider and counts towards 30 paid calls per hour per account (counts already cached are free). Returns max_credits, the most the export can cost: per site, 1 credit up to 100 referring domains, then 2 credits per started block of 1,000, counted on min(depth, referring domains spam included); your site is always taken entirely; velocity adds 1 credit per site. The export is charged on the non spam domains actually delivered and the rest is refunded. Show max_credits to the user and get their approval before launch_link_gap.

## Request body

- object
  - `target` string, required: Your site: a domain (example.com) or a URL. It is always fetched entirely. A URL other than the home page also measures that page when velocity is true.
  - `analysis_id` string: Keyword entry: the analysis_id of a done analysis from one of your batches (see get_batch). Its ranking sites are the competitors to choose from. Not with batch_id.
  - `batch_id` string: Batch entry: the batch_id of one of your batches (see list_batches). The competitors to choose from are the ranking sites of all its done analyses, merged by root domain: a site ranking on several keywords is fetched and charged once. The batch must be finished (get_batch with wait=40 until it is done). Not with analysis_id.
  - `competitors` union[]: Domains or URLs, reduced to their root domain; or objects {domain, depth} to set a depth per site. Required without analysis_id or batch_id (1 to 20 competitors after removing duplicates and your own site). With analysis_id: optional, only sites of that analysis; when absent, the top 10 sites selected like on the website (with referring domains, at most 20,000 each). With batch_id: optional, only sites of its done analyses (30 at most); when absent, selected like on the website: up to 10 sites in the top 10 of at least 2 keywords, completed with the next top 10 sites when fewer than 3 (same filters).
    - union
      - string
      - object
        - `domain` string, required
        - `depth` union
          - 100
          - 1000
          - 'all'
  - `depth` union: Referring domains fetched per competitor, strongest first: 100, 1000 or "all". Default 1000.
    - 100
    - 1000
    - 'all'
  - `velocity` boolean: Also fetch the referring domains gained and lost per month over 24 months for each site (spam included): +1 credit per site, refunded when unavailable. Default false.

## Response `200`

Success.

- object
  - `origin` 'keyword' | 'list' | 'bulk'
  - `target` string
  - `analysis_id` string, nullable
  - `keyword` string, nullable
  - `batch_id` string: Only when origin is bulk.
  - `keywords_used` integer: Only when origin is bulk: keywords whose analysis is done (the ones used).
  - `keywords_total` integer: Only when origin is bulk: keywords in the batch.
  - `sites` object[]
    - `domain` string
    - `position` integer, nullable: Best position (in the batch when origin is bulk).
    - `keywords` integer: Only when origin is bulk: keywords of the batch where this site ranks in the top 10.
    - `is_target` boolean: true for your own site.
    - `depth` union: 100, 1000 or "all".
      - 100 | 1000
      - 'all'
    - `raw_referring_domains` integer, nullable: Referring domains of the root domain, spam included; null when unknown.
    - `raw_known` boolean
    - `max_credits` integer: Maximum credits of the links of this site (velocity excluded).
    - `max_domains` integer: Referring domains at most, spam included.
    - `velocity_credits` integer
  - `max_credits` integer: The most this export can cost: pass it as max_credits to launch_link_gap.
  - `max_domains` integer
  - `domains_limit` integer
  - `over_limit` boolean
  - `velocity` boolean
  - `credits_available` integer
  - `next_step` string

## Other responses

- `400`: invalid_request: invalid input.
- `401`: unauthorized: missing, malformed or revoked API key.
- `404`: not_found: missing or not owned by this account.
- `409`: analysis_not_ready: the analysis is not done yet.
- `429`: quote_limit: 30 paid quotes or launches per hour per account; rate_limited: daily limit of site measurements reached for this account.
- `500`: internal_error: unexpected error; retry later, mutations with the same idempotency_key.
- `503`: upstream_unavailable: retry later; mutations with the same idempotency_key.

---

[API](https://skmtc.dev/12backlinks/apis/12backlinks-api.md) · [All operations](https://skmtc.dev/12backlinks/apis/12backlinks-api/llms.txt) · [OpenAPI document](https://skmtc.dev/12backlinks/apis/12backlinks-api/revisions/8936d132d496?raw)
