SourcesItemUpdatedPayload sources.item.updated@1

Generated at from openvibe-contracts v0.33.0 and openvibe-sdk v0.5.0.

Version
1.0.0
Owner
sources
Visibility
first-party
Status
active
Compatibility
backward
Decision
ADR-017
Schema
https://openvibe.network/contracts/events/payloads/sources.item.updated.v1.json

sources.item.updated v1 (OpenVibe.Sources server/items.js ingest → itemEvent). A successful fetch or manual entry changed an existing item's content hash, which made a new revision. A removed item is never updated (removal is sticky). Envelope: subject { type: item, id: <item_id>, revision }, visibility internal, priority important, actor service:sources.

Fields

FieldTypeRequiredDescriptionConstraints
item_idstringyes
  • pattern ^itm_[0-9A-HJKMNP-TV-Z]{26}$
source_keystringyes
  • pattern ^[a-z0-9][a-z0-9-]{1,63}$
categoryenumyes
  • one of "news", "blog", "reviews", "deals", "coupons", "trade"
kindstringyesarticle | url | sitemap | product | offer | review | record … (sources.item@1 kind).
  • pattern ^[a-z][a-z0-9_]{1,39}$
canonical_urlstring | nullyes
  • format uri
titlestring | nullyes
revisionintegeryes
  • minimum 1
content_hashstringyes
  • pattern ^[0-9a-f]{64}$
retrieved_atstringyesLast successful fetch (or manual entry) that contained the item.
  • format date-time
previous_content_hashstringyes
  • pattern ^[0-9a-f]{64}$

Examples

From the contract's own test fixtures: valid ones validate, rejected ones must fail.

Valid: new-revision
{
  "item_id": "itm_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "source_key": "bbc-world",
  "category": "news",
  "kind": "article",
  "canonical_url": "https://www.bbc.co.uk/news/world-12345678",
  "title": "Summit ends without agreement on climate",
  "revision": 2,
  "content_hash": "60303ae22b998861bce3b28f33eec1be758a213c86c93c076dbe9f558c11c752",
  "retrieved_at": "2026-09-23T09:00:00.000Z",
  "previous_content_hash": "9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"
}
Rejected: no-previous-hash
{
  "item_id": "itm_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "source_key": "bbc-world",
  "category": "news",
  "kind": "article",
  "canonical_url": null,
  "title": null,
  "revision": 2,
  "content_hash": "60303ae22b998861bce3b28f33eec1be758a213c86c93c076dbe9f558c11c752",
  "retrieved_at": "2026-09-23T09:00:00.000Z"
}

Validate

const contracts = require('openvibe-contracts');
contracts.validate('sources.item.updated@1', value);   // { valid, errors: [{ path, message }] }