Documentazione API

Genera immagini BMP 800×480 per display E-Ink che mostrano i programmi delle gare di F1 in modalità 1bit, B/W/R o Spectra 6.

800×480 BMP 1bit / B/W/R / B/W/R/Y / Spectra 6 E-Ink REST API
GET /calendar.bmp

Genera un calendario F1 come immagine BMP (800×480) per display E-Ink 1bit, 4-bit B/W/R, 4-bit B/W/R/Y e Spectra 6.

Parametri

Parameter Tipo Descrizione
lang string Codice lingua per il testo del calendario
Valori: cs, de, en, es, fr, it, ja, nl, pl, pt-BR, sk, tr, zh-CN (predefinito: en)
year integer Anno di stagione per una gara specifica
opzionale — ad es. 2026
round integer Numero del round (1-24) per una gara specifica
opzionale — ad es. 5
tz string Fuso orario per gli orari del programma (formato IANA)
opzionale — ad es. America/New_York, Europe/Prague
display string Modalità di output per display 1bit, B/W/R, B/W/R/Y o Spectra 6
Valori: 1bit, bwr, bwry, spectra6 (predefinito: 1bit)
weather boolean Abilita o disabilita l'overlay meteo
Valori: true, false
weather_type string Quale variante dei dati meteo renderizzare
Valori: race_day, current

Risposta

Content-Type image/bmp
Dimensioni 800×480
Profondità colore 1bit / 4-bit B/W/R / 4-bit B/W/R/Y / Spectra 6
Cache 1 hour

Esempi di codice

# Download next race calendar
curl -o calendar.bmp "https://f1.inkycloud.click/calendar.bmp"

# With Czech language and timezone
curl -o calendar.bmp "https://f1.inkycloud.click/calendar.bmp?lang=cs&tz=Europe/Prague"

# Specific race (year and round)
curl -o calendar.bmp "https://f1.inkycloud.click/calendar.bmp?year=2025&round=5"

# B/W/R/Y output for four-color E-Ink
curl -o calendar.bmp "https://f1.inkycloud.click/calendar.bmp?display=bwry"
import httpx

async def get_f1_calendar(lang: str = "en", tz: str = "Europe/Prague"):
    """Download F1 calendar as BMP image."""
    async with httpx.AsyncClient() as client:
        response = await client.get(
            "https://f1.inkycloud.click/calendar.bmp",
            params={"lang": lang, "tz": tz}
        )
        response.raise_for_status()

        with open("calendar.bmp", "wb") as f:
            f.write(response.content)

        print("Calendar saved as calendar.bmp")

# Usage
import asyncio
asyncio.run(get_f1_calendar(lang="cs"))
// Fetch and display calendar
async function loadF1Calendar(lang = 'en', tz = 'Europe/Prague') {
    const url = new URL('https://f1.inkycloud.click/calendar.bmp');
    url.searchParams.set('lang', lang);
    url.searchParams.set('tz', tz);

    const response = await fetch(url);
    const blob = await response.blob();

    // Display in img element
    const img = document.getElementById('calendar');
    img.src = URL.createObjectURL(blob);
}

// Download as file
async function downloadCalendar() {
    const response = await fetch('/calendar.bmp?lang=cs');
    const blob = await response.blob();

    const link = document.createElement('a');
    link.href = URL.createObjectURL(blob);
    link.download = 'f1-calendar.bmp';
    link.click();
}

Uso con display E-Ink

Recupera /calendar.bmp e visualizzalo direttamente sul tuo display E-Ink. Intervallo di aggiornamento consigliato: ogni 1-6 ore. Compatibile con qualsiasi display E-Ink 800×480 (ad esempio Waveshare 7.5", LaskaKit).

Per LaskaKit / zivyobraz.eu:

  1. 1 In zivyobraz.eu seleziona come sorgente contenuto: URL con immagine
  2. 2 Incolla l'URL: https://f1.inkycloud.click/calendar.bmp?lang=cs&tz=Europe/Prague
  3. 3 Imposta l'intervallo di aggiornamento su 1-6 ore
GET /teams.bmp

Genera un'immagine BMP con tutti i team di F1, i loro piloti, le foto e i punti in campionato nelle modalità di output 1bit, B/W/R, B/W/R/Y o Spectra 6.

Parametri

Parameter Tipo Descrizione
lang string Codice lingua per il testo del calendario
Valori: cs, de, en, es, fr, it, ja, nl, pl, pt-BR, sk, tr, zh-CN (predefinito: en)
year integer Anno della stagione per i dati dei team
opzionale — ad es. 2026
display string Modalità di output del display
Valori: 1bit, bwr, bwry, spectra6 (predefinito: 1bit)

Risposta

Content-Type image/bmp
Dimensioni 800×480
Profondità colore 1-bit / 4-bit / Spectra 6
Cache no-store

Altri endpoint

GET /api/teams/{year}

Ottieni tutti i team con piloti e punti per una stagione (JSON)

GET /api/standings/leader

Ottieni gli attuali leader del campionato (pilota e costruttore)

GET /api/races/{year}

Elenco di tutte le gare di una stagione

GET /api/race/{year}/{round}

Informazioni dettagliate sulla gara, incluso il programma

GET /api/stats

Statistiche delle richieste (ultima ora e 24h)

GET /health

Controllo stato del servizio

GET /api

API JSON — Documentazione API in formato JSON