Linktrust

API

API Pricing

It costs the same as checks via UI

Linktrust

How does it work?

Linktrust.pro provides api for most of services

01

Domains API

Check domains: GET https://linktrust.pro/api/domain?token=< api token >&< ...params >

Available params:

  • ?domain=[string] - document to analyze
  • ?format=['csv' | 'json'] - response format (csv is deprecated, we recommend using json only going forward)

Google doc CSV API: https://docs.google.com/spreadsheets/d/1eHrHKwDedN35x5adfsNubH1etQUoY5AIUq8kM3QiqAk/edit?usp=sharing — domains

Domain calculation runs synchronously on the first request, so the response returns right away — but not all data is ready yet. The message field holds the calculation status:

  • partially_done — core metrics (spam/trust score, backlinks, traffic, keywords) are already ready, additional data is still being calculated in the background
  • done — all data is ready, including DA, wiki backlink, domain age, wayback timeline, keyword topics and contacts
  • failed — error during calculation

To get complete data, repeat the call after a few seconds — until message becomes done. Repeat requests for the same domain are free — tokens are only charged once.

Typed response description:

Success response: HTTP 200

{
  message: 'pending' | 'processing' | 'partially_done' | 'done' | 'failed';
  check: {
    spamScore: number | null;
    trustScore: number | null;
    monthOrganicAmount: number | null;
    monthTrafficAmount: number | null;
    trafficTrend3mPercent: number | null;
    backlinksTotal: number | null;
    backlinksDomains: number | null;
    hasWikipediaBacklink: boolean | null;
    domainDa: number | null;
    majesticTf: number | null;
    majesticCf: number | null;
    domainRegisteredAt: string | null; // YYYY-MM-DD
    waybackOldestAt: string | null; // YYYY-MM-DD
    waybackHasGaps: boolean | null;
    waybackTimeline: { from: string; to: string; months: number }[] | null;
    keywordTopics: string[] | null;
    contacts: { email: string | null; socials: Record<string, string> } | null;
    categories: string[] | null;
    countries: { country: string; percent: number }[] | null;
    backlinks: {
      toUrl: string;
      fromUrl: string;
      nofollow: boolean;
      fromAnchor: string | null;
      fromDomain: string;
      fromDomainRank: number;
    }[];
    keywords: {
      serp_found_url: string;
      serp_position: number;
      keyword: string;
      country: string;
      volume: number;
    }[];
  };
}

Validation error: HTTP 422

{
  message: string;                    // validation failed / invalid domain
  errors?: Record<string, string[]>;  // field => list of messages, absent for invalid domain
}

Error: HTTP 401 | 402

{
  message: string;   // 401 - authorization failed, 402 - no tokens
  status?: 'error';  // present when authorization failed
}

02

Serp API

Check google positions: GET https://linktrust.pro/api/serp?token=< api token >&< ...params >

Available params:

  • ?q=[string] - keyword to check
  • ?hl=[string] - google hl
  • ?gl=[string] - google gl
  • ?uule=[string] - google uule
  • ?depth=[int] - scan depth (10-100)

Typed response description:

Success response: HTTP 200

{
  status: 'success';
  serp: {
    position: number;
    title: string;
    url: string;
    description: string;
  }[];
}

Validation error: HTTP 422

{
  status: 'error';
  errors: Record<string, string[]>;  // field => list of messages
}

Error: HTTP 401 | 402 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 402 - no tokens, 500 - system error
}

03

Check Indexation Single URL API

Check indexation in google: GET https://linktrust.pro/api/check-indexation?token=< api token >&< ...params >

Available params:

  • ?url=[string] - url to check

Typed response description:

Success response: HTTP 200

{
  status: 'success';
  url: string;
  is_indexed: boolean;
}

Validation error: HTTP 422

{
  status: 'error';
  errors: Record<string, string[]>;  // field => list of messages
}

Error: HTTP 401 | 402 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 402 - no tokens, 500 - system error
}

04

Check Indexation Batch API

Batch indexation check in google:

Create request:

POST https://linktrust.pro/api/check-indexation-batch?token=< api token >

Available params:

  • token=[string] - API token
  • urls=[array] - array of URLs to check (1-5000)
  • name=[string] (optional) - batch request name

Typed response description:

Success response: HTTP 200

{
  status: 'success';
  id: number;
  check_status: 'pending';
  urls_count: number;
  message: string;
}

Validation error: HTTP 422

{
  status: 'error';
  errors: Record<string, string[]>;  // field => list of messages
}

Error: HTTP 401 | 402 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 402 - no tokens, 500 - system error
}

Get results:

GET https://linktrust.pro/api/check-indexation-batch/{id}?token=< api token >

Check statuses:

  • pending - pending
  • processing - processing
  • done - done, results available
  • failed - execution error

Typed response description:

Results are not ready yet: HTTP 200

{
  id: number;
  name: string;
  check_status: 'pending' | 'processing' | 'failed';
}

Results are ready: HTTP 200

{
  id: number;
  name: string;
  check_status: 'done';
  results: Record<string, boolean>;  // url => is indexed
  total_indexed: number;
  total_not_indexed: number;
}

Request not found: HTTP 404

{
  status: 'error';
  message: string;  // batch not found or belongs to another user
}

Error: HTTP 401 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 500 - system error
}

05

Indexation Request API

Submit URLs for indexation in google:

Create request:

POST https://linktrust.pro/api/indexation-request?token=< api token >

Available params:

  • token=[string] - API token
  • urls=[array] - array of URLs to index (1-500)
  • name=[string] (optional) - indexation request name

Typed response description:

Success response: HTTP 200

{
  status: 'success';
  id: number;
  indexation_status: 'pending';
  urls_count: number;
  message: string;
}

Validation error: HTTP 422

{
  status: 'error';
  errors: Record<string, string[]>;  // field => list of messages
}

Error: HTTP 401 | 402 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 402 - no tokens, 500 - system error
}

View request:

GET https://linktrust.pro/api/indexation-request/{id}?token=< api token >

Request statuses (indexation_status):

  • pending - pending
  • processing - processing
  • done - all URLs were submitted for indexation
  • partially_done - only a part of URLs was submitted for indexation
  • failed - execution error

Indexation check statuses (indexation_check_status):

  • pending - indexation is not checked so far
  • done - indexation is checked, results available

We check it automatically once, on day 10 since submit.

Typed response description:

Indexation is not checked yet: HTTP 200

{
  id: number;
  name: string;
  indexation_status: 'pending' | 'processing' | 'done' | 'partially_done' | 'failed';
  urls_count: number;
  indexation_requested_at: string | null;  // ISO 8601, when urls were sent to indexation
  indexation_check_status: 'pending';
  indexation_checked_at: null;
}

Indexation is checked: HTTP 200

{
  id: number;
  name: string;
  indexation_status: 'done' | 'partially_done';
  urls_count: number;
  indexation_requested_at: string;         // ISO 8601, when urls were sent to indexation
  indexation_check_status: 'done';
  indexation_checked_at: string;           // ISO 8601, when indexation was checked
  results: Record<string, boolean>;        // url => is indexed
  total_indexed: number;
  total_not_indexed: number;
}

Request not found: HTTP 404

{
  status: 'error';
  message: string;  // request not found or belongs to another user
}

Error: HTTP 401 | 500

{
  status: 'error';
  message: string;  // 401 - authorization failed, 500 - system error
}

06

User balances:

https://linktrust.pro/api/balance?token=< api token >