{
    "openapi": "3.1.0",
    "info": {
        "title": "Instantoto Data API",
        "version": "1.0",
        "description": "Free, keyless JSON API for slot & casino game data (RTP, volatility, providers, mechanics).",
        "contact": {
            "url": "https://instantotodata.com/contact"
        },
        "license": {
            "name": "Fair use",
            "url": "https://instantotodata.com/terms"
        }
    },
    "servers": [
        {
            "url": "https://instantotodata.com"
        }
    ],
    "paths": {
        "/api.php": {
            "get": {
                "summary": "Dispatch endpoint (select with ?endpoint=)",
                "parameters": [
                    {
                        "name": "endpoint",
                        "in": "query",
                        "schema": {
                            "type": "string",
                            "enum": [
                                "endpoints",
                                "slots",
                                "slot",
                                "search",
                                "providers",
                                "provider",
                                "similar",
                                "compare",
                                "trending",
                                "aggregations",
                                "stats",
                                "games"
                            ]
                        },
                        "description": "Which resource to query",
                        "required": true
                    },
                    {
                        "name": "slug",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Slot or provider slug (slot, provider, similar)"
                    },
                    {
                        "name": "q",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Search text (slots, search)"
                    },
                    {
                        "name": "provider",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Exact provider name"
                    },
                    {
                        "name": "volatility",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma list of low,medium,high"
                    },
                    {
                        "name": "min_rtp",
                        "in": "query",
                        "schema": {
                            "type": "number"
                        },
                        "description": "Minimum RTP"
                    },
                    {
                        "name": "max_rtp",
                        "in": "query",
                        "schema": {
                            "type": "number"
                        },
                        "description": "Maximum RTP"
                    },
                    {
                        "name": "year_gte",
                        "in": "query",
                        "schema": {
                            "type": "integer"
                        },
                        "description": "Released on/after year"
                    },
                    {
                        "name": "feature",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match a mechanic/feature"
                    },
                    {
                        "name": "sort",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Comma list; prefix - for desc (e.g. -rtp,name)"
                    },
                    {
                        "name": "fields",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Sparse fieldset (e.g. name,rtp,provider)"
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "schema": {
                            "type": "integer"
                        },
                        "description": "1\u2013200, default 50"
                    },
                    {
                        "name": "cursor",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Opaque pagination cursor from paging.next_cursor"
                    },
                    {
                        "name": "a",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "First slug (compare)"
                    },
                    {
                        "name": "b",
                        "in": "query",
                        "schema": {
                            "type": "string"
                        },
                        "description": "Second slug (compare)"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success envelope",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "ok": {
                                            "type": "boolean"
                                        },
                                        "version": {
                                            "type": "string"
                                        },
                                        "ms": {
                                            "type": "number"
                                        },
                                        "count": {
                                            "type": "integer"
                                        },
                                        "total": {
                                            "type": "integer"
                                        },
                                        "paging": {
                                            "type": "object"
                                        },
                                        "result": {
                                            "type": "array",
                                            "items": {
                                                "type": "object",
                                                "properties": {
                                                    "name": {
                                                        "type": "string"
                                                    },
                                                    "slug": {
                                                        "type": "string"
                                                    },
                                                    "provider": {
                                                        "type": "string"
                                                    },
                                                    "rtp": {
                                                        "type": "number",
                                                        "nullable": true
                                                    },
                                                    "volatility": {
                                                        "type": "string",
                                                        "enum": [
                                                            "low",
                                                            "medium",
                                                            "high"
                                                        ]
                                                    },
                                                    "reels": {
                                                        "type": "string"
                                                    },
                                                    "paylines": {
                                                        "type": "string"
                                                    },
                                                    "max_win": {
                                                        "type": "string"
                                                    },
                                                    "theme": {
                                                        "type": "string"
                                                    },
                                                    "year": {
                                                        "type": "integer",
                                                        "nullable": true
                                                    },
                                                    "features": {
                                                        "type": "array",
                                                        "items": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "popularity": {
                                                        "type": "integer"
                                                    },
                                                    "accent": {
                                                        "type": "string"
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "invalid_param"
                    },
                    "404": {
                        "description": "not_found / invalid_endpoint"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "Slot": {
                "type": "object",
                "properties": {
                    "name": {
                        "type": "string"
                    },
                    "slug": {
                        "type": "string"
                    },
                    "provider": {
                        "type": "string"
                    },
                    "rtp": {
                        "type": "number",
                        "nullable": true
                    },
                    "volatility": {
                        "type": "string",
                        "enum": [
                            "low",
                            "medium",
                            "high"
                        ]
                    },
                    "reels": {
                        "type": "string"
                    },
                    "paylines": {
                        "type": "string"
                    },
                    "max_win": {
                        "type": "string"
                    },
                    "theme": {
                        "type": "string"
                    },
                    "year": {
                        "type": "integer",
                        "nullable": true
                    },
                    "features": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    },
                    "popularity": {
                        "type": "integer"
                    },
                    "accent": {
                        "type": "string"
                    }
                }
            }
        }
    }
}