ExchangeChatExportResult exchange.chat-export-result@1

Generated at from openvibe-contracts v0.419.0 and openvibe-sdk v0.161.0.

Version
1.0.0
Owner
exchange
Visibility
first-party
Status
active
Compatibility
backward
Schema
https://openvibe.network/contracts/exchange/chat-export-result.v1.json

Unsealed chats and messages of exactly the named person, for their import into Chat.

Fields

FieldTypeRequiredDescriptionConstraints
countintegeryes
  • minimum 0
chatsarray of objectyes
  • items: no other fields
chats[].idstringyes
chats[].titlestringyes
chats[].modelsarray of stringyes
  • maxItems 3
chats[].created_atstring
chats[].updated_atstring
chats[].messagesarray of objectyes
  • items: no other fields
chats[].messages[].rolestringyes
chats[].messages[].modelstring | null
chats[].messages[].contentstring | null
chats[].messages[].created_atstring
chats[].messages[].metaobject

Examples

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

Valid: one-chat
{
  "count": 1,
  "chats": [
    {
      "id": "exc_example",
      "title": "A chat",
      "models": [
        "deepseek/deepseek-chat"
      ],
      "created_at": "2026-11-01T10:00:00.000Z",
      "updated_at": "2026-11-01T10:01:00.000Z",
      "messages": [
        {
          "role": "user",
          "model": null,
          "content": "Hello",
          "created_at": "2026-11-01T10:00:00.000Z",
          "meta": {}
        },
        {
          "role": "assistant",
          "model": "deepseek/deepseek-chat",
          "content": "Hi",
          "created_at": "2026-11-01T10:01:00.000Z",
          "meta": {}
        }
      ]
    }
  ]
}
Rejected: no-chats
{
  "count": 1
}

Validate

const contracts = require('openvibe-contracts');
contracts.validate('exchange.chat-export-result@1', value);   // { valid, errors: [{ path, message }] }