Skip to content

Feed API

The Feed API gives you the posts LoopFeed’s AI curation has matched to a match, team, player or competition: highlights, clips, previews, interviews, news and more, from every source LoopFeed curates. You don’t need to set up topics or sources.

GET https://q.loop-feed.com/v1/feeds/football/team/9
→ the latest posts about Arsenal
  1. Get your API key from LoopFeed. It looks like lfk_ followed by 43 characters. It is shown only once, so store it in your server’s secrets.

  2. Request a feed from your server:

    Terminal window
    curl -H "Authorization: Bearer lfk_your_key" \
    "https://q.loop-feed.com/v1/feeds/football/team/9?limit=5"
  3. Show it in a browser or app: your server mints a short-lived feed token, and the page uses the token instead of the key.

GET /v1/feeds/{sport}/{kind}/{id}
Sport ({sport})Kinds ({kind})
football: association football (soccer)match, team, player, competition
rugby: rugby leaguematch, team, competition
rugby-union: rugby union and sevensmatch, team, competition

{id} is the numeric ID of the match, team, player or competition in LoopFeed’s sports data. See Finding IDs.

  • A competition feed covers every season of that competition. Its ID stays the same from one season to the next.
  • Player feeds are football only.
  • IDs are unique only within a sport. Football team 18 and rugby league team 18 are different teams, so always include the sport.
ParameterDefaultDescription
limit20Posts per page, up to 100.
cursorThe next value from the previous page. See Paging.
contentTypeOnly these content types, comma-separated, at most 5. For example highlights,clip.
serviceOnly one platform: youtube, twitter, instagram or rss.
tokenA feed token, for browsers and apps instead of the API key.
{
"content": [
{
"id": "cmh0x1y2z0001abcdpost00001",
"externalId": "m0G_UKNoSqY",
"service": "youtube",
"type": "video",
"title": "MADUEKE THE MATCHWINNER! | EXTENDED HIGHLIGHTS | Nottingham Forest vs Arsenal (0-1)",
"text": "Noni Madueke's late goal was enough to secure a valuable 1-0 win away to Nottingham Forest...",
"url": "https://www.youtube.com/watch?v=m0G_UKNoSqY",
"date": "2026-10-19T23:00:00Z",
"created": "2026-10-19T23:04:12.521Z",
"author": { "name": "Arsenal", "username": "Arsenal", "url": "https://youtube.com/channel/UCpryVRk_VDudG8SHXgWcG0w", "verified": true },
"media": [
{ "type": "embed", "embed": "<iframe src='https://www.youtube.com/embed/m0G_UKNoSqY'></iframe>" },
{ "type": "image", "url": "https://i.ytimg.com/vi/m0G_UKNoSqY/maxresdefault.jpg", "width": 1280, "height": 720 }
],
"metadata": {
"contentType": "highlights",
"matches": [
{
"sport": "football", "matchId": "518066",
"homeTeamId": "11", "homeTeamName": "Nottingham Forest",
"awayTeamId": "9", "awayTeamName": "Arsenal",
"leagueId": "10001", "leagueName": "England - Premier League",
"startDateTime": "2026-10-18T15:30:00.000Z"
}
],
"entities": [
{ "sport": "football", "kind": "competition", "id": "10001", "name": "Premier League" },
{ "sport": "football", "kind": "team", "id": "9", "name": "Arsenal" },
{ "sport": "football", "kind": "team", "id": "11", "name": "Nottingham Forest" },
{ "sport": "football", "kind": "player", "id": "4410", "name": "Noni Madueke" }
],
"custom": {}
},
"pinned": false
}
],
"next": "MjAyNi0xMC0xOVQyMzowMDowMFp8Y21oMHgxeTJ6MDAwMWFiY2Rwb3N0MDAwMDE"
}

The example is shortened. Each post has the same shape as items from the topic content API, and its curation is in metadata:

FieldDescription
metadata.contentTypeThe post’s content type, for example highlights.
metadata.matchesThe match the post is about, if any: its ID, teams, competition and kick-off time.
metadata.entitiesThe teams, players and competitions the post is about. Each has a sport, kind, id and name.
  • Posts are newest first, by the time they were published.
  • If the same video was posted by several sources, it appears once.
  • The match status and score in metadata.matches are a snapshot from when the post was curated. Use your live sports data for current scores.

next is the cursor of the following page, or null on the last page. Pass it back unchanged as cursor, with the same filters:

Terminal window
curl -H "Authorization: Bearer lfk_your_key" \
"https://q.loop-feed.com/v1/feeds/football/team/9?limit=20&cursor=MjAyNi0xMC0xOVQyMzowMDowMFp8Y21oMHgxeTJ6MDAwMWFiY2Rwb3N0MDAwMDE"

To check for new posts, request the first page again (no cursor).

There are two ways to authenticate. Use the one that matches where the request comes from.

