Search and articles
Typeahead search across fighters and events, and UFCalendar’s own articles.
GET /v1/search
Accent-insensitive search across roster fighters and events (up to 8 of each). Great for building pickers.
| Parameter | In | Type | Description |
|---|---|---|---|
q required | query | string |
curl "https://api.ufcalendar.com/v1/search?q=makhachev" \
-H "Authorization: Bearer $UFCALENDAR_API_KEY" from ufcalendar import FightAPI
api = FightAPI() # or FightAPI("ufcalendar_...")
data = api.search("makhachev") import { FightAPI } from '@ufcalendar/sdk';
const api = new FightAPI(process.env.UFCALENDAR_API_KEY);
const data = await api.search("makhachev"); Response: data, 2 fields
| Field | Type | Description |
|---|---|---|
fighters | FighterRef[] | |
events | SearchEvent[] |
GET /v1/articles
UFCalendar's own editorial archive — previews, recaps, investigations, fighter-pay and technique pieces — newest first. q (at least 2 characters) matches the title, summary or a tag, accent-insensitive (and the translated title and summary when locale is set); tag is an exact tag match; locale is one of the 13 site languages (en default, es, pt, de, fr, tr, ru, ka, ja, ko, pl, sr, zh) — a row serves its translation when one exists and English otherwise, and its locale names the language actually served. Each row: slug, url (the canonical page in the requested language), title, description, author_name, tags, published_at, locale. Pass the slug to /v1/articles/{slug} for the body. A q under 2 characters 400s invalid_query; an unknown locale 400s invalid_locale. Betting-advice editorial (picks, parlays) is not served. Link back when quoting.
| Parameter | In | Type | Description |
|---|---|---|---|
q | query | string | Keyword: matches title, summary or a tag. |
tag | query | string | Exact tag. |
locale | query | enum | Site language to serve. |
cursor | query | string | Opaque cursor from meta.pagination.next_cursor. |
limit | query | integer |
curl "https://api.ufcalendar.com/v1/articles?q=title%20fight&limit=3" \
-H "Authorization: Bearer $UFCALENDAR_API_KEY" from ufcalendar import FightAPI
api = FightAPI() # or FightAPI("ufcalendar_...")
for row in api.articles(q="title fight"):
print(row) import { FightAPI } from '@ufcalendar/sdk';
const api = new FightAPI(process.env.UFCALENDAR_API_KEY);
for await (const row of api.articles({ q: "title fight" })) {
console.log(row);
} Response: data items, 8 fields
| Field | Type | Description |
|---|---|---|
slug | string | |
url | string | The canonical page in the requested language. |
title | string | |
description | string | |
author_name | string | |
tags | string[] | |
published_at | string | null | |
locale | ArticleLocale | The 13 site languages. |
GET /v1/articles/{slug}
One published UFCalendar article by slug: title, description, author_name, author_slug, tags, published_at, url and the full body_md (Markdown; the site's client-only widgets — fighter cards, embeds and offer blocks — are removed). No cover image is served: its license credit has no place in this payload. locale is the language requested and served_locale the one delivered: the translation when one exists, English otherwise. An unknown slug (or a draft) 404s; betting-advice editorial (picks, parlays) is not served, so such a slug 404s too; an unknown locale 400s invalid_locale. Link back when quoting.
| Parameter | In | Type | Description |
|---|---|---|---|
slug required | path | string | Article slug, from /v1/articles. |
locale | query | enum | Site language to serve. |
curl "https://api.ufcalendar.com/v1/articles/noche-ufc-payouts-bonuses-jean-silva" \
-H "Authorization: Bearer $UFCALENDAR_API_KEY" from ufcalendar import FightAPI
api = FightAPI() # or FightAPI("ufcalendar_...")
data = api.article("noche-ufc-payouts-bonuses-jean-silva") import { FightAPI } from '@ufcalendar/sdk';
const api = new FightAPI(process.env.UFCALENDAR_API_KEY);
const data = await api.article("noche-ufc-payouts-bonuses-jean-silva"); Response: data, 11 fields
| Field | Type | Description |
|---|---|---|
slug | string | |
url | string | |
title | string | |
description | string | |
author_name | string | |
author_slug | string | null | |
tags | string[] | |
published_at | string | null | |
body_md | string | Markdown; client-only widgets and licensed embeds removed. |
locale | ArticleLocale | The 13 site languages. |
served_locale | ArticleLocale | The 13 site languages. |