POST /ng-cms/content/{projectId}/{typeKey}

Create a content entry

Параметры запроса

projectId string
Обязательный

The unique identifier of the project

typeKey string
Обязательный

The key of the content type (e.g. blog-post). Must match an existing content type in the project.

Тело запроса

CreateContentEntryRequest
fields object
Обязательный

Key-value map of field data. Keys must match the field keys defined in the content type schema. Values are validated against each field's type and constraints.

Ответы

201 Entry created successfully in Draft status. Returns the new entry ID.

тип: ApiResponse<string>

success boolean Indicates whether the request was successful
result string The ID of the newly created content entry
errors ErrorDetail[] List of errors (empty on success)
400 Validation failed — fields do not satisfy the content type schema constraints.

тип: ApiResponse<T>

isValid boolean Always false for validation errors
validationErrors ValidationError[] List of validation failures
name string Field that failed validation
attemptedValue object The value that was submitted
message string Human-readable validation message
401 Unauthorized. A valid API key is required.
404 Not Found. No content type exists with the given typeKey in this project.
412 Precondition Failed. The project's current plan does not allow access to this resource, or payment is required to proceed.
500 Unexpected server error.

тип: ApiResponse<T>

success boolean Always false
errors ErrorDetail[] List of server-side errors
correlationId string Unique ID for tracing the error
message string Error message
stack string Stack trace (non-production only)

Оставаясь на сайте, Вы даете свое согласие на использование файлов cookie