Instant Gaming API
Instant Gaming API — Detailed Documentation
Click here to search page
Overview
- Purpose: Query Instant Gaming using only a query string, optionally enriching with Latin America prices.
- Framework: Flask · Entry:
app.py· Templates:templates/· Static:static/· Logic:reqs.py - Language: English headers (
Accept-Language: en-US,en;q=0.9).
Routes
GET /— Home with embedded docs.GET /search— UI to search games.GET /health— Health check.
API Endpoint
GET /api/search?query=QUERY
query(required): game name (e.g.,elden ring).latam_priority(optional):1default enrich,0skip for speed.max_details(optional, int): enriched items count (default6).concurrency(optional, int): worker threads (default6).- Legacy:
/api/search/<game>redirects to the query variant. - IG URL (no filters):
https://www.instant-gaming.com/pt/pesquisar/?query=QUERY
Response
[
{
"link": "https://www.instant-gaming.com/pt/awdadwadwd",
"origin": "Instant Gaming",
"price": "R$ 25,67",
"title": awd"
},
{
"link": "https://www.instant-gaming.com/pt/awdadwadwad",
"origin": "Instant Gaming",
"price": "R$ 158,47",
"title": "awd"
},
{
"link": "https://www.instant-gaming.com/pt/awdadwad",
"origin": "Instant Gaming",
"price": "R$ 11,03",
"title": "awd"
},
{
"link": "https://www.instant-gaming.com/pt/awdawdawda",
"origin": "Instant Gaming",
"price": "R$ 20,50",
"title": "awd"
}
]
Empty results: []. Missing query returns {"error":"Missing 'query' parameter"} with HTTP 400.
Examples
Performance & Behavior
- Reuses connections with
requests.Session. - Optional LATAM enrichment via concurrent product page requests.
- Timeouts:
20ssearch,12sproducts. - Filters (platform/type/gametype) are disabled for now.
- Currency may vary depending on deployment locale.
Project Structure
app.py— routesreqs.py— search/enrichmenttemplates/—index.html,search.htmlstatic/— assets
Run Locally (Windows)
git clone https://github.com/diogolourencodev/latamgaming.git
cd latamgaming
python -m venv .venv
.\\.venv\\Scripts\\Activate.ps1
pip install -r requirements.txt
python app.py
# open http://127.0.0.1:5000
Deploy (Vercel)
- Connect GitHub, import repo; Vercel detects Flask.
- Set root if needed and deploy; test the endpoint.
Roadmap
- Reintroduce filters (platform/type/gametype).
- Add
POST /api/searchwith JSON body. - Cache, pagination, currency normalization.
- Bilingual filter-ready
/searchUI.
Health route: /health · Search UI: /search