Skip to content

Content Recommendations API Reference

The Content Recommendations platforms offers two APIs:

  • Collector API β€” ingests content metadata and user behavior events.
  • Recommender API β€” serves personalized recommendations.

Server

https://{org}-config-prod.api.arc-cdn.net/
VariableDescriptionDefault
orgOrganization identifierorg

Endpoints overview

MethodPathSummary
POST/collector/v1/contentIngest Content
POST/collector/v1/eventsIngest Event
POST/collector/v1/events/batchIngest Events Batch
GET/recommend/recommendationsGet Recommendations

Collector API

POST /collector/v1/content

Ingest content metadata. The request body accepts either an UpsertContent payload (publish or update an item) or a DeleteContent payload (remove an item from the catalogue), discriminated by the action field.

Tags: Collector, Content

Request body

application/json β€” one of UpsertContent or DeleteContent.

Responses

StatusDescriptionSchema
202Accepted. The request is queued for asynchronous processing.β€”
422Validation ErrorHTTPValidationError

Example β€” publish

{
"action": "publish",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"site_id": "site-1",
"type": "article",
"timestamp": "2026-03-27T14:30:00+00:00",
"title": "Election results, day three",
"categories": ["Politics"],
"tags": ["election-2026", "results"],
"author": "Jane Doe",
"is_premium": false,
"metadata": {}
}

Example β€” delete

{
"action": "delete",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"site_id": "site-1"
}

POST /collector/v1/events

Ingest a single user-behavior event.

Tags: Collector, Events

Request body

application/json β€” FYEventEnvelope.

Responses

StatusDescriptionSchema
202Accepted. The event is queued for asynchronous processing.β€”
422Validation ErrorHTTPValidationError

Example

{
"user_id": "abc-123",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"event_type": "video_progress",
"timestamp": "2026-03-27T14:32:00+00:00",
"event_value": 0.75,
"session_id": "sess-a1b2c3"
}

POST /collector/v1/events/batch

Ingest a batch of user-behavior events in a single request.

Tags: Collector, Events

Request body

application/json β€” array of FYEventEnvelope.

Responses

StatusDescriptionSchema
202Accepted. All events are queued for asynchronous processing.β€”
422Validation ErrorHTTPValidationError

Example

[
{
"user_id": "abc-123",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"event_type": "page_view",
"timestamp": "2026-03-27T14:30:00+00:00"
},
{
"user_id": "abc-123",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"event_type": "video_progress",
"timestamp": "2026-03-27T14:32:00+00:00",
"event_value": 0.75,
"session_id": "sess-a1b2c3"
}
]

Recommender API

GET /recommend/recommendations

Return a ranked list of recommended items for a user on a given site.

Tags: Recommendations

Query parameters

NameTypeRequiredDefaultDescription
site_idstringyesβ€”Site scoping β€” used to partition content and signals by website.
user_idstringyesβ€”Identifier of the user receiving recommendations.
item_idstring | nullnoβ€”Anchor item for β€œmore like this” use cases.
num_resultsinteger (1–50)no5Number of recommendations to return. Capped at 50 to keep response payloads bounded.
subscription_tierstring | nullnoβ€”Caller subscription level (e.g. "free", "premium").
device_typestring | nullnoβ€”Requesting device class (e.g. "mobile", "desktop").

Responses

StatusDescriptionSchema
200Successful ResponseRecommendationResponse
422Validation ErrorHTTPValidationError

Example response

{
"recommendations": [
{
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"score": 0.91
},
{
"item_id": "JYRPLD7XKVAU2NHM4FZQ6BTACE",
"score": 0.84
}
]
}

Schemas

Content schemas

UpsertContent

Request body for adding or updating a content item.

FieldTypeRequiredDefaultDescription
action"publish" (literal)yesβ€”Discriminator value.
item_idstringyesβ€”Stable item identifier.
site_idstringyesβ€”Site this item belongs to.
typeItemTypeyesβ€”Content type classification.
timestampstring (ISO 8601, timezone-aware)yesβ€”Publication date.
titlestringyesβ€”Display title.
categoriesstring[]noβ€”High-level taxonomy (e.g. Politics, Sports).
tagsstring[]noβ€”Detailed keywords.
authorstring | nullnoβ€”Content creator.
is_premiumbooleannofalseWhether content is behind a paywall.
metadataobjectnoβ€”Flexible tenant-specific fields (additional properties allowed).

DeleteContent

Request body for deleting a content item.

FieldTypeRequiredDescription
action"delete" (literal)yesDiscriminator value.
item_idstringyesIdentifier of the item to delete.
site_idstringyesSite the item belongs to.

ItemType

Content type classification for items. Enum.

Value
article
video
podcast

Event schemas

FYEventEnvelope

Canonical representation of an inbound CDP event. All CDP vendor adapters must produce this shape.

FieldTypeRequiredDescription
user_idstringyesIdentifier of the user who triggered the event.
item_idstringyesItem the user interacted with.
event_typeEventTypeyesType of interaction.
timestampstring (ISO 8601, timezone-aware)yesWhen the interaction occurred.
event_valuenumber | nullnoNumeric value (e.g. watch percentage 0.0–1.0).
session_idstring | nullnoSession identifier for grouping interactions.
Examples
{
"event_type": "page_view",
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"timestamp": "2026-03-27T14:30:00+00:00",
"user_id": "abc-123"
}
{
"event_type": "video_progress",
"event_value": 0.75,
"item_id": "ZSGXFR2KNFCMPN3VHPWQR3BGCE",
"session_id": "sess-a1b2c3",
"timestamp": "2026-03-27T14:32:00+00:00",
"user_id": "abc-123"
}

EventType

Types of user interactions captured by the system. Enum.

Value
page_view
click
video_start
video_complete
video_progress
search
share

Recommendation schemas

RecommendationResponse

Top-level response envelope for the recommendations endpoint.

FieldTypeRequiredDescription
recommendationsScoredItem[]yesRecommended items, ordered by adjusted score.

ScoredItem

A single recommended item with its adjusted score. Score reflects post-reranking state β€” editorial signals (boosts, buries, pins) have already been applied by the time this is returned to the caller.

FieldTypeRequiredDescription
item_idstringyesCMS item identifier.
scorenumberyesAdjusted recommendation score (post-reranking), ranging from 0.0 to 1.0.

Error schemas

HTTPValidationError

Returned when request validation fails (HTTP 422).

FieldTypeRequiredDescription
detailValidationError[]noOne entry per failed validation rule.

ValidationError

Detail entry for a single failed validation rule.

FieldTypeRequiredDescription
loc(string | integer)[]yesLocation of the offending field (e.g. ["body", "item_id"]).
msgstringyesHuman-readable error message.
typestringyesError type identifier (e.g. value_error.missing).
inputanynoThe input value that failed validation.
ctxobjectnoAdditional error context.