跳转到内容
EN

创建剪辑项目

POST /cut/v1/projects

Create a blank editing project in the API key organization before writing a script. First obtain accessible library ids from praxis.media; bindings must include exactly one read_write library with default_upload true. Each call creates a new project and returns HTTP 201; save its id for execute, state and timeline calls. All editing positions use seconds.

支持状态: supported

请求体 (application/json)

必填: true

名称类型说明
namestringHuman-readable project name; required and must contain non-whitespace text.
labelsobjectUser-defined string labels for organizing projects; label keys retain their original spelling.
settingsobjectDimensions and frame rate for a new editing project.
settings.widthintegerOutput width in pixels; even integer between 16 and 4096.
settings.heightintegerOutput height in pixels; even integer between 16 and 4096.
settings.fpsnumber | objectProject frames per second, as a positive number or an exact num/den fraction.
settings.backgroundstringBackground color as #RRGGBB or #RRGGBBAA; omission uses black.
bindingsarray<object>Accessible library bindings; exactly one read_write entry must have default_upload true.
bindings[].namestringUnique binding alias used in imports and exports; begins with a lowercase letter.
bindings[].library_idstringMedia library id from praxis.media.libraries.create or list; must be accessible to this organization.
bindings[].accessstringread permits using library assets; read_write also permits imports and exports into the library.
bindings[].default_uploadbooleanTrue selects the one read_write library used when an import or export omits binding.
{
"type": "object",
"description": "Create a blank project bound to the media libraries it may use.",
"properties": {
"name": {
"type": "string",
"description": "Human-readable project name; required and must contain non-whitespace text."
},
"labels": {
"type": "object",
"description": "User-defined string labels for organizing projects; label keys retain their original spelling.",
"additionalProperties": {
"type": "string"
}
},
"settings": {
"$ref": "#/components/schemas/cut-SettingsInput"
},
"bindings": {
"type": "array",
"description": "Accessible library bindings; exactly one read_write entry must have default_upload true.",
"items": {
"$ref": "#/components/schemas/cut-Binding"
}
}
},
"required": [
"name",
"settings",
"bindings"
]
}

响应

HTTP 201

New resource; save its id for subsequent calls.

application/json

名称 类型 说明
id string Project id assigned by create; pass as project_id on subsequent requests.
name string Human-readable editing project name; not an API identifier.
owner string Organization that owns the project and its editing history.
labels object User-defined string labels for organizing projects; label keys retain their original spelling.
state string active projects can be edited; deleted projects are retained until purge_time and may be undeleted.
revision integer Committed project revision from retrieve, state, timeline or execute; increases after each successful write.
settings object Rendering dimensions, frame rate and audio sample rate for this project.
settings.width integer Output width in pixels; even integer between 16 and 4096.
settings.height integer Output height in pixels; even integer between 16 and 4096.
settings.fps object Exact frames-per-second fraction used to snap second-based edits to project frames.
settings.background string Background color as #RRGGBB or #RRGGBBAA; omission uses black.
settings.sample_rate integer Project audio sample rate in hertz; fixed at 48000.
bindings array<object> Named library bindings available to scripts, imports and exports.
bindings[].name string Unique binding alias used in imports and exports; begins with a lowercase letter.
bindings[].library_id string Media library id from praxis.media.libraries.create or list; must be accessible to this organization.
bindings[].access string read permits using library assets; read_write also permits imports and exports into the library.
bindings[].default_upload boolean True selects the one read_write library used when an import or export omits binding.
create_time string ISO 8601 timestamp when this project was created.
console_url string Link that opens this project in the Praxis Console, in the Console of the environment serving the request. Open this URL when telling a user where to edit the project, and use the value as given — do not build the link yourself, because the Console host differs per environment (develop and production are different hosts) and a composed address will not open.
update_time string ISO 8601 timestamp of the latest committed project update.
purge_time string ISO 8601 deadline for permanent removal of a deleted project; absent for active projects.