PlayPlayerAchievements play.player-achievements@1
Generated at from
openvibe-contracts v0.177.0 and
openvibe-sdk v0.44.0.
- Version
- 1.0.0
- Owner
- play
- Visibility
- public
- Status
- active
- Compatibility
- backward
- Decision
- Games ADR-0007
- Schema
https://openvibe.network/contracts/play/player-achievements.v1.json
One player's unlocked achievements in a title the caller manages (play.player.read), newest first.
Fields
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
title | string | yes |
| |
player | string | yes | a person (usr_) or a guest the title names (guest:<opaque>) |
|
achievements | array of object | yes |
| |
achievements[].id | string | yes |
| |
achievements[].name | string | yes | ||
achievements[].description | string | |||
achievements[].unlocked_at | string | yes |
|
Examples
From the contract's own test fixtures: valid ones validate, rejected ones must fail.
Valid: basic
{
"title": "salvage-rush",
"player": "usr_01JABCDEFGHJKMNPQRSTVWXYZ0",
"achievements": [
{
"id": "first-haul",
"name": "First Haul",
"description": "Finish a round with scrap.",
"unlocked_at": "2026-10-14T12:00:00.000Z"
}
]
}Rejected: basic
{
"title": "salvage-rush",
"player": "nobody",
"achievements": []
}Validate
const contracts = require('openvibe-contracts');
contracts.validate('play.player-achievements@1', value); // { valid, errors: [{ path, message }] }