{
    "openapi": "3.1.0",
    "info": {
        "title": "APK API",
        "version": "1.0.0",
        "description": "Google Play data API: 4 million apps (live and removed), developers, new releases, removals and title keywords. JSON, UTF-8, CORS enabled.\n\nEvery call costs 0–3 tokens regardless of the number of rows (up to 100); /apps costs 1 token per app. Monthly free tokens are used first, then the purchased balance; if a request fails on our side, the tokens are returned. Remaining tokens are in the `_tokens` field of every response; `_credits` is a deprecated alias.\n\nDocumentation: https://apkapi.com/api-docs.php",
        "contact": {
            "url": "https://apkapi.com/api-docs.php"
        },
        "termsOfService": "https://apkapi.com/legal/terms.php"
    },
    "servers": [
        {
            "url": "https://apkapi.com/api/v1"
        }
    ],
    "security": [
        {
            "ApiKeyHeader": []
        },
        {
            "BearerAuth": []
        }
    ],
    "tags": [
        {
            "name": "Приложения"
        },
        {
            "name": "Разработчици"
        },
        {
            "name": "Промени в магазина"
        },
        {
            "name": "Пазар"
        }
    ],
    "paths": {
        "/account": {
            "get": {
                "operationId": "account",
                "tags": [
                    "Account"
                ],
                "summary": "Your plan, token balance, the monthly reset date and the per-minute limit.",
                "description": "Free: no tokens are charged.",
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/app": {
            "get": {
                "operationId": "app",
                "tags": [
                    "Приложения"
                ],
                "summary": "Пълна карта на приложението: заглавие, описание, „Какво е новото“, инсталации (праг и точно число), оценка, брой оценки и отзиви, разпределение на звездите, цена, покупки, реклами, категория, възрастов рейтинг, версия, минимален Android, дати на издаване и обновяване, икона, екранни снимки, видео, разработчик и неговият сайт. За премахнатите — последните запазени данни и дата на изчезване.",
                "description": "Пълна карта на приложението: заглавие, описание, „Какво е новото“, инсталации (праг и точно число), оценка, брой оценки и отзиви, разпределение на звездите, цена, покупки, реклами, категория, възрастов рейтинг, версия, минимален Android, дати на издаване и обновяване, икона, екранни снимки, видео, разработчик и неговият сайт. За премахнатите — последните запазени данни и дата на изчезване.\n\nCost: 1 token per call.",
                "x-tokens": 1,
                "parameters": [
                    {
                        "name": "id",
                        "in": "query",
                        "required": true,
                        "description": "име на пакета на приложението",
                        "schema": {
                            "type": "string"
                        },
                        "example": "com.whatsapp"
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/apps": {
            "get": {
                "operationId": "apps",
                "tags": [
                    "Приложения"
                ],
                "summary": "До 100 карти с една заявка: GET ?ids=a,b,c или POST със списък в тялото (по един на ред или JSON {\"ids\": […]}). 1 токен за всяко приложение; ненамерените се връщат в not_found.",
                "description": "До 100 карти с една заявка: GET ?ids=a,b,c или POST със списък в тялото (по един на ред или JSON {\"ids\": […]}). 1 токен за всяко приложение; ненамерените се връщат в not_found.\n\nCost: 1 token per app.",
                "x-tokens": 1,
                "parameters": [
                    {
                        "name": "ids",
                        "in": "query",
                        "required": true,
                        "description": "имена на пакети, разделени със запетая, до 100",
                        "schema": {
                            "type": "string"
                        },
                        "example": "com.whatsapp,org.telegram.messenger"
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            },
            "post": {
                "operationId": "apps_post",
                "tags": [
                    "Приложения"
                ],
                "summary": "Same as GET, with package names in the request body (one per line, or JSON {\"ids\": [...]}).",
                "description": "До 100 карти с една заявка: GET ?ids=a,b,c или POST със списък в тялото (по един на ред или JSON {\"ids\": […]}). 1 токен за всяко приложение; ненамерените се връщат в not_found.\n\nCost: 1 token per app.",
                "x-tokens": 1,
                "parameters": [],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                },
                "requestBody": {
                    "required": true,
                    "content": {
                        "text/plain": {
                            "schema": {
                                "type": "string"
                            },
                            "example": "com.whatsapp\norg.telegram.messenger"
                        }
                    }
                }
            }
        },
        "/search": {
            "get": {
                "operationId": "search",
                "tags": [
                    "Приложения"
                ],
                "summary": "Търсене и филтри в цялата база. Нужен е поне един филтър. Без q сортирането е по инсталации.",
                "description": "Търсене и филтри в цялата база. Нужен е поне един филтър. Без q сортирането е по инсталации.\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "required": false,
                        "description": "думи за търсене в заглавието, описанието и името на разработчика",
                        "schema": {
                            "type": "string"
                        },
                        "example": "photo editor"
                    },
                    {
                        "name": "category",
                        "in": "query",
                        "required": false,
                        "description": "ID на категория, напр. GAME_PUZZLE (вж. /v1/categories)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "developer_id",
                        "in": "query",
                        "required": false,
                        "description": "ID на разработчика в Google Play",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "min_installs",
                        "in": "query",
                        "required": false,
                        "description": "минимум инсталации (праг на Google Play: 1000, 10000…)",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "max_installs",
                        "in": "query",
                        "required": false,
                        "description": "максимум инсталации",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "min_score",
                        "in": "query",
                        "required": false,
                        "description": "минимална оценка, 0–5",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "min_ratings",
                        "in": "query",
                        "required": false,
                        "description": "минимум оценки",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "free",
                        "in": "query",
                        "required": false,
                        "description": "true — само безплатни, false — само платени",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "true",
                                "false"
                            ]
                        }
                    },
                    {
                        "name": "ads",
                        "in": "query",
                        "required": false,
                        "description": "true — с реклами, false — без",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "true",
                                "false"
                            ]
                        }
                    },
                    {
                        "name": "iap",
                        "in": "query",
                        "required": false,
                        "description": "true — с покупки в приложението",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "true",
                                "false"
                            ]
                        }
                    },
                    {
                        "name": "lang",
                        "in": "query",
                        "required": false,
                        "description": "език на заглавието, ISO код: en, de, pt…",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "released_from",
                        "in": "query",
                        "required": false,
                        "description": "излезли от тази дата, YYYY-MM-DD",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "released_to",
                        "in": "query",
                        "required": false,
                        "description": "излезли до тази дата включително",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "updated_from",
                        "in": "query",
                        "required": false,
                        "description": "обновени от дата",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "updated_to",
                        "in": "query",
                        "required": false,
                        "description": "обновени до тази дата включително",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "description": "live (в магазина, по подразбиране), removed или all",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "live",
                                "removed",
                                "all"
                            ]
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "relevance | installs | real_installs | score | ratings | reviews | released | updated | price",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "order",
                        "in": "query",
                        "required": false,
                        "description": "desc | asc",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "desc",
                                "asc"
                            ]
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/suggest": {
            "get": {
                "operationId": "suggest",
                "tags": [
                    "Приложения"
                ],
                "summary": "Подсказки по началото на заглавието: 10-те най-популярни съвпадения. Безплатно.",
                "description": "Подсказки по началото на заглавието: 10-те най-популярни съвпадения. Безплатно.\n\nCost: 0 tokens per call.",
                "x-tokens": 0,
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "required": true,
                        "description": "начало на заглавието, от 2 знака",
                        "schema": {
                            "type": "string"
                        },
                        "example": "whats"
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/developer": {
            "get": {
                "operationId": "developer",
                "tags": [
                    "Разработчици"
                ],
                "summary": "Разработчик и всичките му приложения: брой (в магазина и премахнати), общо инсталации, средна оценка, първо издаване, категории, сайт. В план Business — имейл, телефон, адрес и юридическо име.",
                "description": "Разработчик и всичките му приложения: брой (в магазина и премахнати), общо инсталации, средна оценка, първо издаване, категории, сайт. В план Business — имейл, телефон, адрес и юридическо име.\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "id",
                        "in": "query",
                        "required": false,
                        "description": "ID на разработчика (от картата на приложението: developer.id)",
                        "schema": {
                            "type": "string"
                        },
                        "example": "5191370068110375942"
                    },
                    {
                        "name": "name",
                        "in": "query",
                        "required": false,
                        "description": "или точното име на разработчика",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "description": "all (по подразбиране), live или removed",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "live",
                                "removed",
                                "all"
                            ]
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "relevance | installs | real_installs | score | ratings | reviews | released | updated | price",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/new": {
            "get": {
                "operationId": "new",
                "tags": [
                    "Промени в магазина"
                ],
                "summary": "Нови приложения по дата на първо издаване, най-новите първи.",
                "description": "Нови приложения по дата на първо издаване, най-новите първи.\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "since",
                        "in": "query",
                        "required": false,
                        "description": "от дата, YYYY-MM-DD (по подразбиране преди 7 дни)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "until",
                        "in": "query",
                        "required": false,
                        "description": "до тази дата включително",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "category",
                        "in": "query",
                        "required": false,
                        "description": "ID на категория, напр. GAME_PUZZLE (вж. /v1/categories)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "min_installs",
                        "in": "query",
                        "required": false,
                        "description": "минимум инсталации (праг на Google Play: 1000, 10000…)",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "lang",
                        "in": "query",
                        "required": false,
                        "description": "език на заглавието, ISO код: en, de, pt…",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "relevance | installs | real_installs | score | ratings | reviews | released | updated | price",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/removed": {
            "get": {
                "operationId": "removed",
                "tags": [
                    "Промени в магазина"
                ],
                "summary": "Приложения, изчезнали от Google Play (няма ги в нито една от 19-те държави, които проверяваме), по дата на изчезване. Картата запазва последните данни.",
                "description": "Приложения, изчезнали от Google Play (няма ги в нито една от 19-те държави, които проверяваме), по дата на изчезване. Картата запазва последните данни.\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "since",
                        "in": "query",
                        "required": false,
                        "description": "от дата, YYYY-MM-DD (по подразбиране преди 7 дни)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "until",
                        "in": "query",
                        "required": false,
                        "description": "до тази дата включително",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "category",
                        "in": "query",
                        "required": false,
                        "description": "ID на категория, напр. GAME_PUZZLE (вж. /v1/categories)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "min_installs",
                        "in": "query",
                        "required": false,
                        "description": "минимум инсталации (праг на Google Play: 1000, 10000…)",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "removed_at | installs | score",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/keywords": {
            "get": {
                "operationId": "keywords",
                "tags": [
                    "Пазар"
                ],
                "summary": "Думи и фрази от заглавията на приложенията поотделно за всеки език: колко приложения и разработчици ги използват, колко от тях са силни (100 хил.+ инсталации), общо инсталации, дял на лидера и оценка на възможността (opportunity).",
                "description": "Думи и фрази от заглавията на приложенията поотделно за всеки език: колко приложения и разработчици ги използват, колко от тях са силни (100 хил.+ инсталации), общо инсталации, дял на лидера и оценка на възможността (opportunity).\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "lang",
                        "in": "query",
                        "required": false,
                        "description": "език, по подразбиране en",
                        "schema": {
                            "type": "string"
                        },
                        "example": "en"
                    },
                    {
                        "name": "q",
                        "in": "query",
                        "required": false,
                        "description": "дума или фраза",
                        "schema": {
                            "type": "string"
                        },
                        "example": "vpn"
                    },
                    {
                        "name": "phrase",
                        "in": "query",
                        "required": false,
                        "description": "true — само фрази от две думи, false — само отделни думи",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "true",
                                "false"
                            ]
                        }
                    },
                    {
                        "name": "min_apps",
                        "in": "query",
                        "required": false,
                        "description": "минимум приложения",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "max_apps",
                        "in": "query",
                        "required": false,
                        "description": "максимум приложения",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "opportunity | apps | installs | strong | devs | max_installs",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "order",
                        "in": "query",
                        "required": false,
                        "description": "desc | asc",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "desc",
                                "asc"
                            ]
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/categories": {
            "get": {
                "operationId": "categories",
                "tags": [
                    "Пазар"
                ],
                "summary": "Всички категории с брой приложения и общо инсталации. Безплатно.",
                "description": "Всички категории с брой приложения и общо инсталации. Безплатно.\n\nCost: 0 tokens per call.",
                "x-tokens": 0,
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "description": "live (в магазина, по подразбиране), removed или all",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "live",
                                "removed",
                                "all"
                            ]
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/free_domains": {
            "get": {
                "operationId": "free_domains",
                "tags": [
                    "Пазар"
                ],
                "summary": "Приложения, на които домейнът на сайта на разработчика е свободен за регистрация, с популярността на приложението. Отключва се след първата покупка на токени.",
                "description": "Приложения, на които домейнът на сайта на разработчика е свободен за регистрация, с популярността на приложението. Отключва се след първата покупка на токени.\n\nCost: 3 tokens per call. Opens after the first token purchase.",
                "x-tokens": 3,
                "parameters": [
                    {
                        "name": "category",
                        "in": "query",
                        "required": false,
                        "description": "ID на категория, напр. GAME_PUZZLE (вж. /v1/categories)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "min_installs",
                        "in": "query",
                        "required": false,
                        "description": "минимум инсталации (праг на Google Play: 1000, 10000…)",
                        "schema": {
                            "type": "integer",
                            "minimum": 0
                        }
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "description": "live (в магазина, по подразбиране), removed или all",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "live",
                                "removed",
                                "all"
                            ]
                        }
                    },
                    {
                        "name": "tld",
                        "in": "query",
                        "required": false,
                        "description": "домейн зона, напр. com",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "relevance | installs | real_installs | score | ratings | reviews | released | updated | price",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/charts": {
            "get": {
                "operationId": "charts",
                "tags": [
                    "Пазар"
                ],
                "summary": "Топ класация на Google Play за една държава и категория: до 200 позиции, промяна на мястото спрямо предишната снимка (change: с колко места се е качило, \"new\" — ново в класацията), икона и инсталации.",
                "description": "Топ класация на Google Play за една държава и категория: до 200 позиции, промяна на мястото спрямо предишната снимка (change: с колко места се е качило, \"new\" — ново в класацията), икона и инсталации.\n\nCost: 2 tokens per call.",
                "x-tokens": 2,
                "parameters": [
                    {
                        "name": "country",
                        "in": "query",
                        "required": true,
                        "description": "държава, ISO код: US, DE, BR…",
                        "schema": {
                            "type": "string"
                        },
                        "example": "US"
                    },
                    {
                        "name": "category",
                        "in": "query",
                        "required": true,
                        "description": "категория, напр. GAME_PUZZLE",
                        "schema": {
                            "type": "string"
                        },
                        "example": "GAME_PUZZLE"
                    },
                    {
                        "name": "collection",
                        "in": "query",
                        "required": false,
                        "description": "free | paid | grossing",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "free",
                                "paid",
                                "grossing"
                            ]
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/rankings": {
            "get": {
                "operationId": "rankings",
                "tags": [
                    "Пазар"
                ],
                "summary": "Всички класации, в които приложението е в последната снимка: държава, категория, колекция, позиция; брой класации, държави и най-добра позиция.",
                "description": "Всички класации, в които приложението е в последната снимка: държава, категория, колекция, позиция; брой класации, държави и най-добра позиция.\n\nCost: 1 token per call.",
                "x-tokens": 1,
                "parameters": [
                    {
                        "name": "id",
                        "in": "query",
                        "required": true,
                        "description": "име на пакета на приложението",
                        "schema": {
                            "type": "string"
                        },
                        "example": "com.whatsapp"
                    },
                    {
                        "name": "country",
                        "in": "query",
                        "required": false,
                        "description": "само една държава",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "collection",
                        "in": "query",
                        "required": false,
                        "description": "free | paid | grossing",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "free",
                                "paid",
                                "grossing"
                            ]
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/availability": {
            "get": {
                "operationId": "availability",
                "tags": [
                    "Пазар"
                ],
                "summary": "Държави, в които приложението е налично в Google Play (по hreflang в sitemap на магазина). При 190+ държави се връща worldwide = true без списък.",
                "description": "Държави, в които приложението е налично в Google Play (по hreflang в sitemap на магазина). При 190+ държави се връща worldwide = true без списък.\n\nCost: 1 token per call.",
                "x-tokens": 1,
                "parameters": [
                    {
                        "name": "id",
                        "in": "query",
                        "required": true,
                        "description": "име на пакета на приложението",
                        "schema": {
                            "type": "string"
                        },
                        "example": "com.whatsapp"
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/markets": {
            "get": {
                "operationId": "markets",
                "tags": [
                    "Пазар"
                ],
                "summary": "Конкурентност на пазарите по безплатните класации: праг за влизане в топ 100 и топ 200 (инсталации на приложението на това място), дял на новите (за 12 месеца) и локалните (≤3 държави) приложения в топа, размер на локалния пазар. Без параметри — всички държави; country — категориите на една държава; category — една категория във всички държави.",
                "description": "Конкурентност на пазарите по безплатните класации: праг за влизане в топ 100 и топ 200 (инсталации на приложението на това място), дял на новите (за 12 месеца) и локалните (≤3 държави) приложения в топа, размер на локалния пазар. Без параметри — всички държави; country — категориите на една държава; category — една категория във всички държави.\n\nCost: 1 token per call.",
                "x-tokens": 1,
                "parameters": [
                    {
                        "name": "country",
                        "in": "query",
                        "required": false,
                        "description": "държава, ISO код",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "category",
                        "in": "query",
                        "required": false,
                        "description": "ID на категория, напр. GAME_PUZZLE (вж. /v1/categories)",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "required": false,
                        "description": "entry100 | entry200 | new_share | local_share | local_apps | local_installs | local_new",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "order",
                        "in": "query",
                        "required": false,
                        "description": "desc | asc",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "desc",
                                "asc"
                            ]
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "required": false,
                        "description": "страница, от 1",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        }
                    },
                    {
                        "name": "per",
                        "in": "query",
                        "required": false,
                        "description": "редове на страница, 1–100 (по подразбиране 20)",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                        },
                        "example": 20
                    }
                ],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/stats": {
            "get": {
                "operationId": "stats",
                "tags": [
                    "Пазар"
                ],
                "summary": "Размер на базата: приложения в магазина и премахнати, разработчици, нови и премахнати за 7 дни, час на последното обновяване. Безплатно.",
                "description": "Размер на базата: приложения в магазина и премахнати, разработчици, нови и премахнати за 7 дни, час на последното обновяване. Безплатно.\n\nCost: 0 tokens per call.",
                "x-tokens": 0,
                "parameters": [],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    },
                    "400": {
                        "$ref": "#/components/responses/Error"
                    },
                    "401": {
                        "$ref": "#/components/responses/Error"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error"
                    },
                    "502": {
                        "$ref": "#/components/responses/Error"
                    },
                    "503": {
                        "$ref": "#/components/responses/Error"
                    }
                }
            }
        },
        "/health": {
            "get": {
                "operationId": "health",
                "tags": [
                    "Account"
                ],
                "summary": "Service status. No key required.",
                "security": [],
                "responses": {
                    "200": {
                        "$ref": "#/components/responses/Ok"
                    }
                }
            }
        }
    },
    "components": {
        "securitySchemes": {
            "ApiKeyHeader": {
                "type": "apiKey",
                "in": "header",
                "name": "X-API-Key"
            },
            "BearerAuth": {
                "type": "http",
                "scheme": "bearer"
            }
        },
        "schemas": {
            "Tokens": {
                "type": "object",
                "properties": {
                    "cost": {
                        "type": "integer",
                        "description": "tokens this request cost"
                    },
                    "remaining": {
                        "type": "integer",
                        "description": "tokens left (monthly + purchased)"
                    }
                }
            },
            "Ok": {
                "type": "object",
                "required": [
                    "ok"
                ],
                "additionalProperties": true,
                "properties": {
                    "ok": {
                        "type": "boolean",
                        "const": true
                    },
                    "results": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "additionalProperties": true
                        }
                    },
                    "total": {
                        "type": "integer"
                    },
                    "page": {
                        "type": "integer"
                    },
                    "per": {
                        "type": "integer"
                    },
                    "pages": {
                        "type": "integer"
                    },
                    "_tokens": {
                        "$ref": "#/components/schemas/Tokens"
                    },
                    "_credits": {
                        "$ref": "#/components/schemas/Tokens",
                        "deprecated": true
                    }
                }
            },
            "Error": {
                "type": "object",
                "required": [
                    "ok",
                    "error",
                    "code"
                ],
                "properties": {
                    "ok": {
                        "type": "boolean",
                        "const": false
                    },
                    "error": {
                        "type": "string"
                    },
                    "code": {
                        "type": "string",
                        "examples": [
                            "missing_api_key",
                            "invalid_api_key",
                            "account_blocked",
                            "insufficient_credits",
                            "rate_limited",
                            "invalid_param",
                            "invalid_request",
                            "not_found",
                            "upstream_error",
                            "service_unavailable"
                        ]
                    }
                }
            }
        },
        "responses": {
            "Ok": {
                "description": "Success",
                "headers": {
                    "X-Cache": {
                        "description": "HIT — served from cache, MISS — fresh query to the database",
                        "schema": {
                            "type": "string"
                        }
                    }
                },
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Ok"
                        }
                    }
                }
            },
            "Error": {
                "description": "Error",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        }
                    }
                }
            }
        }
    }
}