BlogBlogResult blog.blog-result@1

Generated at from openvibe-contracts v0.53.0 and openvibe-sdk v0.11.0.

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

blog.blog-result@1: the answer of PATCH /api/v1/blogs/:handle (blog.blog.configure) and PUT /api/v1/blogs/:handle/theme (blog.theme.set) on OpenVibe.Blog: { blog } with the member view; the theme answer adds themes (the presets).

Fields

FieldTypeRequiredDescriptionConstraints
blogblog.blogyes
themesarray of string

Examples

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

Valid: theme
{
  "blog": {
    "id": "blg_01JAB2C3D4E5F6G7H8J9K0MNPQ",
    "kind": "member",
    "handle": "alice",
    "title": "Alice builds things",
    "description": "Garage projects and stream tech.",
    "url": "https://openvibe.blog/@alice",
    "theme": "paper",
    "language": "en",
    "feeds": [
      {
        "type": "rss",
        "url": "https://openvibe.blog/@alice/feed.xml"
      },
      {
        "type": "json",
        "url": "https://openvibe.blog/@alice/feed.json"
      }
    ]
  },
  "themes": [
    "vibe",
    "paper",
    "slate",
    "sand",
    "nord",
    "high-contrast"
  ]
}
Rejected: no-blog
{
  "themes": []
}

Validate

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