“API: domain_metrics”
Gives you a complete view of a domain’s performance: estimated organic traffic, number of ranking keywords, direct competitors, historical trend and Domain Rating.
- Cost: 1 API credit per successful call.
- Module: Competitors (Competitor analysis)
- REST endpoint:
POST https://api.ranki.co/v1/domain-metrics
What it’s for
domain_metrics lets you run a high-level analysis of any website’s authority and visibility in a given country. It’s ideal for evaluating competitors, qualifying prospects or auditing how your own domain is trending, with a reliable estimate of organic traffic and number of ranking keywords.
API parameters
- Operation:
domain_metrics - Parameters:
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
domain | string | Yes | – | Target domain to analyze (e.g. "mercadolibre.com.co"). |
location | string | Yes | – | Country or geographic market to evaluate (e.g. "Colombia"). |
Endpoint
POST https://api.ranki.co/v1/domain-metrics
Authorization: Bearer rk_TU_CLAVE_AQUI
Content-Type: application/json
{
"domain": "mercadolibre.com.co",
"location": "Colombia"
}
Example with curl
curl -s -X POST
-H "Authorization: Bearer rk_TU_CLAVE_AQUI"
-H "Content-Type: application/json"
-d '{
"domain": "mercadolibre.com.co",
"location": "Colombia"
}'
"https://api.ranki.co/v1/domain-metrics"
Sample response
{
"credits_consumed": 1,
"credits_remaining": 246,
"data": {
"domain": "mercadolibre.com.co",
"location": "Colombia",
"organic_traffic": 18450000,
"organic_keywords_count": 820000,
"paid_traffic": 450000,
"paid_keywords_count": 12500,
"domain_rating": 84,
"main_competitors": [
{ "domain": "amazon.com", "common_keywords": 45000 },
{ "domain": "falabella.com.co", "common_keywords": 38000 },
{ "domain": "exito.com", "common_keywords": 34000 }
]
}
}
Response fields
| Field | Type | Description |
|---|---|---|
credits_consumed | integer | Credits deducted (1 credit). |
credits_remaining | integer | Remaining API credit balance. |
data.domain | string | Domain queried. |
data.location | string | Country of the query. |
data.organic_traffic | integer | Estimated monthly organic visits from Google. |
data.organic_keywords_count | integer | Total organic keywords ranking in the top 100 positions. |
data.paid_traffic | integer | Estimated traffic from search ads. |
data.paid_keywords_count | integer | Number of keywords bought in ads. |
data.domain_rating | integer | Link authority rating (0 to 100). |
data.main_competitors | array | List of domains competing organically for the same keywords. |