API-Dokumentation

MetaFetch Open-Graph-Extraktions-API v1

Erste Schritte

  1. Melden Sie sich unter /login mit E-Mail/Passwort oder Google an.
  2. Öffnen Sie das Dashboard und generieren Sie Ihren kostenlosen API-Schlüssel (mf_live_...).
  3. Rufen Sie GET /api/v1/preview mit Authorization: Bearer Ihr_Schlüssel auf.

Verwenden Sie immer die kanonische URL mit www (z. B. https://www.metafetch.dev). Die Domain ohne www leitet um und kann den Authorization-Header entfernen.

Endpunkt

GET https://www.metafetch.dev/api/v1/preview?url={encoded_url}

Authentifizierung

Authorization: Bearer mf_live_your_api_key

Beispiel (bash)

curl "https://www.metafetch.dev/api/v1/preview?url=https://github.com" \
  -H "Authorization: Bearer mf_live_your_api_key"

Beispiel (PowerShell)

curl.exe "https://www.metafetch.dev/api/v1/preview?url=https://github.com" `
  -H "Authorization: Bearer mf_live_your_api_key"

Antwort

{
  "success": true,
  "data": {
    "url": "https://github.com",
    "title": "GitHub",
    "description": "...",
    "image": "https://...",
    "favicon": "https://...",
    "siteName": "GitHub",
    "canonical": "https://github.com",
    "locale": "en_US",
    "type": "website"
  }
}

Demo (ohne Schlüssel)

Die öffentliche Demo ohne Schlüssel funktioniert nur für example.com und github.com.

GET https://www.metafetch.dev/api/v1/preview?url=https://example.com
GET https://www.metafetch.dev/api/v1/preview?url=https://github.com

Fehler

401 Unauthorized — missing/invalid API key
429 Too Many Requests — quota or rate limit exceeded
400 Bad Request — invalid URL
502 Bad Gateway — upstream fetch failed
API-Dokumentation — MetaFetch