curl -X POST https://api.classet.ai/v2/scripts \ -H "X-API-KEY: your-api-key" \ -H "Content-Type: application/json" \ -d '{ "name": "Electrician Screen", "description": "Screening script for electrician roles", "default": false, "questions": { "Basics": [ "How many years of electrical experience do you have?", "Are you a journeyman or master electrician?" ], "Next Steps": [ "Are you available to start within two weeks?", "Do you have reliable transportation?" ] } }'
{ "data": { "script_id": 3 }}
Scripts
Create Script
Create a script from a template. Pass questions keyed by task name or short_name.
POST
/
v2
/
scripts
curl -X POST https://api.classet.ai/v2/scripts \ -H "X-API-KEY: your-api-key" \ -H "Content-Type: application/json" \ -d '{ "name": "Electrician Screen", "description": "Screening script for electrician roles", "default": false, "questions": { "Basics": [ "How many years of electrical experience do you have?", "Are you a journeyman or master electrician?" ], "Next Steps": [ "Are you available to start within two weeks?", "Do you have reliable transportation?" ] } }'
{ "data": { "script_id": 3 }}
Creates a new interview script from Classet’s Basic Interview template. The new script gets a copy of the template’s five tasks, in order:
Order
Task name
short_name
Takes questions
1
Introduction
Intro
No
2
AI Introduction
AI Intro
No
3
Sell The Position
The Sell
No
4
Learn the Basics about the Candidate
Basics
Yes
5
Establish Next Steps
Next Steps
Yes
questions is an object keyed by a task’s name or short_name. Each value replaces that task’s default questions. A task you don’t name keeps the template’s default questions. A key that matches no task is ignored without an error, so check the spelling. Only tasks whose needed_variables include task.questions ask the questions you set.You can customize individual tasks afterward using the Update Task endpoint.Returns the new script_id. Fetch Get Script when you need the generated task list.
curl -X POST https://api.classet.ai/v2/scripts \ -H "X-API-KEY: your-api-key" \ -H "Content-Type: application/json" \ -d '{ "name": "Electrician Screen", "description": "Screening script for electrician roles", "default": false, "questions": { "Basics": [ "How many years of electrical experience do you have?", "Are you a journeyman or master electrician?" ], "Next Steps": [ "Are you available to start within two weeks?", "Do you have reliable transportation?" ] } }'
{ "data": { "script_id": 3 }}
Authorizations
X-API-KEY
string
header
required
Your Classet API key. Create and rotate keys in Settings → API.
Body
application/json
name
string
required
The name of the script.
Minimum string length: 1
Example:
"Technical Screen"
description
string
A description of the script's purpose.
default
boolean
Set to true to make this the default script for new jobs.
questions
object
Questions for the script's tasks, as a map from task key to an array of question strings. A new script copies its tasks from the default interview template; each key must match a task's name or short_name in that template (see GET /v2/scripts/{scriptId} for a script's tasks). Unknown keys are ignored, and a task with no matching key keeps the template's questions.
Show child attributes
Response
Created
data
object
required
Show child attributes
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Classet API","colors":{"primary":"#A16207","light":"#EDB968","dark":"#A16207"},"logo":{"light":"https://mintcdn.com/classet/F7FrQ_OAFGMrT5Fg/logo/light.svg?fit=max\u0026auto=format\u0026n=F7FrQ_OAFGMrT5Fg\u0026q=85\u0026s=aa940697cace955dcf764ab40e61ee6e","dark":"https://mintcdn.com/classet/F7FrQ_OAFGMrT5Fg/logo/dark.svg?fit=max\u0026auto=format\u0026n=F7FrQ_OAFGMrT5Fg\u0026q=85\u0026s=2bd235026c6489ba56bc624a41ae4266"},"favicon":"https://mintcdn.com/classet/F7FrQ_OAFGMrT5Fg/favicon.ico?fit=max\u0026auto=format\u0026n=F7FrQ_OAFGMrT5Fg\u0026q=85\u0026s=093eeb6f17d708eb4387250ef77557f6","api":{"openapi":{"source":"openapi.json","overlays":["openapi.overlay.json"]},"mdx":{"auth":{"method":"key","name":"X-API-KEY"},"server":"https://api.classet.ai"}},"background":{"color":{"light":"#FFFDF9","dark":"#1C1917"}},"navbar":{"links":[{"href":"https://app.classet.ai","label":"Dashboard"}],"primary":{"type":"button","label":"Get API Key","href":"https://app.classet.ai/settings/developers"}},"footer":{"socials":{"linkedin":"https://www.linkedin.com/company/classet","website":"https://classet.ai"}},"seo":{"metatags":{"og:site_name":"Classet API Documentation","og:image":"https://www.classet.ai/og-image.png","twitter:site":"@classetai","robots":"noindex"},"indexing":"navigable"},"fonts":{"heading":{"family":"Lato","weight":700},"body":{"family":"Lato","weight":400}},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"Product","icon":"box","href":"https://www.classet.ai/product"},{"anchor":"Blog","icon":"newspaper","href":"https://www.classet.ai/blog"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"classet","hasAudioNarration":false,"actualSubdomain":"classet","customDomains":[],"gitSource":{"type":"github","owner":"classet-trades","repo":"classet-monorepo","deployBranch":"main","contentDirectory":"docs","isPrivate":true,"mountPath":"","label":"","_id":"6b0fad66f1dbddd3a85d4e59"},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6b0fb149f1dbddd3a85d6bf2","clientVersion":"0.0.4410","searchFilterCounts":[{"language":"default","tag":"API Reference","count":65},{"language":"default","tag":"Documentation","count":23},{"language":"default","tag":"Guides","count":16},{"language":"default","tag":"Candidates","count":11},{"language":"default","tag":"Message Automations","count":9},{"language":"default","tag":"Scripts","count":9},{"language":"default","tag":"Applications","count":6},{"language":"default","tag":"Jobs","count":6},{"language":"default","tag":"Webhooks","count":5},{"language":"default","tag":"Calls","count":4}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"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":"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":"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":"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":"turbopuffer-dual-write","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":"editor-metadata","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":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"auth-vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":true},"customCss":[{"filePath":"custom.css","content":":root{--radius: 0px}button,input,select,textarea,[role=\"button\"],.card,code,pre,.accordion,[class*=\"rounded\"]{border-radius:0!important}pre{border-radius:0!important;border:1px solid #e5e5e5}.card,[class*=\"callout\"],[class*=\"note\"],[class*=\"warning\"],[class*=\"tip\"]{border-radius:0!important}[role=\"tablist\"] button,[role=\"tab\"]{border-radius:0!important}h1,h2,h3,h4,h5,h6{letter-spacing:-0.02em}p,li,td{letter-spacing:-0.01em}"}]}
{"page":{"pagePath":"api-reference/scripts/create-script","slug":"/api-reference/scripts/create-script","pageMetadata":{"title":"Create Script","openapi":"POST /v2/scripts","description":"Create a script from a template. Pass questions keyed by task name or short_name.","href":"/api-reference/scripts/create-script"},"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: \"Create a script from a template. Pass questions keyed by task name or short_name.\"\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`,p:`p`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{Table}=_components;if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Creates a new interview script from Classet’s Basic Interview template. The new script gets a copy of the template’s five tasks, in order:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Order`}),_jsxs(_components.th,{children:[`Task `,_jsx(_components.code,{children:`name`})]}),_jsx(_components.th,{children:_jsx(_components.code,{children:`short_name`})}),_jsxs(_components.th,{children:[`Takes `,_jsx(_components.code,{children:`questions`})]})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`1`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Introduction`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Intro`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`2`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AI Introduction`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AI Intro`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`3`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Sell The Position`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`The Sell`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`4`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Learn the Basics about the Candidate`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Basics`})}),_jsx(_components.td,{children:`Yes`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`5`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Establish Next Steps`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Next Steps`})}),_jsx(_components.td,{children:`Yes`})]})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`questions`}),` is an object keyed by a task’s `,_jsx(_components.code,{children:`name`}),` or `,_jsx(_components.code,{children:`short_name`}),`. Each value replaces that task’s default questions. A task you don’t name keeps the template’s default questions. A key that matches no task is ignored without an error, so check the spelling. Only tasks whose `,_jsx(_components.code,{children:`needed_variables`}),` include `,_jsx(_components.code,{children:`task.questions`}),` ask the questions you set.`]}),`\n`,_jsxs(_components.p,{children:[`You can customize individual tasks afterward using the `,_jsx(_components.a,{href:`/api-reference/scripts/update-task`,children:`Update Task`}),` endpoint.`]}),`\n`,_jsxs(_components.p,{children:[`Returns the new `,_jsx(_components.code,{children:`script_id`}),`. Fetch `,_jsx(_components.a,{href:`/api-reference/scripts/get-script`,children:`Get Script`}),` when you need the generated task list.`]})]})}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":"Create Script","openapi":"POST /v2/scripts","description":"Create a script from a template. Pass questions keyed by task name or short_name.","href":"/api-reference/scripts/create-script"}}},"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`,p:`p`,pre:`pre`,span:`span`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,RequestExample,ResponseExample,Table}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!RequestExample)_missingMdxReference(`RequestExample`,true);if(!ResponseExample)_missingMdxReference(`ResponseExample`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Creates a new interview script from Classet’s Basic Interview template. The new script gets a copy of the template’s five tasks, in order:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Order`}),_jsxs(_components.th,{children:[`Task `,_jsx(_components.code,{children:`name`})]}),_jsx(_components.th,{children:_jsx(_components.code,{children:`short_name`})}),_jsxs(_components.th,{children:[`Takes `,_jsx(_components.code,{children:`questions`})]})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`1`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Introduction`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Intro`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`2`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AI Introduction`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AI Intro`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`3`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Sell The Position`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`The Sell`})}),_jsx(_components.td,{children:`No`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`4`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Learn the Basics about the Candidate`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Basics`})}),_jsx(_components.td,{children:`Yes`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`5`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Establish Next Steps`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Next Steps`})}),_jsx(_components.td,{children:`Yes`})]})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`questions`}),` is an object keyed by a task’s `,_jsx(_components.code,{children:`name`}),` or `,_jsx(_components.code,{children:`short_name`}),`. Each value replaces that task’s default questions. A task you don’t name keeps the template’s default questions. A key that matches no task is ignored without an error, so check the spelling. Only tasks whose `,_jsx(_components.code,{children:`needed_variables`}),` include `,_jsx(_components.code,{children:`task.questions`}),` ask the questions you set.`]}),`\n`,_jsxs(_components.p,{children:[`You can customize individual tasks afterward using the `,_jsx(_components.a,{href:`/api-reference/scripts/update-task`,children:`Update Task`}),` endpoint.`]}),`\n`,_jsxs(_components.p,{children:[`Returns the new `,_jsx(_components.code,{children:`script_id`}),`. Fetch `,_jsx(_components.a,{href:`/api-reference/scripts/get-script`,children:`Get Script`}),` when you need the generated task list.`]}),`\n`,_jsx(RequestExample,{children:_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`18`,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:`18`,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:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.classet.ai/v2/scripts`}),_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: your-api-key\"`}),_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:` \"name\": \"Electrician Screen\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"description\": \"Screening script for electrician roles\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"default\": false,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"questions\": {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Basics\": [`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"How many years of electrical experience do you have?\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Are you a journeyman or master electrician?\"`})}),`\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:` \"Next Steps\": [`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Are you available to start within two weeks?\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Do you have reliable transportation?\"`})}),`\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`]})})})}),`\n`,_jsx(ResponseExample,{children:_jsx(CodeBlock,{filename:`201`,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:` \"data\"`}),_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:` \"script_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`3`})]}),`\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`]})})})})]})}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":"Create Script","openapi":"POST /v2/scripts","description":"Create a script from a template. Pass questions keyed by task name or short_name.","href":"/api-reference/scripts/create-script"}}}},"mdxExtracts":{"tableOfContents":[],"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=\"18\">\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\"> POST\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> https://api.classet.ai/v2/scripts\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: your-api-key\"\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\"> \"name\": \"Electrician Screen\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"description\": \"Screening script for electrician roles\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"default\": false,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"questions\": {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Basics\": [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"How many years of electrical experience do you have?\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Are you a journeyman or master electrician?\"\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\"> \"Next Steps\": [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Are you available to start within two weeks?\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Do you have reliable transportation?\"\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>"}],"attributes":[]},"response":{"type":"ResponseExample","children":[{"filename":"201","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\"> \"data\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"script_id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">3\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\u003c/code>\u003c/pre>"}],"attributes":[]}}},"jsLinks":[],"openApiReferenceData":{"operation":{"tags":["Scripts"],"summary":"Create a new interview script","description":"Create a script from a template. Pass questions keyed by task name or short_name.","security":["aacced06-3be0-4e25-bc50-9b4ed7b8abd2"],"requestBody":"430c08c7-9587-4d9a-9aad-8b0ad8dd339c","responses":{"201":"c3707984-a180-430b-9ac1-4c88ae4abb2d","400":"432c9f4a-82c1-4321-a3ad-c8588248c62e","500":"f37b25a5-d1ba-4360-a3bb-93d0a02b8583"},"method":"post","type":"path","servers":["17839619-2618-4ac3-afba-460763bc66c5","00aa4118-4e11-4af9-b17e-be21516ad931"],"path":"/v2/scripts","baseUrlOptions":["https://api.classet.ai","http://localhost:8081"],"title":"Create a new interview script","codeSamples":[],"requiredOnlyExamples":false,"requestExamples":[{"dropdown":false,"language":"shellscript","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes github-light-default dark-plus","style":{"backgroundColor":"#ffffff","--shiki-dark-bg":"#0B0C0E","color":"#1f2328","--shiki-dark":"#D4D4D4"},"language":"shellscript","children":{"type":"code","key":null,"ref":null,"props":{"language":"shellscript","numberOfLines":"18","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#953800","--shiki-dark":"#DCDCAA"},"children":"curl"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#0550AE","--shiki-dark":"#569CD6"},"children":" -X"}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" POST"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" https://api.classet.ai/v2/scripts"}},{"type":"span","key":"4","ref":null,"props":{"style":{"color":"#CF222E","--shiki-dark":"#D7BA7D"},"children":" \\"}}]}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#0550AE","--shiki-dark":"#569CD6"},"children":" -H"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"X-API-KEY: your-api-key\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CF222E","--shiki-dark":"#D7BA7D"},"children":" \\"}}]}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#0550AE","--shiki-dark":"#569CD6"},"children":" -H"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Content-Type: application/json\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CF222E","--shiki-dark":"#D7BA7D"},"children":" \\"}}]}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#0550AE","--shiki-dark":"#569CD6"},"children":" -d"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" '{"}}]}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"name\": \"Electrician Screen\","}}}},"\n",{"type":"span","key":"10","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"description\": \"Screening script for electrician roles\","}}}},"\n",{"type":"span","key":"12","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"default\": false,"}}}},"\n",{"type":"span","key":"14","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"questions\": {"}}}},"\n",{"type":"span","key":"16","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Basics\": ["}}}},"\n",{"type":"span","key":"18","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"How many years of electrical experience do you have?\","}}}},"\n",{"type":"span","key":"20","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Are you a journeyman or master electrician?\""}}}},"\n",{"type":"span","key":"22","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" ],"}}}},"\n",{"type":"span","key":"24","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Next Steps\": ["}}}},"\n",{"type":"span","key":"26","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Are you available to start within two weeks?\","}}}},"\n",{"type":"span","key":"28","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" \"Do you have reliable transportation?\""}}}},"\n",{"type":"span","key":"30","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" ]"}}}},"\n",{"type":"span","key":"32","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" }"}}}},"\n",{"type":"span","key":"34","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#0A3069","--shiki-dark":"#CE9178"},"children":" }'"}}}},"\n"]}}}},"filename":"cURL"}],"requestExampleType":"mdx","responseExamples":[{"dropdown":false,"language":"json","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes github-light-default dark-plus","style":{"backgroundColor":"#ffffff","--shiki-dark-bg":"#0B0C0E","color":"#1f2328","--shiki-dark":"#D4D4D4"},"language":"json","children":{"type":"code","key":null,"ref":null,"props":{"language":"json","numberOfLines":"5","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#1F2328","--shiki-dark":"#D4D4D4"},"children":"{"}}}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#116329","--shiki-dark":"#9CDCFE"},"children":" \"data\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#1F2328","--shiki-dark":"#D4D4D4"},"children":": {"}}]}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#116329","--shiki-dark":"#9CDCFE"},"children":" \"script_id\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#1F2328","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#0550AE","--shiki-dark":"#B5CEA8"},"children":"3"}}]}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#1F2328","--shiki-dark":"#D4D4D4"},"children":" }"}}}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#1F2328","--shiki-dark":"#D4D4D4"},"children":"}"}}}},"\n"]}}}},"filename":"201"}],"responseExampleType":"mdx"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"example":"Technical Screen","description":"The name of the script.","isRequired":true,"uniqueKey":"name","typeLabel":"string"},"description":{"type":"string","description":"A description of the script's purpose.","uniqueKey":"description","typeLabel":"string"},"default":{"type":"boolean","description":"Set to `true` to make this the default script for new jobs.","uniqueKey":"default","typeLabel":"boolean"},"questions":{"type":"object","additionalProperties":{"oneOf":[{},{"type":"null","uniqueKey":"questions.additionalProperties.oneOf.1","typeLabel":"null"}],"uniqueKey":"questions.additionalProperties","typeLabel":"null"},"description":"Questions for the script's tasks, as a map from task key to an array of question strings. A new script copies its tasks from the default interview template; each key must match a task's `name` or `short_name` in that template (see GET /v2/scripts/{scriptId} for a script's tasks). Unknown keys are ignored, and a task with no matching key keeps the template's questions.","uniqueKey":"questions","typeLabel":"object"}},"required":["name"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"name":"Technical Screen","description":"\u003cstring>","default":true,"questions":{}}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"c3707984-a180-430b-9ac1-4c88ae4abb2d":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"script_id":{"type":"integer","isRequired":true,"uniqueKey":"data.script_id","typeLabel":"integer"}},"required":["script_id"],"isRequired":true,"uniqueKey":"data","typeLabel":"object"}},"required":["data"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"data":{"script_id":123}}}},"exampleType":"generated"}},"exampleType":"generated"},"432c9f4a-82c1-4321-a3ad-c8588248c62e":{"description":"Bad request","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"Resource not found","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","enum":["not_found","validation_error","unauthorized","forbidden","insufficient_scope","restricted_key_unsupported","branch_out_of_scope","key_misconfigured","quota_exceeded","rate_limited","rate_limit_unavailable","conflict","idempotency_key_reuse","candidate_opted_out","recently_contacted","request_in_progress","unprocessable","bad_request","payload_too_large","internal_error","service_unavailable"],"example":"not_found","description":"Stable machine-readable error code.","uniqueKey":"code","typeLabel":"enum\u003cstring>"},"request_id":{"type":"string","example":"9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f","description":"Request ID, also echoed in the X-Request-Id response header. Include it when reporting issues.","uniqueKey":"request_id","typeLabel":"string"}},"required":["error"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Resource not found","code":"not_found","request_id":"9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f"}}},"exampleType":"generated"}},"exampleType":"generated"},"f37b25a5-d1ba-4360-a3bb-93d0a02b8583":{"description":"Server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"Resource not found","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","enum":["not_found","validation_error","unauthorized","forbidden","insufficient_scope","restricted_key_unsupported","branch_out_of_scope","key_misconfigured","quota_exceeded","rate_limited","rate_limit_unavailable","conflict","idempotency_key_reuse","candidate_opted_out","recently_contacted","request_in_progress","unprocessable","bad_request","payload_too_large","internal_error","service_unavailable"],"example":"not_found","description":"Stable machine-readable error code.","uniqueKey":"code","typeLabel":"enum\u003cstring>"},"request_id":{"type":"string","example":"9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f","description":"Request ID, also echoed in the X-Request-Id response header. Include it when reporting issues.","uniqueKey":"request_id","typeLabel":"string"}},"required":["error"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"Resource not found","code":"not_found","request_id":"9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"aacced06-3be0-4e25-bc50-9b4ed7b8abd2":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-KEY","description":"Your Classet API key. Create and rotate keys in Settings → API.","scopes":[],"schemeName":"ApiKeyAuth"}}},"servers":{"17839619-2618-4ac3-afba-460763bc66c5":{"url":"https://api.classet.ai","description":"Production"},"00aa4118-4e11-4af9-b17e-be21516ad931":{"url":"http://localhost:8081","description":"Local development"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"X-API-KEY","description":"Your Classet API key. Create and rotate keys in Settings → API.","scopes":[],"schemeName":"ApiKeyAuth"},"schema":{"title":"X-API-KEY","type":"string","description":"Your Classet API key. Create and rotate keys in Settings → API.","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKeyAuth","name":"X-API-KEY"}],"title":"ApiKeyAuth"}]},"originalFileLocation":"openapi.json"},"subdomain":"classet","siteName":"Classet API","title":"Create Script - Classet API","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-12-02T05:49:06.207Z","originalFileLocation":"api-reference/scripts/create-script.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=\"Create a script from a template. Pass questions keyed by task name or short_name.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Classet API\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"noindex\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_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=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create Script - Classet API\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create a script from a template. Pass questions keyed by task name or short_name.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Classet API Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://www.classet.ai/og-image.png\">\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=\"Create Script - Classet API\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create a script from a template. Pass questions keyed by task name or short_name.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://www.classet.ai/og-image.png\">\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=\"/docs/mintlify-assets/_mintlify/favicons/classet/c0zbHJjKuSM8zOpy/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Classet API\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#A16207\">\u003clink data-mint-head rel=\"canonical\" href=\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/api-reference/scripts/create-script.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://classet.mintlify.dev/#organization\",\"name\":\"Classet API\",\"url\":\"https://classet.mintlify.dev\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/classet/F7FrQ_OAFGMrT5Fg/logo/light.svg?fit=max\u0026auto=format\u0026n=F7FrQ_OAFGMrT5Fg\u0026q=85\u0026s=aa940697cace955dcf764ab40e61ee6e\"}},{\"@type\":\"WebSite\",\"@id\":\"https://classet.mintlify.dev/docs#website\",\"name\":\"Classet API\",\"url\":\"https://classet.mintlify.dev/docs\",\"publisher\":{\"@id\":\"https://classet.mintlify.dev/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script#webpage\",\"url\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script\",\"name\":\"Create Script\",\"description\":\"Create a script from a template. Pass questions keyed by task name or short_name.\",\"dateModified\":\"2026-12-02T05:49:06.207Z\",\"isPartOf\":{\"@id\":\"https://classet.mintlify.dev/docs#website\"},\"breadcrumb\":{\"@id\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Scripts\",\"item\":\"https://classet.mintlify.dev/docs/api-reference/scripts/list-scripts\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create Script\",\"item\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script#apireference\",\"headline\":\"Create Script\",\"name\":\"Create Script\",\"description\":\"Create a script from a template. Pass questions keyed by task name or short_name.\",\"url\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script\",\"mainEntityOfPage\":{\"@id\":\"https://classet.mintlify.dev/docs/api-reference/scripts/create-script#webpage\"},\"image\":\"https://www.classet.ai/og-image.png\",\"dateModified\":\"2026-12-02T05:49:06.207Z\",\"publisher\":{\"@id\":\"https://classet.mintlify.dev/#organization\"},\"isPartOf\":{\"@id\":\"https://classet.mintlify.dev/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Classet API\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Classet API\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/docs/api-reference/scripts/create-script.md","siteName":"Classet API","nav":{"global":{"anchors":[{"anchor":"Product","icon":"box","href":"https://www.classet.ai/product"},{"anchor":"Blog","icon":"newspaper","href":"https://www.classet.ai/blog"}]},"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/introduction"}]},{"tab":"API Reference","groups":[{"group":"Overview","pages":[{"title":"API Reference","href":"/api-reference/overview"},{"title":"Health Check","openapi":"GET /v2/health","href":"/api-reference/health"}]},{"group":"Organization","pages":[{"title":"Get Organization","openapi":"GET /v2/organization","href":"/api-reference/organization/get-organization"},{"title":"List Branches","openapi":"GET /v2/branches","href":"/api-reference/organization/list-branches"},{"title":"List Users","openapi":"GET /v2/users","href":"/api-reference/organization/list-users"},{"title":"List Tags","openapi":"GET /v2/tags","href":"/api-reference/organization/list-tags"}]},{"group":"Jobs","pages":[{"title":"List Jobs","openapi":"GET /v2/jobs","href":"/api-reference/jobs/list-jobs"},{"title":"Get Job","openapi":"GET /v2/jobs/{jobId}","href":"/api-reference/jobs/get-job"},{"title":"List Job Stages","openapi":"GET /v2/jobs/{jobId}/stages","href":"/api-reference/jobs/list-stages"},{"title":"Create Job","openapi":"POST /v2/jobs","href":"/api-reference/jobs/create-job"},{"title":"Update Job","openapi":"PATCH /v2/jobs/{jobId}","href":"/api-reference/jobs/update-job"},{"title":"Delete Job","openapi":"DELETE /v2/jobs/{jobId}","href":"/api-reference/jobs/delete-job"}]},{"group":"Candidates","pages":[{"title":"List Candidates","openapi":"GET /v2/candidates","href":"/api-reference/candidates/list-candidates"},{"title":"Create Candidate","openapi":"POST /v2/candidates","href":"/api-reference/candidates/create-candidate"},{"title":"Get Candidate","openapi":"GET /v2/candidates/{candidateId}","href":"/api-reference/candidates/get-candidate"},{"title":"Update Candidate","openapi":"PATCH /v2/candidates/{candidateId}","href":"/api-reference/candidates/update-candidate"},{"title":"Get Interview","openapi":"GET /v2/candidates/{candidateId}/interview","href":"/api-reference/candidates/get-interview"},{"title":"Get Messages","openapi":"GET /v2/candidates/{candidateId}/messages","href":"/api-reference/candidates/get-messages"},{"title":"Send Interview","openapi":"POST /v2/candidates/{candidateId}/interview","href":"/api-reference/candidates/send-interview"},{"title":"Stop Interview","openapi":"POST /v2/candidates/{candidateId}/stop-interview","href":"/api-reference/candidates/stop-interview"},{"title":"List Candidate Activity","openapi":"GET /v2/candidates/{candidateId}/activity","href":"/api-reference/candidates/list-activity"},{"title":"List Candidate Attachments","openapi":"GET /v2/candidates/{candidateId}/attachments","href":"/api-reference/candidates/list-attachments"},{"title":"List Candidate Notes","openapi":"GET /v2/candidates/{candidateId}/notes","href":"/api-reference/candidates/list-notes"}]},{"group":"Applications","pages":[{"title":"List All Applications","openapi":"GET /v2/applications","href":"/api-reference/applications/list-all-applications"},{"title":"List Applications for a Job","openapi":"GET /v2/jobs/{jobId}/applications","href":"/api-reference/applications/list-applications"},{"title":"Get Application","openapi":"GET /v2/applications/{applicationId}","href":"/api-reference/applications/get-application"},{"title":"Update Application","openapi":"PATCH /v2/applications/{applicationId}","href":"/api-reference/applications/update-application"},{"title":"Disqualify Application","openapi":"POST /v2/applications/{applicationId}/disqualify","href":"/api-reference/applications/disqualify"},{"title":"Move Application Stage","openapi":"PUT /v2/applications/{applicationId}/stage","href":"/api-reference/applications/move-stage"}]},{"group":"Calls","pages":[{"title":"Register Call","openapi":"POST /v2/calls","href":"/api-reference/calls/register-call"},{"title":"Get Call","openapi":"GET /v2/calls/{callId}","href":"/api-reference/calls/get-call"},{"title":"List Candidate Calls","openapi":"GET /v2/candidates/{candidateId}/calls","href":"/api-reference/calls/list-candidate-calls"},{"title":"Download Call Recording","openapi":"GET /v2/calls/{callId}/recording","href":"/api-reference/calls/download-recording"}]},{"group":"Scripts","pages":[{"title":"List Scripts","openapi":"GET /v2/scripts","href":"/api-reference/scripts/list-scripts"},{"title":"Get Script","openapi":"GET /v2/scripts/{scriptId}","description":"Retrieve a script with all tasks, agent settings, and task metadata.","href":"/api-reference/scripts/get-script"},{"title":"Create Script","openapi":"POST /v2/scripts","href":"/api-reference/scripts/create-script"},{"title":"Update Script","openapi":"PATCH /v2/scripts/{scriptId}","description":"Update script metadata and agent settings (outreach messages, summary instructions, etc).","href":"/api-reference/scripts/update-script"},{"title":"Delete Script","openapi":"DELETE /v2/scripts/{scriptId}","href":"/api-reference/scripts/delete-script"},{"title":"Duplicate Script","openapi":"POST /v2/scripts/{scriptId}/duplicate","href":"/api-reference/scripts/duplicate-script"},{"title":"Add Task","openapi":"POST /v2/scripts/{scriptId}/tasks","href":"/api-reference/scripts/add-task"},{"title":"Update Script Task","openapi":"PATCH /v2/script-tasks/{taskId}","href":"/api-reference/scripts/update-task"},{"title":"Reorder Tasks","openapi":"PUT /v2/scripts/{scriptId}/reorder-tasks","href":"/api-reference/scripts/reorder-tasks"}]},{"group":"Message Automations","pages":[{"title":"List Message Automations","openapi":"GET /v2/message-automations","href":"/api-reference/message-automations/list-automations"},{"title":"Get Message Automation","openapi":"GET /v2/message-automations/{automationId}","href":"/api-reference/message-automations/get-automation"},{"title":"Create Message Automation","openapi":"POST /v2/message-automations","href":"/api-reference/message-automations/create-automation"},{"title":"Update Message Automation","openapi":"PATCH /v2/message-automations/{automationId}","href":"/api-reference/message-automations/update-automation"},{"title":"Delete Message Automation","openapi":"DELETE /v2/message-automations/{automationId}","href":"/api-reference/message-automations/delete-automation"},{"title":"Duplicate Message Automation","openapi":"POST /v2/message-automations/{automationId}/duplicate","href":"/api-reference/message-automations/duplicate-automation"},{"title":"Update Automation Steps","openapi":"PUT /v2/message-automations/{automationId}/steps","href":"/api-reference/message-automations/update-steps"},{"title":"Set Default Automation","openapi":"POST /v2/message-automations/{automationId}/set-default","href":"/api-reference/message-automations/set-default"},{"title":"Link Automation to Script","openapi":"POST /v2/scripts/{scriptId}/link-automation","href":"/api-reference/message-automations/link-to-script"}]},{"group":"Agent Settings","pages":[{"title":"Get Agent Settings","openapi":"GET /v2/agent-settings","href":"/api-reference/agent-settings/get-settings"},{"title":"Update Agent Settings","openapi":"PATCH /v2/agent-settings","href":"/api-reference/agent-settings/update-settings"}]},{"group":"Knowledge Base","pages":[{"title":"List Knowledge Entries","openapi":"GET /v2/knowledge","href":"/api-reference/knowledge/list-entries"},{"title":"Create Knowledge Entry","openapi":"POST /v2/knowledge","href":"/api-reference/knowledge/create-entry"},{"title":"Update Knowledge Entry","openapi":"PATCH /v2/knowledge/{entryId}","href":"/api-reference/knowledge/update-entry"},{"title":"Delete Knowledge Entry","openapi":"DELETE /v2/knowledge/{entryId}","href":"/api-reference/knowledge/delete-entry"}]},{"group":"AI Generation","pages":[{"title":"Generate Job","openapi":"POST /v2/jobs/generate","href":"/api-reference/ai/generate-job"},{"title":"Generate Script","openapi":"POST /v2/scripts/generate","href":"/api-reference/ai/generate-script"},{"title":"Onboard Company","openapi":"POST /v2/onboard","href":"/api-reference/ai/onboard"}]},{"group":"Webhooks","pages":[{"title":"Get Webhook Config","openapi":"GET /v2/webhooks","href":"/api-reference/webhooks/get-config"},{"title":"Update Webhook Config","openapi":"PUT /v2/webhooks","href":"/api-reference/webhooks/update-config"},{"title":"Test Webhook","openapi":"POST /v2/webhooks/test","href":"/api-reference/webhooks/test"},{"title":"List Webhook Deliveries","openapi":"GET /v2/webhooks/events","href":"/api-reference/webhooks/list-events"},{"title":"Get Webhook Delivery","openapi":"GET /v2/webhooks/events/{eventId}","href":"/api-reference/webhooks/get-event"}]}]}]},"basePath":"","title":"Create Script - Classet API","deploymentId":"dpl_4jsQX6wxBTKTWBK49utMnZg6AX9Q","buildId":"dpl_4jsQX6wxBTKTWBK49utMnZg6AX9Q","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CqAH5gmw.js","snippetPresets-BJgunkn7.js","utils-2nvZyCRg.js","style-to-object-BY3JEAdk.js","utils-Dg_ccOpq.js","v4-DIgz8zy6.js","addTypeLabelsToSchema-Dx13yQ3Z.js","conditional-requirements-CFM0id0Q.js","cloneDeep-BF2bK8_8.js","_Uint8Array-CroFGttd.js","isObject-FP1Yky1u.js","ApiExamples-DVMMKE_5.js","usePlaygroundInputsStore-CZqNhEOQ.js","shallow-lVKuG6ys.js","isEqual-BtwhVrrv.js","CodeSnippets-D1j3p1Ld.js","CodeSnippet-DZ0X6n6h.js","use-playground-group-access-CHc7bwGD.js","Page-Dsa0ree3.js","api-description-markdown-D8YljcAx.js","DynamicMarkdown-BpzBQATn.js","SectionHeading-DbMHVbf0.js","MethodPill-Bw-UUkE7.js","getPastedJson-DSpdmJSt.js","Check2Icon-CQQrmKnL.js","axios-CsQoIw0U.js","Markdown-DzeE2WAf.js","AssistantPageLink-CufzKkGt.js","dist-b2i9ft66.js","lib-DMeTj1gb.js","lib-B8HbPgcC.js","katex-Dbtb6Wk7.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js"]}