FromSendOpens
Your serversThe API key, in a headerEvery feed of the sports your subscription covers
Browsers and appsA feed token, as ?token=Every feed of the sports your subscription covers, until the token expires

Send the key in either header:

Authorization: Bearer lfk_your_key
X-API-Key: lfk_your_key

If you gave LoopFeed your servers’ IP addresses, the key only works from those addresses. Servers that have IPv6 usually connect over it, so give us their IPv6 addresses (or range) as well as their IPv4 ones. A refused request says which address it came from.

A feed token opens every feed your subscription covers: every match, team, player and competition in its sports. It works for a short time: 15 minutes by default, up to an hour. Your server mints tokens with the API key:

POST /v1/feeds/tokens
Authorization: Bearer lfk_your_key
Content-Type: application/json
{ "ttlSeconds": 900 }
FieldDescription
ttlSecondsOptional. How long the token works: 60 to 3600 seconds, default 900 (15 minutes).

The body is optional. Without one, the token works for 15 minutes. The response (201 Created) has the token, its expiry and a URL that uses it:

{
"token": "Y21zdWIxMjN8MTc5MjUyMDEwMA.q2V0...",
"expiresAt": "2026-10-20T18:15:00Z",
"url": "/v1/feeds/{sport}/{kind}/{id}?token=Y21zdWIxMjN8MTc5MjUyMDEwMA.q2V0..."
}

Put the sport, kind and ID of each feed you read in the path, for example /v1/feeds/football/team/9?token=…. The same token works for every feed.

Mint tokens on your server and share each one with all your visitors until shortly before it expires, as in the example below. Don’t mint a token for every visitor: minting uses your API key, so it counts towards your subscription’s rate limit.

The page then requests https://q.loop-feed.com + url, adding any other parameters with &:

// GET /feed-token on your site: one token for every feed, shared by all visitors
let shared; // { token, expiresAt, url }
app.get('/feed-token', async (req, res) => {
// Mint a new token five minutes before the old one expires
if (!shared || Date.parse(shared.expiresAt) - Date.now() < 5 * 60 * 1000) {
const response = await fetch('https://q.loop-feed.com/v1/feeds/tokens', {
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.LOOPFEED_API_KEY}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({ ttlSeconds: 900 }),
});
if (!response.ok) return res.status(response.status).json(await response.json());
shared = await response.json();
}
res.json(shared);
});

Mint a new token when the old one expires, or shortly before. A page that stays open longer than its token should fetch /feed-token again. Tokens stop working within a minute if LoopFeed pauses your subscription. Rotating your API key doesn’t stop tokens you already minted: they work until they expire.

Feeds use the IDs of LoopFeed’s sports data provider, the same as the rest of LoopFeed. For example, Arsenal is football team 9, and the Premier League is football competition 10001.

  • From a post: every curated post lists its teams, players and competitions in metadata.entities, and its match in metadata.matches, with their IDs.
  • From your topics: the Content API lists the teams you set on each topic, and the leagueId of each attached match.
  • Ask us: your account manager can send you the IDs for the competitions you cover.
  • Caching: feeds are cached for up to a minute, and a LoopFeed curation change clears them within seconds.
    • Token requests are shared through LoopFeed’s CDN: every visitor with the same token and URL gets the same cached response, and browsers keep it for up to 15 seconds (Cache-Control: public, max-age=15, s-maxage=60).
    • API key requests are cached only by your server or browser, for up to 60 seconds (Cache-Control: private, max-age=60).
    • Each response has an ETag. Send it back as If-None-Match, and you get 304 Not Modified with no body when nothing changed.
  • Rate limits: over a limit, you get 429 with a Retry-After header (seconds).
    • API key requests, minting tokens included, count towards your subscription’s limit of requests a minute. When your server reads feeds with the key, cache them rather than requesting them for every visitor.
    • Token requests are limited per visitor: 300 a minute from each IP address. They don’t count towards your subscription’s limit, however many visitors your pages have.

Errors return JSON with a message:

{ "error": "Invalid or expired feed token" }
StatusMeaning
400A parameter is invalid: a non-numeric ID, an unknown contentType or service, a bad cursor, or ttlSeconds out of range.
401No API key or token, or the key or token is unknown or expired, or the subscription is paused.
403The subscription doesn’t cover this sport, the request came from an IP address the key doesn’t allow (the message names the address), or the API key was sent from a browser.
404Unknown sport or kind in the path.
429Rate limit exceeded. Wait for Retry-After seconds.
5xxA temporary problem on our side. Retry with backoff.
Feed APITopic content API
What you getPosts about one match, team, player or competition, from every source LoopFeed curatesYour topic’s posts, from the sources and filters you chose
ModerationLoopFeed’s AI, checked by LoopFeed reviewersYou: hide, pin and edit in your queue
AccessSubscription and API keyPublic, by topic ID