TipsOverlayFailedPayload tips.overlay.failed@1

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

Version
1.0.0
Owner
tips
Visibility
first-party
Status
active
Compatibility
backward
Decision
ADR-012
Schema
https://openvibe.network/contracts/events/payloads/tips.overlay.failed.v1.json

tips.overlay.failed v1 (OpenVibe.Tips server/domain/overlays.js sweepFailed). No overlay showed the delivery within the delivery window. Envelope: subject { type: overlay_delivery, id: tovd_… }, visibility internal, priority important, actor service:tips. Never for tests.

Fields

FieldTypeRequiredDescriptionConstraints
delivery_idstringyes
  • pattern ^tovd_[0-9A-HJKMNP-TV-Z]{26}$
creatoridentity.subject-refyes
kindenumyes
  • one of "alert", "goal"
interaction_idstring | nullyes
goal_idstring | nullyes
reasonstringyes

Examples

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

Valid: goal
{
  "delivery_id": "tovd_01JAB3C4D5E6F7G8H9J0K1MNPT",
  "creator": {
    "type": "user",
    "id": "usr_01JAB2C3D4E5F6G7H8J9K0MNPQ"
  },
  "kind": "goal",
  "interaction_id": "tint_01JAB3C4D5E6F7G8H9J0K1MNPQ",
  "goal_id": "tgoal_01JAB3C4D5E6F7G8H9J0K1MNPS",
  "reason": "no overlay showed it within the delivery window"
}
Rejected: no-reason
{
  "delivery_id": "tovd_01JAB3C4D5E6F7G8H9J0K1MNPT",
  "creator": {
    "type": "user",
    "id": "usr_01JAB2C3D4E5F6G7H8J9K0MNPQ"
  },
  "kind": "alert",
  "interaction_id": "tint_01JAB3C4D5E6F7G8H9J0K1MNPQ",
  "goal_id": null
}

Validate

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