{
    "openapi": "3.1.0",
    "info": {
        "title": "Tasbeeh Open API",
        "description": "Free JSON API for Islamic azkar, prophetic duas, daily ayah and prayer times. No API key for GET. Документация: https://tasbeeh.ru/api/",
        "version": "1.1.0",
        "contact": {
            "url": "https://tasbeeh.ru/"
        }
    },
    "servers": [
        {
            "url": "https://tasbeeh.ru/wp-json/app"
        }
    ],
    "paths": {
        "/azkars": {
            "get": {
                "summary": "Все азкары",
                "operationId": "getAzkars",
                "parameters": [
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 50,
                            "maximum": 200
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "success": {
                                            "type": "boolean"
                                        },
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "type": "object",
                                                "properties": {
                                                    "id": {
                                                        "type": "integer"
                                                    },
                                                    "arab": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "rus": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "rus_trans": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "ingush_trans": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "counter": {
                                                        "type": [
                                                            "integer",
                                                            "null"
                                                        ]
                                                    },
                                                    "audio": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "format": "uri"
                                                    },
                                                    "name_source": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "full_source": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "categories": {
                                                        "type": "array",
                                                        "items": {
                                                            "type": "string",
                                                            "enum": [
                                                                "morning",
                                                                "evening",
                                                                "quran"
                                                            ]
                                                        }
                                                    },
                                                    "level": {
                                                        "type": "array",
                                                        "items": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "date": {
                                                        "type": "string"
                                                    },
                                                    "modified_date": {
                                                        "type": "string"
                                                    }
                                                }
                                            }
                                        },
                                        "total": {
                                            "type": "integer"
                                        },
                                        "pages": {
                                            "type": "integer"
                                        },
                                        "current": {
                                            "type": "integer"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/azkars/{slug}": {
            "get": {
                "summary": "Азкары по категории",
                "operationId": "getAzkarsByCategory",
                "parameters": [
                    {
                        "name": "slug",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "enum": [
                                "morning",
                                "evening",
                                "quran",
                                "prophets"
                            ]
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 50,
                            "maximum": 200
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/prophets-duas": {
            "get": {
                "summary": "Дуа пророков из Корана",
                "operationId": "getProphetsDuas",
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/ayat-day": {
            "get": {
                "summary": "Аят дня",
                "operationId": "getAyatDay",
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/ayats": {
            "get": {
                "summary": "Все аяты",
                "operationId": "getAyats",
                "parameters": [
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 50,
                            "maximum": 200
                        }
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "default": 1
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/prayer-times": {
            "get": {
                "summary": "Страны и города намаза",
                "operationId": "getPrayerTimesIndex",
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Поиск города"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/prayer-times/{country}": {
            "get": {
                "summary": "Города страны",
                "operationId": "getPrayerTimesCountry",
                "parameters": [
                    {
                        "name": "country",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "example": "RU"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/prayer-times/{country}/{city}": {
            "get": {
                "summary": "Год намаза по городу",
                "operationId": "getPrayerTimesCity",
                "parameters": [
                    {
                        "name": "country",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "example": "RU"
                        }
                    },
                    {
                        "name": "city",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "example": "nazran"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    }
}