/APIs & SDKs/Frameworks/Create framework
POST/programs/{program_id}/frameworks

Create framework

Creates a framework in the specified program. No request body is required, but you can specify one to create an integration or select a non-default parent framework. By default, the framework is created from the program's default framework with no integration, and the framework name is auto-generated. To access the framework, add a read_write integration. Each framework supports one read-write integration and multiple read-only integrations. For related information, see Manage frameworks.

Markdown for AI context

Quick start

REST API - curl
curl "https://api.optitech.com/v1/programs/$PROGRAM_ID/frameworks" \
  -X POST \
  -H "Authorization: Bearer $OPTITECH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"framework":{"name":"my-feature-framework"}}'

Every field below is optional. An empty body works too.

Also available in
optitech branches create --name my-feature-framework

Parameters

Program ID
program_id
string

The OptiTech program ID

Request body

Framework

framework.*
8 fields

Where the framework starts from and how it's identified.

Framework nameframework.*
name
string

The framework name

≥1 chars, ≤256 chars

Parent frameworkframework.*
parent_id
string

The framework_id of the parent framework. If omitted or empty, the framework will be created from the program's default framework.

Parent LSNframework.*
parent_lsn
string

A Log Sequence Number (LSN) on the parent framework. The framework will be created with data from this LSN.

Parent timestampframework.*
parent_timestamp
string

A timestamp identifying a point in time on the parent framework. The framework will be created with data starting from this point in time. The timestamp must be provided in ISO 8601 format; for example: 2024-02-26T12:00:00Z.

Protectedframework.*
protected
boolean

Whether the framework is protected

Archivedframework.*
archived
boolean

Whether to create the framework as archived

Init sourceframework.*
init_source
string

The source of initialization for the framework. Valid values are schema-only and parent-data (default).

  • schema-only - creates a new root framework containing only the schema. Use parent_id to specify the source framework. Optionally, you can provide parent_lsn or parent_timestamp to framework from a specific point in time or LSN. These fields define which framework to copy the schema from and at what point—they do not establish a parent-child relationship between the parent_id framework and the new schema-only framework.
  • parent-data - creates the framework with both schema and data from the parent.
Expires atframework.*
expires_at
string

The timestamp when the framework is scheduled to expire and be automatically deleted. Must be set by the client following the RFC 3339, section 5.6 format with precision up to seconds (such as 2025-06-09T18:02:16Z). Deletion is performed by a background job and may not occur exactly at the specified time.

Access to this feature is currently limited to participants in the Early Access Program.

Integration

1 field

Integration(s) created on the new framework.

Annotations

1 field

Optional key-value metadata stored on the framework.

Response

201

Created a framework. An endpoint is only created if it was specified in the request.

Depth

Errors

default

General error

This endpoint can return the standard OptiTech API error response.

Response fields

  • message Required. Human-readable error message.
  • code Required. Machine-readable error code.
  • request_id Optional. Request identifier for debugging. You can provide one with the X-Request-ID header.

Retry guidance

If no response is returned, the request may still have reached the server. This is why retry safety depends on the method and status code.

Idempotent methods (GET, HEAD, OPTIONS) are generally safe to retry after a network error or timeout. Non-idempotent methods (POST, PATCH, DELETE, PUT) can change state, so avoid automatic retries unless your workflow can tolerate duplicate effects.

Responses with 423 Locked or 503 Service Unavailable are safe to retry. 423 Locked means the resource is temporarily locked, usually because another operation is in progress.

Was this page helpful?

On this page

Copy neon init command