Update an existing video project with new settings, AI features, or user media (B-roll) insertions. This endpoint allows you to modify project parameters and enhance your video with additional features or custom media content from your library.
This endpoint requires authentication and has a rate limit of 100 requests per
hour. After modifying a video, you’ll need to re-export to see the changes
using the export endpoint. When using removeBadTakes, the response may take
1-2 minutes as our AI processes the video.
All fields are optional. Only provide the fields you want to update. If a field is provided with a different value from the current project settings, it will be updated.
Edit the project’s captions. Fetch the current transcript from
Get Project, change anything you want (text,
timing, add or remove words), and send the full array back — it replaces
the transcript, so include every word you want to keep. The caption layout is
rebuilt automatically.Requirements (otherwise VALIDATION_ERROR): the project must already be
transcribed, and words must stay in chronological order — each startTime
greater than or equal to the previous word’s.Can be combined with other fields in the same request: the words are applied
first, then the rest. If the words edit fails, nothing else is applied.
Automatically remove silence from the video at the specified pace. Allowed
values: natural, fast, extra-fast. - extra-fast: 0.1-0.2 seconds of
silence removal - fast: 0.2-0.6 seconds of silence removal - natural: 0.6+
seconds of silence removal
Vertical caption position as a percentage from the top of the frame (0-80).
Applies to all captions, replacing any per-line position adjustments.
Re-export the project to see the change.
Update the animated hook caption shown at the start of the video. Set to
true to enable the default AI-generated hook, false to remove it, or pass
an object with optional overrides:
text: Custom copy (1-100 characters)
template: Hook title template name (defaults to "tiktok"). Fetch valid
names using the hook title templates
endpoint.
top: Vertical position between 0-80 (default 50)
size: Font size between 0-80 (default 30)
Template names are validated before processing resumes; invalid names return
VALIDATION_ERROR immediately.
UUID of the music track. Accepts either an AUDIO file from your media
library (use List User Media) or a Trendy
Music track ID (copied from the editor’s Edit Audio → Trendy Music tab).
Array describing B-roll edits. Provide at least one entry when this field is
included. Each item must include a type field to specify whether it’s user
media from your library or AI-generated content.
Layout mode for the inserted media. Available values depend on the media type:Video media:"cover", "contain", "rounded", "square", "split-50-50", "split-35-65", "split-50-50-bordered", "split-35-65-bordered", "pip-top-right", "pip-bottom-right"Image media:"cover", "contain", "rounded", "square"
Every AI B-roll item consumes 3 AI credits. Requests fail with
VALIDATION_ERROR if the authenticated user lacks enough credits (unless their
balance is unlimited).
When AI B-roll work is accepted, the project is moved back to processing and
the generation jobs run asynchronously. Your webhook or polling logic should
watch for the project to return to completed.
Stock/user-media updates continue to succeed immediately with the traditional
Project updated successfully message.
Success message confirming the project update. When AI B-roll work is accepted,
the message is Project update accepted to indicate asynchronous rendering.
{ "error": "VALIDATION_ERROR", "message": "Project is not transcribed yet; words can only be edited after transcription completes."}
{ "error": "NOT_FOUND", "message": "Project not found"}
{ "error": "VALIDATION_ERROR", "message": "endTime must be greater than startTime"}
{ "error": "VALIDATION_ERROR", "message": "Invalid UUID format for userMediaId"}
Important: After updating a project, you must re-export the project to see
the changes in the final video. Use the export endpoint to generate the
updated video with your modifications. Processing Time: When using
removeBadTakes, the API response may take 1-2 minutes as our AI analyzes and
processes the video to detect and remove bad takes and silence.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/schema.json","name":"Submagic API","colors":{"primary":"#ff6b35","light":"#ff8c66","dark":"#e55a2b"},"logo":{"light":"https://mintcdn.com/submagic/Gyf5dEe3UuhgkFDU/logo-dark.png?fit=max\u0026auto=format\u0026n=Gyf5dEe3UuhgkFDU\u0026q=85\u0026s=1ee650d8a4e56baa2c938294da5e446d","dark":"https://mintcdn.com/submagic/Gyf5dEe3UuhgkFDU/logo-light.png?fit=max\u0026auto=format\u0026n=Gyf5dEe3UuhgkFDU\u0026q=85\u0026s=8855b86b66c90c7f8edb57155622a80e","href":"https://submagic.co"},"favicon":"https://mintcdn.com/submagic/smJEP_sOUx1zlYbc/favicon.svg?fit=max\u0026auto=format\u0026n=smJEP_sOUx1zlYbc\u0026q=85\u0026s=1547171b4db227c4a526b3e340876175","api":{},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"llms.txt","icon":"file-text","href":"https://docs.submagic.co/llms-full.txt"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"submagic","hasAudioNarration":false,"actualSubdomain":"submagic","customDomains":["docs.submagic.co"],"gitSource":{"type":"github","owner":"turbo-magic","repo":"submagic-api-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6abd51599d353a69cc5bb0d4","collectionId":"81f6fc60-53d5-4fc6-9c4d-1627816a9184","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6abd51599d353a69cc5bb0d4"},"entitlements":{},"buildId":"6abd51599d353a69cc5bb0d4","clientVersion":"0.0.4076","searchFilterCounts":[{"language":"default","tag":"API Reference","count":22},{"language":"default","tag":"Get Started","count":4},{"language":"default","tag":"Guides","count":1}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":".smc-connect{--smc-text: #18181b;--smc-muted: #52525b;--smc-border: rgba(9, 9, 11, 0.1);--smc-fill: rgba(9, 9, 11, 0.04);--smc-fill-hover: rgba(9, 9, 11, 0.08);--smc-surface: #ffffff;--smc-claude: #d97757;--smc-claude-hover: #cc6a4a;--smc-claude-edge: #a8583d;display:flex;flex-direction:column;align-items:center;gap:1.25rem;margin:1.5rem 0;padding:2rem 1.5rem;border:1px solid var(--smc-border);border-radius:1rem}.dark .smc-connect{--smc-text: #fafafa;--smc-muted: #a1a1aa;--smc-border: rgba(255, 255, 255, 0.1);--smc-fill: rgba(255, 255, 255, 0.05);--smc-fill-hover: rgba(255, 255, 255, 0.1);--smc-surface: #18181b}.smc-connect .smc-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:0.75rem}.smc-connect .smc-btn{display:inline-flex;align-items:center;gap:0.625rem;padding:0.75rem 1.25rem;border:1px solid transparent;border-radius:0.75rem;font-size:1rem;font-weight:600;line-height:1.5rem;text-decoration:none;cursor:pointer;transition:background-color 0.15s,\n transform 0.1s,\n box-shadow 0.1s}.smc-connect .smc-btn svg,.smc-connect .smc-btn img{width:1.25rem;height:1.25rem;margin:0;flex-shrink:0}.smc-connect .smc-btn-primary{background:var(--smc-claude);color:#ffffff;box-shadow:0 4px 0 0 var(--smc-claude-edge)}.smc-connect .smc-btn-primary:hover{background:var(--smc-claude-hover);color:#ffffff}.smc-connect .smc-btn-primary:active{transform:translateY(2px);box-shadow:0 2px 0 0 var(--smc-claude-edge)}.smc-connect .smc-btn-secondary{background:var(--smc-fill);border-color:var(--smc-border);color:var(--smc-text)}.smc-connect .smc-btn-secondary:hover{background:var(--smc-fill-hover);color:var(--smc-text)}.smc-connect .smc-url{display:inline-flex;align-items:center;gap:0.5rem;padding:0.25rem 0.5rem;border:0;border-radius:0.5rem;background:none;color:var(--smc-muted);font-family:ui-monospace, SFMono-Regular, Menlo, monospace;font-size:0.875rem;cursor:pointer;transition:color 0.15s}.smc-connect .smc-url:hover{color:var(--smc-text)}.smc-connect .smc-url svg{width:1rem;height:1rem}.smc-connect .smc-url-copied svg{color:#10b981}.smc-connect .smc-modal{width:calc(100vw - 2rem);max-width:68rem;max-height:calc(100vh - 2rem);margin:auto;padding:0;overflow-y:auto;border:1px solid var(--smc-border);border-radius:1rem;background:var(--smc-surface);color:var(--smc-text);box-shadow:0 25px 50px -12px rgba(0, 0, 0, 0.4)}.smc-connect .smc-modal::backdrop{background:rgba(0, 0, 0, 0.6);backdrop-filter:blur(4px)}.smc-connect .smc-modal-body{position:relative;display:grid;grid-template-columns:minmax(0, 1fr)}.smc-connect .smc-close{position:absolute;top:0.75rem;right:0.75rem;z-index:1;display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;border:0;border-radius:9999px;background:none;color:var(--smc-muted);cursor:pointer}.smc-connect .smc-close:hover{background:var(--smc-fill-hover);color:var(--smc-text)}.smc-connect .smc-close svg{width:1rem;height:1rem}.smc-connect .smc-steps{display:flex;flex-direction:column;margin:0;padding:1.5rem;list-style:none}.smc-connect .smc-step{display:flex;flex-direction:column;align-items:flex-start;gap:0.75rem;margin:0;padding:1.5rem 0;border-bottom:1px solid var(--smc-border)}.smc-connect .smc-step:first-child{padding-top:0}.smc-connect .smc-step:last-child{padding-bottom:0;border-bottom:0}.smc-connect .smc-step .smc-btn{margin-top:0.25rem}.smc-connect .smc-step-number{display:flex;align-items:center;justify-content:center;width:2.25rem;height:2.25rem;border-radius:9999px;background:var(--smc-fill-hover);color:var(--smc-text);font-size:0.875rem;font-weight:600}.smc-connect .smc-step-title{display:flex;flex-wrap:wrap;align-items:center;gap:0.5rem;margin:0;color:var(--smc-text);font-size:1.125rem;font-weight:600}.smc-connect .smc-step-title img{width:1.25rem;height:1.25rem;margin:0}.smc-connect .smc-step-text{margin:0;color:var(--smc-muted);font-size:0.875rem;line-height:1.6}.smc-connect .smc-step-text a{color:var(--smc-text);text-decoration:underline;text-underline-offset:2px}.smc-connect .smc-mono{color:var(--smc-text);font-family:ui-monospace, SFMono-Regular, Menlo, monospace;white-space:nowrap}.smc-connect .smc-media{display:flex;align-items:center;padding:0 1.5rem 1.5rem}.smc-connect .smc-media video{display:block;width:100%;aspect-ratio:16 / 9;object-fit:contain;border:1px solid var(--smc-border);border-radius:0.75rem;background:#09090b}@media (min-width: 768px){.smc-connect .smc-modal-body{grid-template-columns:minmax(0, 5fr) minmax(0, 6fr)}.smc-connect .smc-steps{padding:2.5rem}.smc-connect .smc-media{padding:3.5rem 2.5rem 2.5rem 0}}"}],"page":{"pagePath":"api-reference/update-project","slug":"/api-reference/update-project","pageMetadata":{"title":"Update Project","api":"PUT https://api.submagic.co/v1/projects/{id}","description":"Update an existing video project with new settings, features, or media insertions","href":"/api-reference/update-project"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Update an existing video project with new settings, features, or media insertions\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Expandable,Heading,Note,OptimizedImage,ParamField,ResponseField}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Expandable)_missingMdxReference(`Expandable`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`1`,id:`update-project`,children:`Update Project`}),`\n`,_jsx(_components.p,{children:`Update an existing video project with new settings, AI features, or user media (B-roll) insertions. This endpoint allows you to modify project parameters and enhance your video with additional features or custom media content from your library.`}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`This endpoint requires authentication and has a rate limit of 100 requests per\nhour. After modifying a video, you’ll need to re-export to see the changes\nusing the export endpoint. When using `,_jsx(_components.code,{children:`removeBadTakes`}),`, the response may take\n1-2 minutes as our AI processes the video.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`authentication`,children:`Authentication`}),`\n`,_jsx(ParamField,{header:`x-api-key`,type:`string`,required:true,id:`param-x-api-key`,children:_jsxs(_components.p,{children:[`Your Submagic API key starting with `,_jsx(_components.code,{children:`sk-`})]})}),`\n`,_jsx(Heading,{level:`2`,id:`path-parameters`,children:`Path Parameters`}),`\n`,_jsx(ParamField,{path:`id`,type:`string`,required:true,id:`param-id`,children:_jsx(_components.p,{children:`The unique identifier (UUID) of the project to update`})}),`\n`,_jsx(Heading,{level:`2`,id:`request-body`,children:`Request Body`}),`\n`,_jsx(_components.p,{children:`All fields are optional. Only provide the fields you want to update. If a field is provided with a different value from the current project settings, it will be updated.`}),`\n`,_jsxs(ParamField,{body:`words`,type:`array`,id:`param-words`,children:[_jsxs(_components.p,{children:[`Edit the project’s captions. Fetch the current transcript from\n`,_jsx(_components.a,{href:`/api-reference/get-project`,children:`Get Project`}),`, change anything you want (text,\ntiming, add or remove words), and send the `,_jsx(_components.strong,{children:`full`}),` array back — it replaces\nthe transcript, so include every word you want to keep. The caption layout is\nrebuilt automatically.`]}),_jsxs(_components.p,{children:[`Requirements (otherwise `,_jsx(_components.code,{children:`VALIDATION_ERROR`}),`): the project must already be\ntranscribed, and words must stay in chronological order — each `,_jsx(_components.code,{children:`startTime`}),`\ngreater than or equal to the previous word’s.`]}),_jsx(_components.p,{children:`Can be combined with other fields in the same request: the words are applied\nfirst, then the rest. If the words edit fails, nothing else is applied.`}),_jsxs(Expandable,{title:`Word Object`,defaultOpen:true,children:[_jsx(ParamField,{body:`id`,type:`string`,id:`param-id-1`,children:_jsxs(_components.p,{children:[`The word’s id from the Get Project response. Keep it to edit an existing\nword; `,_jsx(_components.strong,{children:`omit it to add a new word.`})]})}),_jsx(ParamField,{body:`text`,type:`string`,required:true,id:`param-text`,children:_jsxs(_components.p,{children:[`The word text. For `,_jsx(_components.code,{children:`silence`}),` segments it is ignored and stored as empty\n(silence never renders caption text).`]})}),_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type`,children:_jsxs(_components.p,{children:[`Segment type. Must be one of `,_jsx(_components.code,{children:`\"word\"`}),`, `,_jsx(_components.code,{children:`\"silence\"`}),`, or `,_jsx(_components.code,{children:`\"punctuation\"`}),` —\nany other value is rejected with `,_jsx(_components.code,{children:`VALIDATION_ERROR`}),`.`]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time`,children:_jsx(_components.p,{children:`Start time in seconds (must be ≥ 0).`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time`,children:_jsxs(_components.p,{children:[`End time in seconds (must be ≥ `,_jsx(_components.code,{children:`startTime`}),`).`]})})]}),_jsxs(_components.p,{children:[`Returns the standard update response (`,_jsx(_components.code,{children:`Project updated successfully`}),`).\nRe-export the project to render the edited captions.`]})]}),`\n`,_jsx(ParamField,{body:`removeSilencePace`,type:`string`,id:`param-remove-silence-pace`,children:_jsxs(_components.p,{children:[`Automatically remove silence from the video at the specified pace. Allowed\nvalues: `,_jsx(_components.code,{children:`natural`}),`, `,_jsx(_components.code,{children:`fast`}),`, `,_jsx(_components.code,{children:`extra-fast`}),`. - `,_jsx(_components.code,{children:`extra-fast`}),`: 0.1-0.2 seconds of\nsilence removal - `,_jsx(_components.code,{children:`fast`}),`: 0.2-0.6 seconds of silence removal - `,_jsx(_components.code,{children:`natural`}),`: 0.6+\nseconds of silence removal`]})}),`\n`,_jsx(ParamField,{body:`removeBadTakes`,type:`boolean`,id:`param-remove-bad-takes`,children:_jsxs(_components.p,{children:[`Automatically detect and remove bad takes and silence from the video using AI\nanalysis. `,_jsx(_components.strong,{children:`Note: This process may take 1-2 minutes to complete.`})]})}),`\n`,_jsx(ParamField,{body:`disableCaptions`,type:`boolean`,id:`param-disable-captions`,children:_jsxs(_components.p,{children:[`Hide captions from the exported video. Optional, defaults to `,_jsx(_components.code,{children:`false`}),`.`]})}),`\n`,_jsx(ParamField,{body:`captionPositionY`,type:`number`,id:`param-caption-position-y`,children:_jsx(_components.p,{children:`Vertical caption position as a percentage from the top of the frame (0-80).\nApplies to all captions, replacing any per-line position adjustments.\nRe-export the project to see the change.`})}),`\n`,_jsx(ParamField,{body:`captionPositionX`,type:`number`,id:`param-caption-position-x`,children:_jsxs(_components.p,{children:[`Horizontal caption position as a percentage (0-100, `,_jsx(_components.code,{children:`50`}),` = centered).\nRe-export the project to see the change.`]})}),`\n`,_jsxs(ParamField,{body:`hookTitle`,type:`boolean | object`,id:`param-hook-title`,children:[_jsxs(_components.p,{children:[`Update the animated hook caption shown at the start of the video. Set to\n`,_jsx(_components.code,{children:`true`}),` to enable the default AI-generated hook, `,_jsx(_components.code,{children:`false`}),` to remove it, or pass\nan object with optional overrides:`]}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`text`}),`: Custom copy (1-100 characters)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`template`}),`: Hook title template name (defaults to `,_jsx(_components.code,{children:`\"tiktok\"`}),`). Fetch valid\nnames using the `,_jsx(_components.a,{href:`/api-reference/hook-title-templates`,children:`hook title templates\nendpoint`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`top`}),`: Vertical position between 0-80 (default `,_jsx(_components.code,{children:`50`}),`)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`size`}),`: Font size between 0-80 (default `,_jsx(_components.code,{children:`30`}),`)`]}),`\n`]}),_jsxs(_components.p,{children:[`Template names are validated before processing resumes; invalid names return\n`,_jsx(_components.code,{children:`VALIDATION_ERROR`}),` immediately.`]})]}),`\n`,_jsxs(ParamField,{body:`music`,type:`object`,id:`param-music`,children:[_jsx(_components.p,{children:`Optional background music track. When provided, replaces any existing\nbackground music on the project.`}),_jsxs(Expandable,{title:`Music Object`,defaultOpen:true,children:[_jsx(ParamField,{body:`userMediaId`,type:`string`,required:true,id:`param-user-media-id`,children:_jsxs(_components.p,{children:[`UUID of the music track. Accepts either an `,_jsx(_components.code,{children:`AUDIO`}),` file from your media\nlibrary (use `,_jsx(_components.a,{href:`/api-reference/list-user-media`,children:`List User Media`}),`) or a Trendy\nMusic track ID (copied from the editor’s `,_jsx(_components.strong,{children:`Edit Audio → Trendy Music`}),` tab).`]})}),_jsx(ParamField,{body:`volume`,type:`number`,required:true,id:`param-volume`,children:_jsx(_components.p,{children:`Playback volume (1-100)`})}),_jsx(ParamField,{body:`startFromTime`,type:`number`,id:`param-start-from-time`,children:_jsxs(_components.p,{children:[`Start offset within the audio file in seconds. Defaults to `,_jsx(_components.code,{children:`0`}),`.`]})}),_jsx(ParamField,{body:`fade`,type:`boolean`,id:`param-fade`,children:_jsxs(_components.p,{children:[`Apply a fade-in/fade-out effect to the music track. Defaults to `,_jsx(_components.code,{children:`true`}),`.`]})})]})]}),`\n`,_jsxs(ParamField,{body:`items`,type:`array`,id:`param-items`,children:[_jsxs(_components.p,{children:[`Array describing B-roll edits. Provide at least one entry when this field is\nincluded. Each item must include a `,_jsx(_components.code,{children:`type`}),` field to specify whether it’s user\nmedia from your library or AI-generated content.`]}),_jsxs(Expandable,{title:`User Media Item`,defaultOpen:true,children:[_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type-1`,children:_jsxs(_components.p,{children:[`Must be set to `,_jsx(_components.code,{children:`\"user-media\"`})]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time-1`,children:_jsx(_components.p,{children:`Start time in seconds where the media should begin (must be ≥ 0)`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time-1`,children:_jsxs(_components.p,{children:[`End time in seconds where the media should end (must be greater than\n`,_jsx(_components.code,{children:`startTime`}),`)`]})}),_jsx(ParamField,{body:`userMediaId`,type:`string`,required:true,id:`param-user-media-id-1`,children:_jsx(_components.p,{children:`UUID of the user media from your library. You can find this ID in the editor’s ‘B-roll’ tab → ‘My videos’ section under each video.`})}),_jsxs(ParamField,{body:`layout`,type:`string`,id:`param-layout`,children:[_jsx(_components.p,{children:`Layout mode for the inserted media. Available values depend on the media type:`}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Video media:`}),` `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50-bordered\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65-bordered\"`}),`, `,_jsx(_components.code,{children:`\"pip-top-right\"`}),`, `,_jsx(_components.code,{children:`\"pip-bottom-right\"`})]}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Image media:`}),` `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`})]})]})]}),_jsxs(Expandable,{title:`AI B-roll Item`,defaultOpen:true,children:[_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type-2`,children:_jsxs(_components.p,{children:[`Must be set to `,_jsx(_components.code,{children:`\"ai-broll\"`})]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time-2`,children:_jsx(_components.p,{children:`Start time in seconds (must be ≥ 0)`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time-2`,children:_jsxs(_components.p,{children:[`End time in seconds. Must be greater than `,_jsx(_components.code,{children:`startTime`}),` and no more than 12\nseconds later.`]})}),_jsx(ParamField,{body:`prompt`,type:`string`,required:true,id:`param-prompt`,children:_jsxs(_components.p,{children:[`1-2500 character description of what the AI should render. This field is\nmandatory whenever `,_jsx(_components.code,{children:`type: \"ai-broll\"`}),` is present.`]})}),_jsx(ParamField,{body:`layout`,type:`string`,id:`param-layout-1`,children:_jsxs(_components.p,{children:[`Layout mode for the AI B-roll. Allowed values: `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50-bordered\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65-bordered\"`}),`, `,_jsx(_components.code,{children:`\"pip-top-right\"`}),`, `,_jsx(_components.code,{children:`\"pip-bottom-right\"`})]})})]}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Important:`}),` Each item must have a `,_jsx(_components.code,{children:`type`}),` field. Items entries cannot overlap\neach other in time.`]})]}),`\n`,_jsx(Heading,{level:`2`,id:`ai-b-roll-workflow-\u0026-credits`,children:`AI B-roll Workflow \u0026 Credits`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Every AI B-roll item consumes `,_jsx(_components.strong,{children:`3 AI credits`}),`. Requests fail with\n`,_jsx(_components.code,{children:`VALIDATION_ERROR`}),` if the authenticated user lacks enough credits (unless their\nbalance is unlimited).`]}),`\n`,_jsxs(_components.li,{children:[`When AI B-roll work is accepted, the project is moved back to `,_jsx(_components.code,{children:`processing`}),` and\nthe generation jobs run asynchronously. Your webhook or polling logic should\nwatch for the project to return to `,_jsx(_components.code,{children:`completed`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Stock/user-media updates continue to succeed immediately with the traditional\n`,_jsx(_components.code,{children:`Project updated successfully`}),` message.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`finding-user-media-id`,children:`Finding User Media ID`}),`\n`,_jsxs(_components.p,{children:[`To find your `,_jsx(_components.code,{children:`userMediaId`}),`:`]}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsx(_components.li,{children:`Go to the Submagic editor`}),`\n`,_jsxs(_components.li,{children:[`Navigate to the `,_jsx(_components.strong,{children:`‘B-roll’`}),` tab`]}),`\n`,_jsx(_components.li,{children:`Add a B-roll to access your media library`}),`\n`,_jsxs(_components.li,{children:[`Go to the `,_jsx(_components.strong,{children:`‘My videos’`}),` tab`]}),`\n`,_jsx(_components.li,{children:`Each video will display its unique media ID that you can use with this API`}),`\n`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=34f0653da7f63c569ba15cf48d679871`,alt:`Example.png`,\"data-og-width\":`2476`,width:`2476`,\"data-og-height\":`1768`,height:`1768`,\"data-path\":`images/Example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=280\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=2e42298e3b84fb51f96774b7cbc58e07 280w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=560\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=99b1ee51e346d090dcad8a63791d1c16 560w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=840\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=130804a10a5786a846af9784857bbddf 840w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=acd94e7c521e851991078e51a7e2d46b 1100w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=5448feb056f71a2a2aff9c38288bcce9 1650w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=0f877c23e64ee3b91625073be582e9eb 2500w`}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(ResponseField,{name:`message`,type:`string`,id:`param-message`,children:_jsxs(_components.p,{children:[`Success message confirming the project update. When AI B-roll work is accepted,\nthe message is `,_jsx(_components.code,{children:`Project update accepted`}),` to indicate asynchronous rendering.`]})}),`\n`,_jsx(ResponseField,{name:`id`,type:`string`,id:`param-id-2`,children:_jsx(_components.p,{children:`The unique identifier of the updated project`})}),`\n`,_jsx(ResponseField,{name:`status`,type:`string`,id:`param-status`,children:_jsxs(_components.p,{children:[`Updated processing status of the project. If AI B-roll generation was\nrequested, the project is moved to `,_jsx(_components.code,{children:`processing`}),` until the renders finish.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`error-responses`,children:`Error Responses`}),`\n`,_jsx(ResponseField,{name:`error`,type:`string`,id:`param-error`,children:_jsxs(_components.p,{children:[`Error code: `,_jsx(_components.code,{children:`NOT_FOUND`}),` or `,_jsx(_components.code,{children:`VALIDATION_ERROR`})]})}),`\n`,_jsx(ResponseField,{name:`message`,type:`string`,id:`param-message-1`,children:_jsx(_components.p,{children:`Detailed error message explaining what went wrong`})}),`\n`,_jsx(ResponseField,{name:`400 Invalid Hook Title Template`,type:`object`,id:`param-400-invalid-hook-title-template`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"VALIDATION_ERROR\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Invalid template name\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),`\n`,`\n`,`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Important:`}),` After updating a project, you must re-export the project to see\nthe changes in the final video. Use the export endpoint to generate the\nupdated video with your modifications. `,_jsx(_components.strong,{children:`Processing Time:`}),` When using\n`,_jsx(_components.code,{children:`removeBadTakes`}),`, the API response may take 1-2 minutes as our AI analyzes and\nprocesses the video to detect and remove bad takes and silence.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Update Project","api":"PUT https://api.submagic.co/v1/projects/{id}","description":"Update an existing video project with new settings, features, or media insertions","href":"/api-reference/update-project"}}},"mdxSourceWithNoJs":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Expandable,Heading,Note,OptimizedImage,ParamField,RequestExample,ResponseExample,ResponseField}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Expandable)_missingMdxReference(`Expandable`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!RequestExample)_missingMdxReference(`RequestExample`,true);if(!ResponseExample)_missingMdxReference(`ResponseExample`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`1`,id:`update-project`,children:`Update Project`}),`\n`,_jsx(_components.p,{children:`Update an existing video project with new settings, AI features, or user media (B-roll) insertions. This endpoint allows you to modify project parameters and enhance your video with additional features or custom media content from your library.`}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`This endpoint requires authentication and has a rate limit of 100 requests per\nhour. After modifying a video, you’ll need to re-export to see the changes\nusing the export endpoint. When using `,_jsx(_components.code,{children:`removeBadTakes`}),`, the response may take\n1-2 minutes as our AI processes the video.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`authentication`,children:`Authentication`}),`\n`,_jsx(ParamField,{header:`x-api-key`,type:`string`,required:true,id:`param-x-api-key`,children:_jsxs(_components.p,{children:[`Your Submagic API key starting with `,_jsx(_components.code,{children:`sk-`})]})}),`\n`,_jsx(Heading,{level:`2`,id:`path-parameters`,children:`Path Parameters`}),`\n`,_jsx(ParamField,{path:`id`,type:`string`,required:true,id:`param-id`,children:_jsx(_components.p,{children:`The unique identifier (UUID) of the project to update`})}),`\n`,_jsx(Heading,{level:`2`,id:`request-body`,children:`Request Body`}),`\n`,_jsx(_components.p,{children:`All fields are optional. Only provide the fields you want to update. If a field is provided with a different value from the current project settings, it will be updated.`}),`\n`,_jsxs(ParamField,{body:`words`,type:`array`,id:`param-words`,children:[_jsxs(_components.p,{children:[`Edit the project’s captions. Fetch the current transcript from\n`,_jsx(_components.a,{href:`/api-reference/get-project`,children:`Get Project`}),`, change anything you want (text,\ntiming, add or remove words), and send the `,_jsx(_components.strong,{children:`full`}),` array back — it replaces\nthe transcript, so include every word you want to keep. The caption layout is\nrebuilt automatically.`]}),_jsxs(_components.p,{children:[`Requirements (otherwise `,_jsx(_components.code,{children:`VALIDATION_ERROR`}),`): the project must already be\ntranscribed, and words must stay in chronological order — each `,_jsx(_components.code,{children:`startTime`}),`\ngreater than or equal to the previous word’s.`]}),_jsx(_components.p,{children:`Can be combined with other fields in the same request: the words are applied\nfirst, then the rest. If the words edit fails, nothing else is applied.`}),_jsxs(Expandable,{title:`Word Object`,defaultOpen:true,children:[_jsx(ParamField,{body:`id`,type:`string`,id:`param-id-1`,children:_jsxs(_components.p,{children:[`The word’s id from the Get Project response. Keep it to edit an existing\nword; `,_jsx(_components.strong,{children:`omit it to add a new word.`})]})}),_jsx(ParamField,{body:`text`,type:`string`,required:true,id:`param-text`,children:_jsxs(_components.p,{children:[`The word text. For `,_jsx(_components.code,{children:`silence`}),` segments it is ignored and stored as empty\n(silence never renders caption text).`]})}),_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type`,children:_jsxs(_components.p,{children:[`Segment type. Must be one of `,_jsx(_components.code,{children:`\"word\"`}),`, `,_jsx(_components.code,{children:`\"silence\"`}),`, or `,_jsx(_components.code,{children:`\"punctuation\"`}),` —\nany other value is rejected with `,_jsx(_components.code,{children:`VALIDATION_ERROR`}),`.`]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time`,children:_jsx(_components.p,{children:`Start time in seconds (must be ≥ 0).`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time`,children:_jsxs(_components.p,{children:[`End time in seconds (must be ≥ `,_jsx(_components.code,{children:`startTime`}),`).`]})})]}),_jsxs(_components.p,{children:[`Returns the standard update response (`,_jsx(_components.code,{children:`Project updated successfully`}),`).\nRe-export the project to render the edited captions.`]})]}),`\n`,_jsx(ParamField,{body:`removeSilencePace`,type:`string`,id:`param-remove-silence-pace`,children:_jsxs(_components.p,{children:[`Automatically remove silence from the video at the specified pace. Allowed\nvalues: `,_jsx(_components.code,{children:`natural`}),`, `,_jsx(_components.code,{children:`fast`}),`, `,_jsx(_components.code,{children:`extra-fast`}),`. - `,_jsx(_components.code,{children:`extra-fast`}),`: 0.1-0.2 seconds of\nsilence removal - `,_jsx(_components.code,{children:`fast`}),`: 0.2-0.6 seconds of silence removal - `,_jsx(_components.code,{children:`natural`}),`: 0.6+\nseconds of silence removal`]})}),`\n`,_jsx(ParamField,{body:`removeBadTakes`,type:`boolean`,id:`param-remove-bad-takes`,children:_jsxs(_components.p,{children:[`Automatically detect and remove bad takes and silence from the video using AI\nanalysis. `,_jsx(_components.strong,{children:`Note: This process may take 1-2 minutes to complete.`})]})}),`\n`,_jsx(ParamField,{body:`disableCaptions`,type:`boolean`,id:`param-disable-captions`,children:_jsxs(_components.p,{children:[`Hide captions from the exported video. Optional, defaults to `,_jsx(_components.code,{children:`false`}),`.`]})}),`\n`,_jsx(ParamField,{body:`captionPositionY`,type:`number`,id:`param-caption-position-y`,children:_jsx(_components.p,{children:`Vertical caption position as a percentage from the top of the frame (0-80).\nApplies to all captions, replacing any per-line position adjustments.\nRe-export the project to see the change.`})}),`\n`,_jsx(ParamField,{body:`captionPositionX`,type:`number`,id:`param-caption-position-x`,children:_jsxs(_components.p,{children:[`Horizontal caption position as a percentage (0-100, `,_jsx(_components.code,{children:`50`}),` = centered).\nRe-export the project to see the change.`]})}),`\n`,_jsxs(ParamField,{body:`hookTitle`,type:`boolean | object`,id:`param-hook-title`,children:[_jsxs(_components.p,{children:[`Update the animated hook caption shown at the start of the video. Set to\n`,_jsx(_components.code,{children:`true`}),` to enable the default AI-generated hook, `,_jsx(_components.code,{children:`false`}),` to remove it, or pass\nan object with optional overrides:`]}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`text`}),`: Custom copy (1-100 characters)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`template`}),`: Hook title template name (defaults to `,_jsx(_components.code,{children:`\"tiktok\"`}),`). Fetch valid\nnames using the `,_jsx(_components.a,{href:`/api-reference/hook-title-templates`,children:`hook title templates\nendpoint`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`top`}),`: Vertical position between 0-80 (default `,_jsx(_components.code,{children:`50`}),`)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`size`}),`: Font size between 0-80 (default `,_jsx(_components.code,{children:`30`}),`)`]}),`\n`]}),_jsxs(_components.p,{children:[`Template names are validated before processing resumes; invalid names return\n`,_jsx(_components.code,{children:`VALIDATION_ERROR`}),` immediately.`]})]}),`\n`,_jsxs(ParamField,{body:`music`,type:`object`,id:`param-music`,children:[_jsx(_components.p,{children:`Optional background music track. When provided, replaces any existing\nbackground music on the project.`}),_jsxs(Expandable,{title:`Music Object`,defaultOpen:true,children:[_jsx(ParamField,{body:`userMediaId`,type:`string`,required:true,id:`param-user-media-id`,children:_jsxs(_components.p,{children:[`UUID of the music track. Accepts either an `,_jsx(_components.code,{children:`AUDIO`}),` file from your media\nlibrary (use `,_jsx(_components.a,{href:`/api-reference/list-user-media`,children:`List User Media`}),`) or a Trendy\nMusic track ID (copied from the editor’s `,_jsx(_components.strong,{children:`Edit Audio → Trendy Music`}),` tab).`]})}),_jsx(ParamField,{body:`volume`,type:`number`,required:true,id:`param-volume`,children:_jsx(_components.p,{children:`Playback volume (1-100)`})}),_jsx(ParamField,{body:`startFromTime`,type:`number`,id:`param-start-from-time`,children:_jsxs(_components.p,{children:[`Start offset within the audio file in seconds. Defaults to `,_jsx(_components.code,{children:`0`}),`.`]})}),_jsx(ParamField,{body:`fade`,type:`boolean`,id:`param-fade`,children:_jsxs(_components.p,{children:[`Apply a fade-in/fade-out effect to the music track. Defaults to `,_jsx(_components.code,{children:`true`}),`.`]})})]})]}),`\n`,_jsxs(ParamField,{body:`items`,type:`array`,id:`param-items`,children:[_jsxs(_components.p,{children:[`Array describing B-roll edits. Provide at least one entry when this field is\nincluded. Each item must include a `,_jsx(_components.code,{children:`type`}),` field to specify whether it’s user\nmedia from your library or AI-generated content.`]}),_jsxs(Expandable,{title:`User Media Item`,defaultOpen:true,children:[_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type-1`,children:_jsxs(_components.p,{children:[`Must be set to `,_jsx(_components.code,{children:`\"user-media\"`})]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time-1`,children:_jsx(_components.p,{children:`Start time in seconds where the media should begin (must be ≥ 0)`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time-1`,children:_jsxs(_components.p,{children:[`End time in seconds where the media should end (must be greater than\n`,_jsx(_components.code,{children:`startTime`}),`)`]})}),_jsx(ParamField,{body:`userMediaId`,type:`string`,required:true,id:`param-user-media-id-1`,children:_jsx(_components.p,{children:`UUID of the user media from your library. You can find this ID in the editor’s ‘B-roll’ tab → ‘My videos’ section under each video.`})}),_jsxs(ParamField,{body:`layout`,type:`string`,id:`param-layout`,children:[_jsx(_components.p,{children:`Layout mode for the inserted media. Available values depend on the media type:`}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Video media:`}),` `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50-bordered\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65-bordered\"`}),`, `,_jsx(_components.code,{children:`\"pip-top-right\"`}),`, `,_jsx(_components.code,{children:`\"pip-bottom-right\"`})]}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Image media:`}),` `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`})]})]})]}),_jsxs(Expandable,{title:`AI B-roll Item`,defaultOpen:true,children:[_jsx(ParamField,{body:`type`,type:`string`,required:true,id:`param-type-2`,children:_jsxs(_components.p,{children:[`Must be set to `,_jsx(_components.code,{children:`\"ai-broll\"`})]})}),_jsx(ParamField,{body:`startTime`,type:`number`,required:true,id:`param-start-time-2`,children:_jsx(_components.p,{children:`Start time in seconds (must be ≥ 0)`})}),_jsx(ParamField,{body:`endTime`,type:`number`,required:true,id:`param-end-time-2`,children:_jsxs(_components.p,{children:[`End time in seconds. Must be greater than `,_jsx(_components.code,{children:`startTime`}),` and no more than 12\nseconds later.`]})}),_jsx(ParamField,{body:`prompt`,type:`string`,required:true,id:`param-prompt`,children:_jsxs(_components.p,{children:[`1-2500 character description of what the AI should render. This field is\nmandatory whenever `,_jsx(_components.code,{children:`type: \"ai-broll\"`}),` is present.`]})}),_jsx(ParamField,{body:`layout`,type:`string`,id:`param-layout-1`,children:_jsxs(_components.p,{children:[`Layout mode for the AI B-roll. Allowed values: `,_jsx(_components.code,{children:`\"cover\"`}),`, `,_jsx(_components.code,{children:`\"contain\"`}),`, `,_jsx(_components.code,{children:`\"rounded\"`}),`, `,_jsx(_components.code,{children:`\"square\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65\"`}),`, `,_jsx(_components.code,{children:`\"split-50-50-bordered\"`}),`, `,_jsx(_components.code,{children:`\"split-35-65-bordered\"`}),`, `,_jsx(_components.code,{children:`\"pip-top-right\"`}),`, `,_jsx(_components.code,{children:`\"pip-bottom-right\"`})]})})]}),_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Important:`}),` Each item must have a `,_jsx(_components.code,{children:`type`}),` field. Items entries cannot overlap\neach other in time.`]})]}),`\n`,_jsx(Heading,{level:`2`,id:`ai-b-roll-workflow-\u0026-credits`,children:`AI B-roll Workflow \u0026 Credits`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Every AI B-roll item consumes `,_jsx(_components.strong,{children:`3 AI credits`}),`. Requests fail with\n`,_jsx(_components.code,{children:`VALIDATION_ERROR`}),` if the authenticated user lacks enough credits (unless their\nbalance is unlimited).`]}),`\n`,_jsxs(_components.li,{children:[`When AI B-roll work is accepted, the project is moved back to `,_jsx(_components.code,{children:`processing`}),` and\nthe generation jobs run asynchronously. Your webhook or polling logic should\nwatch for the project to return to `,_jsx(_components.code,{children:`completed`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Stock/user-media updates continue to succeed immediately with the traditional\n`,_jsx(_components.code,{children:`Project updated successfully`}),` message.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`finding-user-media-id`,children:`Finding User Media ID`}),`\n`,_jsxs(_components.p,{children:[`To find your `,_jsx(_components.code,{children:`userMediaId`}),`:`]}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsx(_components.li,{children:`Go to the Submagic editor`}),`\n`,_jsxs(_components.li,{children:[`Navigate to the `,_jsx(_components.strong,{children:`‘B-roll’`}),` tab`]}),`\n`,_jsx(_components.li,{children:`Add a B-roll to access your media library`}),`\n`,_jsxs(_components.li,{children:[`Go to the `,_jsx(_components.strong,{children:`‘My videos’`}),` tab`]}),`\n`,_jsx(_components.li,{children:`Each video will display its unique media ID that you can use with this API`}),`\n`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=34f0653da7f63c569ba15cf48d679871`,alt:`Example.png`,\"data-og-width\":`2476`,width:`2476`,\"data-og-height\":`1768`,height:`1768`,\"data-path\":`images/Example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=280\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=2e42298e3b84fb51f96774b7cbc58e07 280w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=560\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=99b1ee51e346d090dcad8a63791d1c16 560w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=840\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=130804a10a5786a846af9784857bbddf 840w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=acd94e7c521e851991078e51a7e2d46b 1100w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=5448feb056f71a2a2aff9c38288bcce9 1650w, https://mintcdn.com/submagic/eEPiypbnZT0UxgbH/images/Example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=eEPiypbnZT0UxgbH\u0026q=85\u0026s=0f877c23e64ee3b91625073be582e9eb 2500w`}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(ResponseField,{name:`message`,type:`string`,id:`param-message`,children:_jsxs(_components.p,{children:[`Success message confirming the project update. When AI B-roll work is accepted,\nthe message is `,_jsx(_components.code,{children:`Project update accepted`}),` to indicate asynchronous rendering.`]})}),`\n`,_jsx(ResponseField,{name:`id`,type:`string`,id:`param-id-2`,children:_jsx(_components.p,{children:`The unique identifier of the updated project`})}),`\n`,_jsx(ResponseField,{name:`status`,type:`string`,id:`param-status`,children:_jsxs(_components.p,{children:[`Updated processing status of the project. If AI B-roll generation was\nrequested, the project is moved to `,_jsx(_components.code,{children:`processing`}),` until the renders finish.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`error-responses`,children:`Error Responses`}),`\n`,_jsx(ResponseField,{name:`error`,type:`string`,id:`param-error`,children:_jsxs(_components.p,{children:[`Error code: `,_jsx(_components.code,{children:`NOT_FOUND`}),` or `,_jsx(_components.code,{children:`VALIDATION_ERROR`})]})}),`\n`,_jsx(ResponseField,{name:`message`,type:`string`,id:`param-message-1`,children:_jsx(_components.p,{children:`Detailed error message explaining what went wrong`})}),`\n`,_jsx(ResponseField,{name:`400 Invalid Hook Title Template`,type:`object`,id:`param-400-invalid-hook-title-template`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"VALIDATION_ERROR\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Invalid template name\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),`\n`,_jsxs(RequestExample,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`35`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`35`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` PUT`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"https://api.submagic.co/v1/projects/550e8400-e29b-41d4-a716-446655440000\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"x-api-key: sk-your-api-key-here\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"removeSilencePace\": \"fast\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"removeBadTakes\": true,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"hookTitle\": {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"text\": \"New intro in 15 seconds\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"template\": \"laura\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"top\": 40,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"size\": 28`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"music\": {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"userMediaId\": \"88a08eec-712a-45d0-8d0b-3b631700cb3a\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"volume\": 25,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"startFromTime\": 10,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"fade\": true`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"items\": [`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"type\": \"user-media\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"startTime\": 10.5,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"endTime\": 15.2,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"userMediaId\": \"123e4567-e89b-12d3-a456-426614174000\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"layout\": \"pip-top-right\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"type\": \"ai-broll\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"startTime\": 25,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"endTime\": 31,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"prompt\": \"smooth slider shot of a team collaborating in a modern studio\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"layout\": \"split-50-50\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`JavaScript`,numberOfLines:`57`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`57`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` updateProject`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` async`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`projectId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`updateData`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` response`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` fetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `https://api.submagic.co/v1/projects/\"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`projectId`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` method:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"PUT\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` headers:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"x-api-key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"sk-your-api-key-here\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` body:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` JSON`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`stringify`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`updateData`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` );`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` result`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` response`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`json`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` console`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`log`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project updated:\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`result`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`message`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` result`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Usage`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` updateData`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` removeSilencePace:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"fast\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` removeBadTakes:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` hookTitle:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` text:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"New intro in 15 seconds\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` template:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"laura\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` top:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 40`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` size:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 28`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` music:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` userMediaId:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"88a08eec-712a-45d0-8d0b-3b631700cb3a\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` volume:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 25`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` startFromTime:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 10`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` fade:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` items:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"user-media\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` startTime:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 10.5`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` endTime:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 15.2`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` userMediaId:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"123e4567-e89b-12d3-a456-426614174000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` layout:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"pip-top-right\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"ai-broll\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` startTime:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 25`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` endTime:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 31`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` prompt:`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"smooth slider shot of a team collaborating in a modern studio\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` layout:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"split-50-50\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ],`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`};`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` result`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` updateProject`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"550e8400-e29b-41d4-a716-446655440000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` updateData`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`Python`,numberOfLines:`51`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`51`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` json`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`def`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` update_project`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`project_id`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`update_data`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`):`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` url `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` f`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'https://api.submagic.co/v1/projects/`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`{`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`project_id`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` headers `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'x-api-key'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'sk-your-api-key-here'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'Content-Type'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'application/json'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` response `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests.put(url, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`headers`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`headers, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`json`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`update_data)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` result `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` response.json()`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` print`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`f`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project updated: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`{`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`result.get(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'message'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` result`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Usage`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`update_data `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'removeSilencePace'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'fast'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'removeBadTakes'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`True`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'hookTitle'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'text'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'New intro in 15 seconds'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'template'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'laura'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'top'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`40`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'size'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`28`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'music'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'userMediaId'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'88a08eec-712a-45d0-8d0b-3b631700cb3a'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'volume'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`25`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'startFromTime'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`10`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'fade'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`True`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'items'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'type'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'user-media'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'startTime'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`10.5`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'endTime'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`15.2`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'userMediaId'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'123e4567-e89b-12d3-a456-426614174000'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'layout'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'pip-top-right'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'type'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'ai-broll'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'startTime'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`25`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'endTime'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`31`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'prompt'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'smooth slider shot of a team collaborating in a modern studio'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'layout'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'split-50-50'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`result `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` update_project(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'550e8400-e29b-41d4-a716-446655440000'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, update_data)`})]}),`\n`]})})})]}),`\n`,_jsxs(ResponseExample,{children:[_jsx(CodeBlock,{filename:`200 OK - Stock/User Media Only`,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project updated successfully\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"550e8400-e29b-41d4-a716-446655440000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"processing\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`200 OK - AI B-roll Accepted`,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project update accepted\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"550e8400-e29b-41d4-a716-446655440000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"processing\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`200 OK - Words Updated`,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project updated successfully\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"550e8400-e29b-41d4-a716-446655440000\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`400 VALIDATION_ERROR - Not Transcribed Yet`,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"VALIDATION_ERROR\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project is not transcribed yet; words can only be edited after transcription completes.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`404 NOT_FOUND`,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"NOT_FOUND\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Project not found\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`400 VALIDATION_ERROR - Invalid Time Range`,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"VALIDATION_ERROR\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"endTime must be greater than startTime\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`400 VALIDATION_ERROR - Invalid UUID`,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"VALIDATION_ERROR\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"message\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Invalid UUID format for userMediaId\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Important:`}),` After updating a project, you must re-export the project to see\nthe changes in the final video. Use the export endpoint to generate the\nupdated video with your modifications. `,_jsx(_components.strong,{children:`Processing Time:`}),` When using\n`,_jsx(_components.code,{children:`removeBadTakes`}),`, the API response may take 1-2 minutes as our AI analyzes and\nprocesses the video to detect and remove bad takes and silence.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Update Project","api":"PUT https://api.submagic.co/v1/projects/{id}","description":"Update an existing video project with new settings, features, or media insertions","href":"/api-reference/update-project"}}}},"mdxExtracts":{"tableOfContents":[{"title":"Update Project","slug":"update-project","depth":1,"children":[]},{"title":"Authentication","slug":"authentication","depth":2,"children":[]},{"title":"Path Parameters","slug":"path-parameters","depth":2,"children":[]},{"title":"Request Body","slug":"request-body","depth":2,"children":[]},{"title":"AI B-roll Workflow \u0026 Credits","slug":"ai-b-roll-workflow-\u0026-credits","depth":2,"children":[]},{"title":"Finding User Media ID","slug":"finding-user-media-id","depth":2,"children":[]},{"title":"Response","slug":"response","depth":2,"children":[]},{"title":"Error Responses","slug":"error-responses","depth":2,"children":[]}],"codeExamples":{"request":{"type":"RequestExample","children":[{"filename":"cURL","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"shellscript\">\u003ccode language=\"shellscript\" numberOfLines=\"35\">\u003cspan class=\"line\">\u003cspan style=\"color:#953800;--shiki-dark:#DCDCAA\">curl\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -X\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> PUT\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"https://api.submagic.co/v1/projects/550e8400-e29b-41d4-a716-446655440000\"\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -H\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"x-api-key: sk-your-api-key-here\"\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -H\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Content-Type: application/json\"\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -d\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> '{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"removeSilencePace\": \"fast\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"removeBadTakes\": true,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"hookTitle\": {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"text\": \"New intro in 15 seconds\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"template\": \"laura\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"top\": 40,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"size\": 28\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"music\": {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"userMediaId\": \"88a08eec-712a-45d0-8d0b-3b631700cb3a\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"volume\": 25,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"startFromTime\": 10,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"fade\": true\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"items\": [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"type\": \"user-media\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"startTime\": 10.5,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"endTime\": 15.2,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"userMediaId\": \"123e4567-e89b-12d3-a456-426614174000\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"layout\": \"pip-top-right\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"type\": \"ai-broll\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"startTime\": 25,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"endTime\": 31,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"prompt\": \"smooth slider shot of a team collaborating in a modern studio\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"layout\": \"split-50-50\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> ]\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> }'\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"JavaScript","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"javascript\">\u003ccode language=\"javascript\" numberOfLines=\"57\">\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> updateProject\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> async\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> (\u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">projectId\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">updateData\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">) \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">=>\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> response\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> fetch\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> `https://api.submagic.co/v1/projects/\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#569CD6\">${\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">projectId\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#569CD6\">}\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">`\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> method:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"PUT\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> headers:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"x-api-key\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"sk-your-api-key-here\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Content-Type\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"application/json\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> body:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> JSON\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">stringify\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">updateData\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">),\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> );\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> result\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> response\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">json\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">();\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> console\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">log\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project updated:\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">result\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">message\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">);\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> return\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> result\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">;\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">};\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#6E7781;--shiki-dark:#6A9955\">// Usage\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> updateData\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> removeSilencePace:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"fast\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> removeBadTakes:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> true\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> hookTitle:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> text:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"New intro in 15 seconds\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> template:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"laura\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> top:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 40\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> size:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 28\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> music:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> userMediaId:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"88a08eec-712a-45d0-8d0b-3b631700cb3a\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> volume:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 25\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> startFromTime:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 10\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> fade:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> true\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> items:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> type:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"user-media\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> startTime:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 10.5\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> endTime:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 15.2\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> userMediaId:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"123e4567-e89b-12d3-a456-426614174000\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> layout:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"pip-top-right\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> type:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"ai-broll\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> startTime:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 25\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> endTime:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\"> 31\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> prompt:\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"smooth slider shot of a team collaborating in a modern studio\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> layout:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"split-50-50\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> ],\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">};\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> result\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> updateProject\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"550e8400-e29b-41d4-a716-446655440000\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> updateData\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">);\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"Python","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"python\">\u003ccode language=\"python\" numberOfLines=\"51\">\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">import\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> json\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">import\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> requests\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">def\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> update_project\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">project_id\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">update_data\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">):\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> url \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> f\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'https://api.submagic.co/v1/projects/\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">{\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">project_id\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">}\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> headers \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'x-api-key'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'sk-your-api-key-here'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'Content-Type'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'application/json'\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> response \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> requests.put(url, \u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">headers\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">headers, \u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">json\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">update_data)\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> result \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> response.json()\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#DCDCAA\"> print\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">f\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project updated: \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">{\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">result.get(\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'message'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">)\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">}\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">)\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> return\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> result\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#6E7781;--shiki-dark:#6A9955\"># Usage\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">update_data \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'removeSilencePace'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'fast'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'removeBadTakes'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\">True\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'hookTitle'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'text'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'New intro in 15 seconds'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'template'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'laura'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'top'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">40\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'size'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">28\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'music'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'userMediaId'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'88a08eec-712a-45d0-8d0b-3b631700cb3a'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'volume'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">25\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'startFromTime'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">10\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'fade'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\">True\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'items'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'type'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'user-media'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'startTime'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">10.5\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'endTime'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">15.2\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'userMediaId'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'123e4567-e89b-12d3-a456-426614174000'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'layout'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'pip-top-right'\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'type'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'ai-broll'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'startTime'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">25\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'endTime'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">31\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'prompt'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'smooth slider shot of a team collaborating in a modern studio'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'layout'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'split-50-50'\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> ]\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">result \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> update_project(\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'550e8400-e29b-41d4-a716-446655440000'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, update_data)\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]},"response":{"type":"ResponseExample","children":[{"filename":"200 OK - Stock/User Media Only","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"5\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project updated successfully\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"550e8400-e29b-41d4-a716-446655440000\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"status\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"processing\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"200 OK - AI B-roll Accepted","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"5\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project update accepted\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"550e8400-e29b-41d4-a716-446655440000\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"status\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"processing\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"200 OK - Words Updated","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"5\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project updated successfully\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"550e8400-e29b-41d4-a716-446655440000\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"status\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"completed\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"400 VALIDATION_ERROR - Not Transcribed Yet","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"4\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"VALIDATION_ERROR\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project is not transcribed yet; words can only be edited after transcription completes.\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"404 NOT_FOUND","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"4\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"NOT_FOUND\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Project not found\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"400 VALIDATION_ERROR - Invalid Time Range","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"4\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"VALIDATION_ERROR\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"endTime must be greater than startTime\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"400 VALIDATION_ERROR - Invalid UUID","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"4\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"VALIDATION_ERROR\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"message\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Invalid UUID format for userMediaId\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]}},"endpoint":{"title":"Update Project","path":"/v1/projects/{id}","servers":[{"url":"https://api.submagic.co"}],"method":"put","request":{"security":[],"parameters":{"query":{},"header":{"x-api-key":{"schema":[{"type":"string","description":"Your Submagic API key starting with `sk-`","required":true}]}},"cookie":{},"path":{"id":{"schema":[{"type":"string","description":"The unique identifier (UUID) of the project to update","required":true}]}}},"body":{"application/json":{"schemaArray":[{"type":"object","properties":{"words":[{"type":"array","items":[{"type":"object","properties":{"id":[{"type":"string","description":"The word’s id from the Get Project response. Keep it to edit an existing word; omit it to add a new word."}],"text":[{"type":"string","description":"The word text. For `silence` segments it is ignored and stored as empty (silence never renders caption text).","required":true}],"type":[{"type":"string","description":"Segment type. Must be one of `\"word\"` , `\"silence\"` , or `\"punctuation\"` — any other value is rejected with `VALIDATION_ERROR` .","required":true}],"startTime":[{"type":"number","description":"Start time in seconds (must be ≥ 0).","required":true}],"endTime":[{"type":"number","description":"End time in seconds (must be ≥ `startTime` ).","required":true}]}}],"description":"Edit the project’s captions. Fetch the current transcript from Get Project , change anything you want (text, timing, add or remove words), and send the full array back — it replaces the transcript, so include every word you want to keep. The caption layout is rebuilt automatically. Requirements (otherwise `VALIDATION_ERROR` ): the project must already be transcribed, and words must stay in chronological order — each `startTime` greater than or equal to the previous word’s. Can be combined with other fields in the same request: the words are applied first, then the rest. If the words edit fails, nothing else is applied. Returns the standard update response ( `Project updated successfully` ). Re-export the project to render the edited captions."}],"removeSilencePace":[{"type":"string","description":"Automatically remove silence from the video at the specified pace. Allowed values: `natural` , `fast` , `extra-fast` . - `extra-fast` : 0.1-0.2 seconds of silence removal - `fast` : 0.2-0.6 seconds of silence removal - `natural` : 0.6+ seconds of silence removal"}],"removeBadTakes":[{"type":"boolean","description":"Automatically detect and remove bad takes and silence from the video using AI analysis. Note: This process may take 1-2 minutes to complete."}],"disableCaptions":[{"type":"boolean","description":"Hide captions from the exported video. Optional, defaults to `false` ."}],"captionPositionY":[{"type":"number","description":"Vertical caption position as a percentage from the top of the frame (0-80). Applies to all captions, replacing any per-line position adjustments. Re-export the project to see the change."}],"captionPositionX":[{"type":"number","description":"Horizontal caption position as a percentage (0-100, `50` = centered). Re-export the project to see the change."}],"hookTitle":[{"type":"object","properties":{},"description":"Update the animated hook caption shown at the start of the video. Set to `true` to enable the default AI-generated hook, `false` to remove it, or pass an object with optional overrides: `text` : Custom copy (1-100 characters) `template` : Hook title template name (defaults to `\"tiktok\"` ). Fetch valid names using the hook title templates endpoint . `top` : Vertical position between 0-80 (default `50` ) `size` : Font size between 0-80 (default `30` ) Template names are validated before processing resumes; invalid names return `VALIDATION_ERROR` immediately."}],"music":[{"type":"object","properties":{"userMediaId":[{"type":"string","description":"UUID of the music track. Accepts either an `AUDIO` file from your media library (use List User Media ) or a Trendy Music track ID (copied from the editor’s Edit Audio → Trendy Music tab).","required":true}],"volume":[{"type":"number","description":"Playback volume (1-100)","required":true}],"startFromTime":[{"type":"number","description":"Start offset within the audio file in seconds. Defaults to `0` ."}],"fade":[{"type":"boolean","description":"Apply a fade-in/fade-out effect to the music track. Defaults to `true` ."}]},"description":"Optional background music track. When provided, replaces any existing background music on the project."}],"items":[{"type":"array","items":[{"type":"object","properties":{"type":[{"type":"string","description":"Must be set to `\"ai-broll\"`","required":true}],"startTime":[{"type":"number","description":"Start time in seconds (must be ≥ 0)","required":true}],"endTime":[{"type":"number","description":"End time in seconds. Must be greater than `startTime` and no more than 12 seconds later.","required":true}],"userMediaId":[{"type":"string","description":"UUID of the user media from your library. You can find this ID in the editor’s ‘B-roll’ tab → ‘My videos’ section under each video.","required":true}],"layout":[{"type":"string","description":"Layout mode for the AI B-roll. Allowed values: `\"cover\"` , `\"contain\"` , `\"rounded\"` , `\"square\"` , `\"split-50-50\"` , `\"split-35-65\"` , `\"split-50-50-bordered\"` , `\"split-35-65-bordered\"` , `\"pip-top-right\"` , `\"pip-bottom-right\"`"}],"prompt":[{"type":"string","description":"1-2500 character description of what the AI should render. This field is mandatory whenever `type: \"ai-broll\"` is present.","required":true}]}}],"description":"Array describing B-roll edits. Provide at least one entry when this field is included. Each item must include a `type` field to specify whether it’s user media from your library or AI-generated content. Important: Each item must have a `type` field. Items entries cannot overlap each other in time."}]}}],"examples":{"example":{"value":{"words":[{"id":"\u003cstring>","text":"\u003cstring>","type":"\u003cstring>","startTime":123,"endTime":123}],"removeSilencePace":"\u003cstring>","removeBadTakes":true,"disableCaptions":true,"captionPositionY":123,"captionPositionX":123,"hookTitle":{},"music":{"userMediaId":"\u003cstring>","volume":123,"startFromTime":123,"fade":true},"items":[{"type":"\u003cstring>","startTime":123,"endTime":123,"userMediaId":"\u003cstring>","layout":"\u003cstring>","prompt":"\u003cstring>"}]}}}}}},"response":{"200":{"application/json":{"schemaArray":[{"type":"object","properties":{"message":[{"type":"string","description":"Detailed error message explaining what went wrong"}],"id":[{"type":"string","description":"The unique identifier of the updated project"}],"status":[{"type":"string","description":"Updated processing status of the project. If AI B-roll generation was requested, the project is moved to `processing` until the renders finish."}],"error":[{"type":"string","description":"Error code: `NOT_FOUND` or `VALIDATION_ERROR`"}],"400 Invalid Hook Title Template":[{"type":"object","properties":{}}]}}],"examples":{"example":{"value":{"message":"\u003cstring>","id":"\u003cstring>","status":"\u003cstring>","error":"\u003cstring>","400 Invalid Hook Title Template":{}}}}}}},"deprecated":false}},"jsLinks":[],"subdomain":"submagic","siteName":"Submagic API","title":"Update Project - Submagic API","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-07-30T11:20:08.472Z","originalFileLocation":"api-reference/update-project.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Update an existing video project with new settings, features, or media insertions\">\u003cmeta data-mint-head name=\"application-name\" content=\"Submagic API\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Update Project - Submagic API\">\u003cmeta data-mint-head property=\"og:description\" content=\"Update an existing video project with new settings, features, or media insertions\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Submagic API\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.submagic.co/api-reference/update-project\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://submagic.mintlify.site/_mintlify/api/og/v2?division=API+Reference\u0026amp;title=Update+Project\u0026amp;description=Update+an+existing+video+project+with+new+settings%2C+features%2C+or+media+insertions\u0026amp;theme=1caa66327510ff05960edc58\u0026amp;signature=eaafa6c8c5e3e39c477b3c33d48fcfbcd312d5e57cd2a727616de86c562779ff\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Update Project - Submagic API\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Update an existing video project with new settings, features, or media insertions\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://submagic.mintlify.site/_mintlify/api/og/v2?division=API+Reference\u0026amp;title=Update+Project\u0026amp;description=Update+an+existing+video+project+with+new+settings%2C+features%2C+or+media+insertions\u0026amp;theme=1caa66327510ff05960edc58\u0026amp;signature=eaafa6c8c5e3e39c477b3c33d48fcfbcd312d5e57cd2a727616de86c562779ff\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/submagic/XZQ1b_hVxi81aVoB/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Submagic API\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#ff6b35\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.submagic.co/api-reference/update-project\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/update-project.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.submagic.co/#organization\",\"name\":\"Submagic API\",\"url\":\"https://docs.submagic.co\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/submagic/Gyf5dEe3UuhgkFDU/logo-dark.png?fit=max\u0026auto=format\u0026n=Gyf5dEe3UuhgkFDU\u0026q=85\u0026s=1ee650d8a4e56baa2c938294da5e446d\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.submagic.co#website\",\"name\":\"Submagic API\",\"url\":\"https://docs.submagic.co\",\"publisher\":{\"@id\":\"https://docs.submagic.co/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.submagic.co/api-reference/update-project#webpage\",\"url\":\"https://docs.submagic.co/api-reference/update-project\",\"name\":\"Update Project\",\"description\":\"Update an existing video project with new settings, features, or media insertions\",\"dateModified\":\"2026-07-30T11:20:08.472Z\",\"isPartOf\":{\"@id\":\"https://docs.submagic.co#website\"},\"breadcrumb\":{\"@id\":\"https://docs.submagic.co/api-reference/update-project#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.submagic.co/api-reference/update-project#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API Reference\",\"item\":\"https://docs.submagic.co/api-reference/health\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Update Project\",\"item\":\"https://docs.submagic.co/api-reference/update-project\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.submagic.co/api-reference/update-project#apireference\",\"headline\":\"Update Project\",\"name\":\"Update Project\",\"description\":\"Update an existing video project with new settings, features, or media insertions\",\"url\":\"https://docs.submagic.co/api-reference/update-project\",\"mainEntityOfPage\":{\"@id\":\"https://docs.submagic.co/api-reference/update-project#webpage\"},\"dateModified\":\"2026-07-30T11:20:08.472Z\",\"publisher\":{\"@id\":\"https://docs.submagic.co/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.submagic.co#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Submagic API\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Submagic API","nav":{"global":{"anchors":[{"anchor":"llms.txt","icon":"file-text","href":"https://docs.submagic.co/llms-full.txt"}]},"groups":[{"group":"Get Started","icon":"play","pages":[{"title":"Introduction","href":"/introduction"},{"title":"Authentication","href":"/authentication"},{"title":"Rate Limits","href":"/rate-limits"},{"title":"MCP Server","href":"/mcp-server"}]},{"group":"Guides","icon":"book-open","pages":[{"title":"Edit the Transcript Before Rendering","href":"/guides/edit-transcript-before-rendering"}]},{"group":"API Reference","icon":"code","pages":[{"title":"Health Check","api":"GET https://api.submagic.co/health","href":"/api-reference/health"},{"title":"Get Languages","api":"GET https://api.submagic.co/v1/languages","href":"/api-reference/languages"},{"title":"Get Templates","api":"GET https://api.submagic.co/v1/templates","href":"/api-reference/templates"},{"title":"Get Hook Title Templates","api":"GET https://api.submagic.co/v1/hook-title/templates","href":"/api-reference/hook-title-templates"},{"title":"List User Media","api":"GET https://api.submagic.co/v1/user-media","href":"/api-reference/list-user-media"},{"title":"Create User Media","api":"POST https://api.submagic.co/v1/user-media","href":"/api-reference/user-media"},{"title":"Upload User Media","api":"POST https://api.submagic.co/v1/user-media/upload","href":"/api-reference/user-media-upload"},{"title":"Create Project","api":"POST https://api.submagic.co/v1/projects","href":"/api-reference/create-project"},{"title":"Create Magic Clips","api":"POST https://api.submagic.co/v1/projects/magic-clips","href":"/api-reference/magic-clips"},{"title":"Upload Magic Clips","api":"POST https://api.submagic.co/v1/projects/magic-clips/upload","href":"/api-reference/magic-clips-upload"},{"title":"Upload Project","api":"POST https://api.submagic.co/v1/projects/upload","href":"/api-reference/upload-project"},{"title":"Get Project","api":"GET https://api.submagic.co/v1/projects/{id}","description":"Retrieve details of a specific video project including processing status and download links","href":"/api-reference/get-project"},{"title":"Update Project","api":"PUT https://api.submagic.co/v1/projects/{id}","href":"/api-reference/update-project"},{"title":"List Presets","api":"GET https://api.submagic.co/v1/presets","description":"List the presets in your library","href":"/api-reference/list-presets"},{"title":"Get Preset","api":"GET https://api.submagic.co/v1/presets/{id}","href":"/api-reference/get-preset"},{"title":"Update Preset","api":"PUT https://api.submagic.co/v1/presets/{id}","href":"/api-reference/update-preset"},{"title":"Export Project","api":"POST https://api.submagic.co/v1/projects/{id}/export","href":"/api-reference/export-project"},{"title":"Publish Project","api":"POST https://api.submagic.co/v1/projects/{id}/publish","href":"/api-reference/publish-project"},{"title":"List Published Projects","api":"GET https://api.submagic.co/v1/projects/published","href":"/api-reference/list-published-projects"},{"title":"Get Publication","api":"GET https://api.submagic.co/v1/projects/published/{id}","href":"/api-reference/get-publication"},{"title":"Publishing Stats","api":"GET https://api.submagic.co/v1/publishing/stats","href":"/api-reference/publishing-stats"},{"title":"Profile Stats","api":"GET https://api.submagic.co/v1/publishing/stats/profiles/{profileId}","href":"/api-reference/profile-stats"}]}]},"basePath":"","title":"Update Project - Submagic API","buildId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","deploymentId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a74be98ba7"],"chunks":["OpenApiReferenceProvider-i2a3QZ8E.js","utils-ChLwp8m0.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-DRktVTDc.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-CA2pEs4T.js","snippetPresets-ClQ6XrKD.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-Ct_Lv36y.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-Cn2PYw9e.js","shallow-rkyymjXQ.js","getApiPlaygroundDisplay-BB9vkXtE.js","CodeSnippet-Bm5RU7m1.js","CodeSnippets-BgU9Deuz.js","Page-BUDYNlhG.js","getPastedJson-BD-6NNum.js","icon-8Z6tud2e.js","MethodPill-Tuzr4g3V.js","DuplicateIcon-0ceWFYhN.js","createIcon-FBXow_ST.js","DynamicMarkdown-CD8713Yy.js","SectionHeading-7zgzQbH-.js","axios-vUo_bRtp.js","zoom-image-lightbox-DMoL6lHz.js","lightbox-handle-r17bVUz3.js"]}