---
title: "quest.app-quest@1 · OpenVibe.Services"
canonical: "https://openvibe.services/docs/contracts/quest.app-quest"
updated: null
---

# quest.app-quest@1 · OpenVibe.Services

HTML: [quest.app-quest@1 · OpenVibe.Services](https://openvibe.services/docs/contracts/quest.app-quest)

# QuestAppQuest `quest.app-quest@1`

Generated at 2026-12-01 05:42:00 UTC from [`openvibe-contracts v0.454.0`](https://github.com/OpenVibers/OpenVibe.Contracts/tree/v0.454.0) and [`openvibe-sdk v0.193.0`](https://github.com/OpenVibers/OpenVibe.SDK/tree/v0.193.0).

- Version: 1.0.0
- Owner: quest
- Visibility: public
- Status: active
- Compatibility: backward
- Schema: [`https://openvibe.network/contracts/quest/app-quest.v1.json`](/docs/contracts/quest.app-quest.json)

quest.app-quest@1: one app quest as OpenVibe.Quest keeps it (the answer to PUT and GET /api/v1/app-quests\[/:slug\]). id is app.<project\_key>.<slug>; badge.id is the same id; completions counts the people who finished it.

## Fields

| Field | Type | Required | Description | Constraints |
| --- | --- | --- | --- | --- |
| `id` | string | yes |  | - `pattern ^app\.p[0-9a-z]{26}\.[a-z0-9][a-z0-9-]{0,47}$` |
| `slug` | string | yes |  | - `pattern ^[a-z0-9][a-z0-9-]{0,47}$` |
| `project_id` | string | yes |  | - `pattern ^prj_[0-9A-HJKMNP-TV-Z]{26}$` |
| `app` | string | yes | The app that last defined it. | - `pattern ^app:app_[0-9A-HJKMNP-TV-Z]{26}$` |
| `env` | enum | yes |  | - `one of "sandbox", "production"` |
| `title` | string | yes |  | - `minLength 1`<br>- `maxLength 80` |
| `why` | string \| null |  |  | - `maxLength 300` |
| `steps` | array of object | yes |  | - `minItems 1`<br>- `maxItems 5`<br>- `items: no other fields` |
| `steps[].event_type` | string | yes | One of the app's own event types (app.<project\_key>.<name>), as it publishes them at OpenVibe.Events. | - `pattern ^app\.p[0-9a-z]{26}\.[a-z0-9_]+(\.[a-z0-9_]+){0,3}$` |
| `steps[].count` | integer | yes |  | - `minimum 1`<br>- `maximum 1000` |
| `steps[].label` | string | yes |  | - `minLength 1`<br>- `maxLength 120` |
| `badge` | object | yes |  | - `no other fields` |
| `badge.id` | string | yes |  |  |
| `badge.name` | string | yes |  | - `minLength 1`<br>- `maxLength 40` |
| `url` | string \| null |  |  | - `maxLength 500` |
| `status` | enum | yes |  | - `one of "active", "retired"` |
| `created_at` | string | yes |  | - `format date-time` |
| `updated_at` | string | yes |  | - `format date-time` |
| `completions` | integer | yes |  | - `minimum 0` |

## Examples

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

 Valid: one

~~~~
{
  "id": "app.p01jab2c3d4e5f6g7h8j9k0mnpq.collector",
  "slug": "collector",
  "project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "app": "app:app_01JAB2C3D4E5F6G7H8J9K0MNPR",
  "env": "production",
  "title": "Collector",
  "why": null,
  "steps": [
    {
      "event_type": "app.p01jab2c3d4e5f6g7h8j9k0mnpq.gem.found",
      "count": 5,
      "label": "Find a gem"
    }
  ],
  "badge": {
    "id": "app.p01jab2c3d4e5f6g7h8j9k0mnpq.collector",
    "name": "Gem Collector"
  },
  "url": null,
  "status": "active",
  "created_at": "2026-10-15T22:00:00.000Z",
  "updated_at": "2026-10-15T22:00:00.000Z",
  "completions": 0
}
~~~~

Rejected: bad-id

~~~~
{
  "id": "live.collector",
  "slug": "collector",
  "project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "app": "app:app_01JAB2C3D4E5F6G7H8J9K0MNPR",
  "env": "production",
  "title": "Collector",
  "why": null,
  "steps": [
    {
      "event_type": "app.p01jab2c3d4e5f6g7h8j9k0mnpq.gem.found",
      "count": 5,
      "label": "Find a gem"
    }
  ],
  "badge": {
    "id": "x",
    "name": "x"
  },
  "url": null,
  "status": "active",
  "created_at": "2026-10-15T22:00:00.000Z",
  "updated_at": "2026-10-15T22:00:00.000Z",
  "completions": 0
}
~~~~

## Validate

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