GET
/v1/extractExtract metadata from any URL including Open Graph, Twitter Card, and more.
Query Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
url | string | - | The URL to extract metadata from (URL encoded) | |
cache | boolean | true | Whether to use cached results if available | |
max_age | integer | 3600 | Maximum cache age in seconds. Only fetch fresh if cache is older. |
Try it out
GET /v1/extractTest the extract endpoint with any URL
curl "https://api.katsau.com/v1/extract?url=https%3A%2F%2Fgithub.com&cache=true" \
-H "Authorization: Bearer YOUR_API_KEY"Request Example
curl "https://api.katsau.com/v1/extract?url=https://github.com" \
-H "Authorization: Bearer ks_live_your_api_key"Response
{
"success": true,
"data": {
"url": "https://github.com",
"resolved_url": "https://github.com/",
"title": "GitHub: Let's build from here",
"description": "GitHub is where over 100 million developers shape the future of software.",
"image": "https://github.githubassets.com/images/modules/site/social-cards/github-social.png",
"open_graph": {
"title": "GitHub: Let's build from here",
"description": "GitHub is where over 100 million developers...",
"image": "https://github.githubassets.com/images/.../github-social.png",
"url": "https://github.com",
"type": "website",
"site_name": "GitHub",
"locale": "en_US"
},
"twitter": {
"card": "summary_large_image",
"site": "@github",
"creator": "@github",
"title": "GitHub: Let's build from here",
"description": "GitHub is where over 100 million developers...",
"image": "https://github.githubassets.com/images/.../github-social.png"
},
"meta": {
"author": null,
"keywords": ["git", "github", "development"],
"theme_color": "#1e2327",
"canonical_url": "https://github.com",
"favicon": "https://github.githubassets.com/favicons/favicon.svg",
"language": "en",
"charset": "utf-8"
},
"article": {
"published_time": null,
"modified_time": null,
"author": null,
"section": null,
"tags": []
},
"icons": [
{
"url": "https://github.githubassets.com/favicons/favicon.svg",
"type": "image/svg+xml",
"sizes": "any"
},
{
"url": "https://github.githubassets.com/favicons/favicon.png",
"type": "image/png",
"sizes": "32x32"
}
]
},
"meta": {
"request_id": "req_abc123xyz",
"response_time_ms": 234,
"cache_hit": false,
"cache_ttl": 3600,
"fetched_at": "2024-01-15T10:30:00Z"
}
}Response Fields
Top-level fields
urlOriginal URL requestedresolved_urlFinal URL after redirectstitleBest available title (OG or HTML)descriptionBest available descriptionimagePrimary image URLopen_graph object
All Open Graph meta tags from the page
titleog:titledescriptionog:descriptionimageog:imagetypeog:type (website, article, etc.)site_nameog:site_nameError Codes
| Code | HTTP | Description |
|---|---|---|
INVALID_URL | 400 | URL format is invalid |
URL_TOO_LONG | 400 | URL exceeds 2048 characters |
TARGET_TIMEOUT | 502 | Target site did not respond within 10s |
TARGET_UNREACHABLE | 502 | Could not connect to target URL |