For the complete documentation index, see llms.txt. This page is also available as Markdown.

Save Database Schema

save Database Schema.

A schema defines a collection's fields, types, and validation. Schemas support drafts, versions, and publishing. This method creates the database schema and returns its id.

This method is on the Hub surface (norbix.hub.database) β€” call it from admin tooling or IaC.

These examples assume the SDK is installed and your credentials are set as environment variables β€” each client reads them automatically, so the constructors below take no arguments. See Install a Norbix SDK.

import { Norbix } from '@norbix.ai/ts';
const norbix = new Norbix();

const result = await norbix.hub.database.saveDatabaseSchema({
  schemaName: 'orders',
  viewId: 'view_4kX9mQvR2tYw7ZbC1dFgHj',
  dataSchema: '{"type":"object"}',
  visualSchema: '{}',
});
using Norbix.Sdk;
using Norbix.Sdk.Types.Hub;

using var client = new NorbixClient();

var result = await client.Database.SaveDatabaseSchemaAsync(new SaveDatabaseSchemaRequest
{
    SchemaName = "orders",
    ViewId = "view_4kX9mQvR2tYw7ZbC1dFgHj",
    DataSchema = "{\"type\":\"object\"}",
    VisualSchema = "{}",
});

In the dashboard

Manage this visually in Norbix Cloud β€” see Database β†’ Schemas.

API reference

Full request and response for this endpoint: Save Database Schema.

Last updated