{
"message": "Duplicate locale codes in request: es"
}
{
"message": "Locale code already attached to another variant: es. A locale code can belong to at most one variant."
}
Variants
Create variants
Creates one or more variants in the workspace.
A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item’s text for that variant.
Read the developer IDs off the response rather than assuming them — a developer ID you don’t specify is generated from the name.
Array of developer IDs for the created variants, in request order
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Ditto","description":"Developer documentation for Ditto, the source of truth for product text. Scan a codebase to import its strings, then connect coding agents through the Ditto MCP server, link Figma files, and pull localized string files with the CLI.","colors":{"primary":"#E2B103","light":"#F0D164","dark":"#1D1700"},"logo":{"light":"https://mintcdn.com/ditto/A9jN5zv6WG_Dk9hK/logo/ditto_logo.svg?fit=max\u0026auto=format\u0026n=A9jN5zv6WG_Dk9hK\u0026q=85\u0026s=4e38ddaa8955775a191cbe1616e02312","dark":"https://mintcdn.com/ditto/A9jN5zv6WG_Dk9hK/logo/ditto_logo.svg?fit=max\u0026auto=format\u0026n=A9jN5zv6WG_Dk9hK\u0026q=85\u0026s=4e38ddaa8955775a191cbe1616e02312"},"favicon":"https://mintcdn.com/ditto/WgRtoF9rLXWv6hNh/favicon.jpeg?fit=max\u0026auto=format\u0026n=WgRtoF9rLXWv6hNh\u0026q=85\u0026s=011fcbfc2411f0c04ab811e7b701750c","background":{"color":{"dark":"#11141B"}},"navbar":{"links":[{"href":"mailto:support@dittowords.com","label":"Support"}],"primary":{"type":"button","label":"Open App","href":"https://app.dittowords.com"}},"footer":{"socials":{"twitter":"https://twitter.com/dittowords","github":"https://github.com/dittowords","linkedin":"https://www.linkedin.com/company/ditto-app"}},"seo":{"organization":{"id":"https://www.dittowords.com/#organization","name":"Ditto","url":"https://www.dittowords.com","logo":"https://developer.dittowords.com/logo/ditto_logo.svg","sameAs":["https://twitter.com/dittowords","https://github.com/dittowords","https://www.linkedin.com/company/ditto-app"]},"indexing":"navigable"},"contextual":{"options":["copy","view","claude","chatgpt","mcp","cursor","vscode"],"display":"header"},"markdown":{"instructions":["These are Ditto's developer docs. Ditto is a single source of truth for product copy across design, review, localization, and code.","The first step on any codebase is a scan: https://developer.dittowords.com/get-started/scan-your-repo.md. That page also covers reviewing the style guide Ditto drafts from the scan. After it, the follow-on guides are Connect Figma files and Set up localization (under /guides/) and Connect the Ditto MCP (the Setup page of the MCP reference).","Two different MCP servers: the Ditto MCP server at https://api.dittowords.com/v2/mcp gives an agent a workspace's text and style guide rules; the documentation MCP server at https://developer.dittowords.com/mcp searches these docs.","Prefer logging in with a Ditto account (npx -y @dittowords/cli@latest login; OAuth in MCP clients) over API keys. API keys are for CI and headless clients only.","Commands are complete as written and use npx -y @dittowords/cli@latest; nothing needs a global install."]},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"Help Guides","icon":"book-open-cover","href":"https://help.dittowords.com/en/"},{"anchor":"What's New","icon":"newspaper","href":"https://www.dittowords.com/whats-new"},{"anchor":"Figma Plugin","icon":"figma","href":"https://www.figma.com/community/plugin/798826066406007173/ditto-manage-copy-from-design-to-production"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"ditto","hasAudioNarration":false,"actualSubdomain":"ditto","customDomains":["developer.dittowords.com"],"gitSource":{"type":"github","owner":"dittowords","repo":"ditto-app","deployBranch":"master","contentDirectory":"docs-public","isPrivate":false,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ada5ce522ea2a3b6e0dbfac","collectionId":"90313f13-54a1-4f52-8dba-e0009122f9c2","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ada5ce522ea2a3b6e0dbfac"},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"REMOVE_BRANDING":{"status":"DISABLED"},"CONTEXTUAL_FEEDBACK":{"status":"DISABLED"},"CODE_SNIPPET_FEEDBACK":{"status":"DISABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ada5ce522ea2a3b6e0dbfac","clientVersion":"0.0.3971","searchFilterCounts":[{"language":"default","tag":"Documentation","count":90},{"language":"default","tag":"API Reference","count":61},{"language":"default","tag":"Endpoints","count":59},{"language":"default","tag":"Legacy","count":18},{"language":"default","tag":"Components","count":16},{"language":"default","tag":"Text Items","count":7},{"language":"default","tag":"CLI Reference","count":7},{"language":"default","tag":"Component Folders","count":6},{"language":"default","tag":"Projects","count":6},{"language":"default","tag":"Style guides","count":6}]},"assistantConfig":{},"basePath":"","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":"editor-v7-file-tree","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":"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":"pause-universal-search-reconcile","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":"per-site-search-delta","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":"editor-private-page-search","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":"editor-nav-generations","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":"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":"byok-sep-25","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":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","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":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/variants/create-variants","slug":"/api-reference/variants/create-variants","pageMetadata":{"openapi":"openapi.json post /variants","title":"Create variants","description":"Creates one or more variants in the workspace.\n\nA variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item's text for that variant.\n\nRead the developer IDs off the response rather than assuming them — a developer ID you don't specify is generated from the name.","href":"/api-reference/variants/create-variants"},"description":{"compiledSource":"\"use strict\";\nconst {Fragment: _Fragment, jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_Fragment, {\n children: [_jsx(_components.p, {\n children: \"Creates one or more variants in the workspace.\"\n }), \"\\n\", _jsx(_components.p, {\n children: \"A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item’s text for that variant.\"\n }), \"\\n\", _jsx(_components.p, {\n children: \"Read the developer IDs off the response rather than assuming them — a developer ID you don’t specify is generated from the name.\"\n })]\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}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"openapi":"openapi.json post /variants","title":"Create variants","description":"Creates one or more variants in the workspace.\n\nA variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item's text for that variant.\n\nRead the developer IDs off the response rather than assuming them — a developer ID you don't specify is generated from the name.","href":"/api-reference/variants/create-variants"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"tags":["Variants"],"description":"Creates one or more variants in the workspace.\n\nA variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item's text for that variant.\n\nRead the developer IDs off the response rather than assuming them — a developer ID you don't specify is generated from the name.","summary":"Create variants","security":["0e65b22a-a7f7-4749-826d-2e7d69d8d9cd"],"requestBody":"0859a51e-38fa-4fc0-9ce8-1c4f13d40b19","responses":{"200":"e8537f10-de11-4dda-9a62-2c96dfb1e2bf","400":"37d8c2b3-8b92-4737-8e9f-1eeeec6ad215","409":"9a6e2ef2-786d-4e48-9927-dfa5258065af"},"method":"post","type":"path","servers":["69d2654a-fa4f-42ae-b988-6c331fe3ca17"],"path":"/variants","baseUrlOptions":["https://api.dittowords.com/v2"],"title":"Create variants","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"variants":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"description":"The variant's name. Must be unique within the workspace; 'base' is reserved.","isRequired":true,"uniqueKey":"variants.items.[INDEX].name","typeLabel":"string"},"developerId":{"type":"string","minLength":1,"description":"Optional preconfigured developer ID for the variant. Must be unique to the workspace and validate against the workspace Developer ID configuration rules. If omitted, one is generated from the name.","uniqueKey":"variants.items.[INDEX].developerId","typeLabel":"string"},"description":{"type":"string","description":"Optional description of what the variant is for.","uniqueKey":"variants.items.[INDEX].description","typeLabel":"string"},"localeCode":{"type":"string","enum":["af","ar","ar-ae","ar-bh","ar-dz","ar-eg","ar-iq","ar-jo","ar-kw","ar-lb","ar-ly","ar-ma","ar-om","ar-qa","ar-sa","ar-sy","ar-tn","ar-ye","az","be","bg","bs","ca","cs","cy","da","de","de-at","de-ch","de-li","de-lu","el","en","en-au","en-bz","en-ca","en-gb","en-ie","en-jm","en-nz","en-sg","en-tt","en-us","en-za","es","es-ar","es-bo","es-cl","es-co","es-cr","es-do","es-ec","es-gt","es-hn","es-mx","es-ni","es-pa","es-pe","es-pr","es-py","es-sv","es-uy","es-ve","et","eu","fa","fi","fo","fr","fr-be","fr-ca","fr-ch","fr-lu","ga","gd","he","hi","hr","hu","hy","id","is","it","it-ch","ja","ka","kk","ko","ku","lt","lv","mk","ml","ms","mt","nb","nl","nl-be","nn","no","pa","pl","pt","pt-br","rm","ro","ro-md","ru","ru-md","sk","sl","sq","sr","sv","sv-fi","th","tn","tr","ts","uk","ur","ve","vi","wen","xh","yi","zh-cn","zh-hk","zh-sg","zh-tw","zu"],"description":"Locale code for the variant, from the set Ditto supports. Casing does not matter on the way in — 'fr-CA' and 'fr-ca' are both accepted — and the code is stored lowercase, which is the form reads return. Not every language-region pairing exists in the set, so pick one of the listed values rather than composing your own. At most one variant per workspace can hold a given locale code. Set this whenever the variant represents a language: translation tools treat it as the authoritative target locale.","uniqueKey":"variants.items.[INDEX].localeCode","typeLabel":"enum\u003cstring>"}},"required":["name"],"uniqueKey":"variants.items.[INDEX]","typeLabel":"object"},"minItems":1,"description":"Array of new variants to create","isRequired":true,"uniqueKey":"variants","typeLabel":"object[]"}},"required":["variants"],"example":{"variants":[{"name":"Spanish","localeCode":"es"},{"name":"Canadian French","developerId":"fr-ca","description":"French translations for Canada"}]},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"variants":[{"name":"Spanish","localeCode":"es"},{"name":"Canadian French","developerId":"fr-ca","description":"French translations for Canada"}]}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"e8537f10-de11-4dda-9a62-2c96dfb1e2bf":{"description":"Returns the developer IDs of the created variants, in request order","content":{"application/json":{"schema":{"type":"object","properties":{"developerIds":{"type":"array","items":{"type":"string","uniqueKey":"developerIds.items.[INDEX]","typeLabel":"string"},"description":"Array of developer IDs for the created variants, in request order","isRequired":true,"uniqueKey":"developerIds","typeLabel":"string[]"}},"required":["developerIds"],"example":{"developerIds":["spanish","fr-ca"]},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"developerIds":["spanish","fr-ca"]}}},"exampleType":"generated"}},"exampleType":"generated"},"37d8c2b3-8b92-4737-8e9f-1eeeec6ad215":{"description":"Returned when the request body fails validation. Common causes include: the same name, developer ID, or locale code appearing twice in one request; a reserved developer ID.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Error message describing the validation failure","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["message"],"uniqueKey":"","typeLabel":"object"},"example":{"message":"Duplicate locale codes in request: es"},"examples":{"Example":{"title":"Example","value":{"message":"Duplicate locale codes in request: es"}}},"exampleType":"examples"}},"exampleType":"examples"},"9a6e2ef2-786d-4e48-9927-dfa5258065af":{"description":"Returned when a name, developer ID, or locale code is already in use by another variant in the workspace","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Error message describing the conflict","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["message"],"uniqueKey":"","typeLabel":"object"},"example":{"message":"Locale code already attached to another variant: es. A locale code can belong to at most one variant."},"examples":{"Example":{"title":"Example","value":{"message":"Locale code already attached to another variant: es. A locale code can belong to at most one variant."}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"0e65b22a-a7f7-4749-826d-2e7d69d8d9cd":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"Authorization","scopes":[],"schemeName":"ApiKeyAuth"}}},"servers":{"69d2654a-fa4f-42ae-b988-6c331fe3ca17":{"url":"https://api.dittowords.com/v2"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"Authorization","scopes":[],"schemeName":"ApiKeyAuth"},"schema":{"title":"Authorization","type":"string","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKeyAuth","name":"Authorization"}],"title":"ApiKeyAuth"}]},"originalFileLocation":"openapi.json"},"subdomain":"ditto","siteName":"Ditto","title":"Create variants - Ditto","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-08-19T17:29:38.664Z","originalFileLocation":"api-reference/variants/create-variants.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=\"Creates one or more variants in the workspace. A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item\u0026#x27;s text for that variant. Read the developer IDs off the response rather than assuming them — a developer ID you don\u0026#x27;t specify is generated from the name.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Ditto\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_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/ditto/sayH8aGeMpv32blB/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create variants - Ditto\">\u003cmeta data-mint-head property=\"og:description\" content=\"Creates one or more variants in the workspace. A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item\u0026#x27;s text for that variant. Read the developer IDs off the response rather than assuming them — a developer ID you don\u0026#x27;t specify is generated from the name.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Ditto\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://developer.dittowords.com/api-reference/variants/create-variants\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://ditto.mintlify.app/_mintlify/api/og/v2?division=Variants\u0026amp;title=Create+variants\u0026amp;description=Creates+one+or+more+variants+in+the+workspace.%0A%0AA+variant+is+a+named+alternative+that+text+items+and+library+components+can+each+have+their+own+text+for+%E2%80%94+most+\u0026amp;theme=cafcf8215feabbb48baf53ae\u0026amp;signature=653f5e0b7a6dc1034c659c114dade0dfe36233aabc60d17a1d127607739e4ed1\">\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 variants - Ditto\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Creates one or more variants in the workspace. A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item\u0026#x27;s text for that variant. Read the developer IDs off the response rather than assuming them — a developer ID you don\u0026#x27;t specify is generated from the name.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://ditto.mintlify.app/_mintlify/api/og/v2?division=Variants\u0026amp;title=Create+variants\u0026amp;description=Creates+one+or+more+variants+in+the+workspace.%0A%0AA+variant+is+a+named+alternative+that+text+items+and+library+components+can+each+have+their+own+text+for+%E2%80%94+most+\u0026amp;theme=cafcf8215feabbb48baf53ae\u0026amp;signature=653f5e0b7a6dc1034c659c114dade0dfe36233aabc60d17a1d127607739e4ed1\">\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/ditto/sayH8aGeMpv32blB/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Ditto\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#E2B103\">\u003clink data-mint-head rel=\"canonical\" href=\"https://developer.dittowords.com/api-reference/variants/create-variants\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/variants/create-variants.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://www.dittowords.com/#organization\",\"name\":\"Ditto\",\"url\":\"https://www.dittowords.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://developer.dittowords.com/logo/ditto_logo.svg\"},\"sameAs\":[\"https://twitter.com/dittowords\",\"https://github.com/dittowords\",\"https://www.linkedin.com/company/ditto-app\"]},{\"@type\":\"WebSite\",\"@id\":\"https://developer.dittowords.com#website\",\"name\":\"Ditto\",\"url\":\"https://developer.dittowords.com\",\"publisher\":{\"@id\":\"https://www.dittowords.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://developer.dittowords.com/api-reference/variants/create-variants#webpage\",\"url\":\"https://developer.dittowords.com/api-reference/variants/create-variants\",\"name\":\"Create variants\",\"description\":\"Creates one or more variants in the workspace. A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item's text for that variant. Read the developer IDs off the response rather than assuming them — a developer ID you don't specify is generated from the name.\",\"dateModified\":\"2026-08-19T17:29:38.664Z\",\"isPartOf\":{\"@id\":\"https://developer.dittowords.com#website\"},\"breadcrumb\":{\"@id\":\"https://developer.dittowords.com/api-reference/variants/create-variants#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://developer.dittowords.com/api-reference/variants/create-variants#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API Reference\",\"item\":\"https://developer.dittowords.com/api-reference/authentication\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Endpoints\",\"item\":\"https://developer.dittowords.com/api-reference/activity/get-activity\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Variants\",\"item\":\"https://developer.dittowords.com/api-reference/variants/get-variants\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Create variants\",\"item\":\"https://developer.dittowords.com/api-reference/variants/create-variants\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://developer.dittowords.com/api-reference/variants/create-variants#apireference\",\"headline\":\"Create variants\",\"name\":\"Create variants\",\"description\":\"Creates one or more variants in the workspace. A variant is a named alternative that text items and library components can each have their own text for — most often a locale to translate into, but also a tone or brand variation. Creating a variant adds no text on its own; use the text item endpoints to set a text item's text for that variant. Read the developer IDs off the response rather than assuming them — a developer ID you don't specify is generated from the name.\",\"url\":\"https://developer.dittowords.com/api-reference/variants/create-variants\",\"mainEntityOfPage\":{\"@id\":\"https://developer.dittowords.com/api-reference/variants/create-variants#webpage\"},\"dateModified\":\"2026-08-19T17:29:38.664Z\",\"publisher\":{\"@id\":\"https://www.dittowords.com/#organization\"},\"isPartOf\":{\"@id\":\"https://developer.dittowords.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Ditto\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Ditto","nav":{"global":{"anchors":[{"anchor":"Help Guides","icon":"book-open-cover","href":"https://help.dittowords.com/en/"},{"anchor":"What's New","icon":"newspaper","href":"https://www.dittowords.com/whats-new"},{"anchor":"Figma Plugin","icon":"figma","href":"https://www.figma.com/community/plugin/798826066406007173/ditto-manage-copy-from-design-to-production"}]},"tabs":[{"tab":"Documentation","groups":[{"group":"Start here","pages":[{"title":"Ditto developer documentation","sidebarTitle":"Introduction","href":"/introduction"},{"title":"Scan your repo","href":"/get-started/scan-your-repo"},{"title":"Connect Figma files","href":"/guides/connect-figma-files"},{"title":"Set up localization","href":"/guides/set-up-localization"}]},{"group":"Concepts","pages":[{"title":"Key concepts","href":"/concepts"}]},{"group":"CLI Reference","pages":[{"title":"Install and log in to the Ditto CLI","sidebarTitle":"Install and log in","href":"/cli-reference/authentication"},{"title":"Ditto CLI commands","sidebarTitle":"Commands","href":"/cli-reference/commands"},{"title":"Ditto CLI configuration","sidebarTitle":"Configuration","href":"/cli-reference/configuration"},{"title":"Ditto CLI output files","sidebarTitle":"Files","href":"/cli-reference/files"}]},{"group":"API Reference","pages":[{"title":"Ditto API authentication","sidebarTitle":"Authentication","href":"/api-reference/authentication"},{"group":"Endpoints","pages":[{"group":"Activity","pages":[{"openapi":"openapi.json get /activity","title":"Fetch activity","href":"/api-reference/activity/get-activity"}]},{"group":"Components","pages":[{"openapi":"openapi.json get /components","title":"Fetch components","href":"/api-reference/components/get-components"},{"openapi":"openapi.json get /components/export","title":"Export components","href":"/api-reference/components/export-components"},{"openapi":"openapi.json post /components","title":"Create components","href":"/api-reference/components/create-components"},{"openapi":"openapi.json patch /components","title":"Update components","href":"/api-reference/components/patch-components"},{"openapi":"openapi.json delete /components","title":"Delete components","href":"/api-reference/components/delete-components"},{"group":"Text Item Linking","pages":[{"openapi":"openapi.json post /components/publish","title":"Publish a text item to the library","href":"/api-reference/components/publish-component"},{"openapi":"openapi.json patch /components/link","title":"Link text items to a component","href":"/api-reference/components/link-components"},{"openapi":"openapi.json patch /components/unlink","title":"Unlink text items from a component","href":"/api-reference/components/unlink-components"}]},{"group":"Versioning","pages":[{"openapi":"openapi.json get /components/staged","title":"Fetch unpublished component changes","href":"/api-reference/components/get-unpublished-component-changes"},{"openapi":"openapi.json patch /components/staged","title":"Save unpublished component changes","href":"/api-reference/components/save-unpublished-component-changes"},{"openapi":"openapi.json delete /components/staged","title":"Discard unpublished component changes","href":"/api-reference/components/discard-unpublished-component-changes"},{"openapi":"openapi.json post /components/staged/publish","title":"Publish component changes","href":"/api-reference/components/publish-component-changes"},{"openapi":"openapi.json patch /components/upgrade","title":"Upgrade component instances","href":"/api-reference/components/upgrade-component-instances"}]}]},{"group":"Component Folders","pages":[{"openapi":"openapi.json get /componentFolders","title":"Fetch component folders","href":"/api-reference/component-folders/get-component-folders"},{"openapi":"openapi.json post /componentFolders","title":"Create component folders","href":"/api-reference/component-folders/create-component-folders"},{"openapi":"openapi.json patch /componentFolders","title":"Update component folders","href":"/api-reference/component-folders/patch-component-folders"},{"openapi":"openapi.json delete /componentFolders","title":"Delete component folders","href":"/api-reference/component-folders/delete-component-folders"}]},{"group":"Projects","pages":[{"openapi":"openapi.json get /projects","title":"Fetch projects","href":"/api-reference/projects/get-projects"},{"openapi":"openapi.json post /projects","title":"Create a project","href":"/api-reference/projects/create-projects"},{"openapi":"openapi.json patch /projects/{projectId}","title":"Update a project","href":"/api-reference/projects/patch-projects"}]},{"group":"Project Blocks","pages":[{"openapi":"openapi.json get /projectBlocks","title":"Fetch project blocks","href":"/api-reference/project-blocks/get-project-blocks"},{"openapi":"openapi.json post /projectBlocks","title":"Create project blocks","href":"/api-reference/project-blocks/create-project-blocks"},{"openapi":"openapi.json patch /projectBlocks","title":"Update project blocks","href":"/api-reference/project-blocks/patch-project-blocks"},{"openapi":"openapi.json delete /projectBlocks","title":"Delete project blocks","href":"/api-reference/project-blocks/delete-project-blocks"}]},{"group":"Statuses","pages":[{"openapi":"openapi.json get /statuses","title":"Fetch statuses","href":"/api-reference/statuses/get-statuses"}]},{"group":"Style guides","pages":[{"title":"Get style guides","openapi":"openapi.json get /styleguides","href":"/api-reference/styleguides/get-styleguides"},{"openapi":"openapi.json post /styleguides","title":"Create a style guide","href":"/api-reference/styleguides/create-styleguides"},{"openapi":"openapi.json patch /styleguides","title":"Update a style guide","href":"/api-reference/styleguides/patch-styleguides"},{"openapi":"openapi.json post /styleguides/rules","title":"Create style guide rules","href":"/api-reference/styleguides/create-styleguide-rules"},{"openapi":"openapi.json patch /styleguides/rules","title":"Update style guide rules","href":"/api-reference/styleguides/patch-styleguide-rules"},{"openapi":"openapi.json delete /styleguides/rules","title":"Delete style guide rules","href":"/api-reference/styleguides/delete-styleguide-rules"}]},{"group":"Text Items","pages":[{"openapi":"openapi.json get /textItems","title":"Fetch text items","href":"/api-reference/text-items/get-text-items"},{"openapi":"openapi.json get /textItems/export","title":"Export text items","href":"/api-reference/text-items/export-text-items"},{"openapi":"openapi.json post /textItems","title":"Create text items","href":"/api-reference/text-items/create-text-items"},{"openapi":"openapi.json patch /textItems","title":"Update text items","href":"/api-reference/text-items/patch-text-items"},{"openapi":"openapi.json put /textItems","title":"Update text items","href":"/api-reference/text-items/update-text-items"},{"openapi":"openapi.json delete /textItems","title":"Delete text items","href":"/api-reference/text-items/delete-text-items"},{"openapi":"openapi.json post /textItems/linkFigmaNodes","title":"Link Figma nodes to text items","href":"/api-reference/text-items/link-figma-nodes"}]},{"group":"Variables","pages":[{"openapi":"openapi.json get /variables","title":"Fetch variables","href":"/api-reference/variables/get-variables"},{"openapi":"openapi.json post /variables","title":"Create variables","href":"/api-reference/variables/create-variables"},{"openapi":"openapi.json patch /variables","title":"Update variables","href":"/api-reference/variables/patch-variables"},{"openapi":"openapi.json delete /variables","title":"Delete variables","href":"/api-reference/variables/delete-variables"}]},{"group":"Variants","pages":[{"openapi":"openapi.json get /variants","title":"Fetch variants","description":"Returns a list of the variants in the workspace.","href":"/api-reference/variants/get-variants"},{"openapi":"openapi.json post /variants","title":"Create variants","href":"/api-reference/variants/create-variants"},{"openapi":"openapi.json patch /variants","title":"Update variants","description":"Updates one or more variants in the workspace, identified by their current developer IDs.\n\nOnly provided fields are modified. The whole batch is rejected if any update is invalid.","href":"/api-reference/variants/patch-variants"},{"openapi":"openapi.json delete /variants","title":"Delete variants","href":"/api-reference/variants/delete-variants"}]}]}]},{"group":"String Formats","pages":[{"title":"JSON","icon":"js","href":"/string-formats/json"},{"title":"iOS string formats","sidebarTitle":"iOS Strings","icon":"apple","href":"/string-formats/ios"},{"title":"Android XML string format","sidebarTitle":"Android XML","icon":"android","href":"/string-formats/android"}]},{"group":"MCP Reference","pages":[{"title":"Ditto MCP server overview","sidebarTitle":"Overview","href":"/mcp-reference/overview"},{"title":"Connect the Ditto MCP","sidebarTitle":"Setup","href":"/guides/connect-the-mcp"},{"title":"Ditto MCP tools","sidebarTitle":"Tools","href":"/mcp-reference/tools"},{"title":"Agent instructions","href":"/guides/agent-instructions"}]},{"group":"Ditto Specs CLI","pages":[{"title":"Ditto Specs overview","sidebarTitle":"Overview","href":"/ditto-specs-cli-reference/overview"},{"title":"Ditto Specs CLI setup","sidebarTitle":"Setup","href":"/ditto-specs-cli-reference/setup"},{"title":"Ditto Specs CLI commands","sidebarTitle":"Commands","href":"/ditto-specs-cli-reference/commands"},{"title":"Ditto Spec Files","sidebarTitle":"Spec files","href":"/ditto-specs-cli-reference/spec-files"},{"title":"Ditto Specs agent skills","sidebarTitle":"Agent skills","href":"/ditto-specs-cli-reference/agent-skills"}]},{"group":"Additional Tools","pages":[{"title":"GitHub PR Review Bot","href":"/additional-tools/github-pr-review-bot"},{"title":"Webhooks","href":"/additional-tools/webhooks"},{"title":"GitHub Action","href":"/additional-tools/gh-action"}]},{"group":"Legacy","pages":[{"group":"API Reference","pages":[{"title":"Legacy API authentication","sidebarTitle":"Authentication","href":"/legacy/api-reference-legacy/authentication"},{"group":"Endpoints","pages":[{"group":"Components","pages":[{"openapi":"openapi-legacy.json get /components","title":"Fetch component text","href":"/legacy/api-reference-legacy/components/fetch-component-text"},{"openapi":"openapi-legacy.json post /components/file","title":"Import components via a file","href":"/legacy/api-reference-legacy/components/import-components-via-a-file"},{"openapi":"openapi-legacy.json put /components","title":"Update component text variant","href":"/legacy/api-reference-legacy/components/update-component-text-variant"}]},{"group":"Component Folders","pages":[{"openapi":"openapi-legacy.json get /component-folders","title":"Fetch component folders","href":"/legacy/api-reference-legacy/components-folders/fetch-component-folders"},{"openapi":"openapi-legacy.json get /component-folders/{api_id}/components","title":"Fetch component text by component folder","href":"/legacy/api-reference-legacy/components-folders/fetch-component-text-by-component-folder"}]},{"group":"Projects","pages":[{"openapi":"openapi-legacy.json get /projects/{id}/components","title":"Fetch component text by project id","href":"/legacy/api-reference-legacy/projects/fetch-component-text-by-project-id"},{"openapi":"openapi-legacy.json get /projects","title":"Fetch projects","href":"/legacy/api-reference-legacy/projects/fetch-projects"},{"openapi":"openapi-legacy.json get /projects/{id}","title":"Fetch text by project id","href":"/legacy/api-reference-legacy/projects/fetch-text-by-project-id"}]},{"group":"Project Folders","pages":[{"openapi":"openapi-legacy.json get /project-folders","title":"Fetch project folders","href":"/legacy/api-reference-legacy/project-folders/fetch-project-folders"},{"openapi":"openapi-legacy.json get /project-folders/{folder_id}/projects","title":"Fetch projects by project folder id","href":"/legacy/api-reference-legacy/project-folders/fetch-projects-by-project-folder-id"}]},{"group":"Variables","pages":[{"openapi":"openapi-legacy.json get /variables","title":"Fetch variables","href":"/legacy/api-reference-legacy/variables/fetch-variables"}]},{"group":"Variants","pages":[{"openapi":"openapi-legacy.json get /variants","title":"Fetch variants","href":"/legacy/api-reference-legacy/variants/fetch-variants"}]}]}]},{"group":"CLI Reference","pages":[{"title":"Legacy CLI installation","sidebarTitle":"Installation","href":"/legacy/cli-reference-legacy/authentication"},{"title":"Legacy CLI configuration","sidebarTitle":"Configuration","href":"/legacy/cli-reference-legacy/configuration"},{"title":"Legacy CLI output files","sidebarTitle":"Files","href":"/legacy/cli-reference-legacy/files"}]},{"title":"Legacy tools","href":"/legacy/legacy-tools"},{"title":"Example apps","href":"/example-apps"}]}]},{"tab":"Feedback \u0026 Support","pages":[{"title":"Feedback \u0026 Support","href":"/feedback-support/feedback-support"}]}]},"title":"Create variants - Ditto","buildId":"dpl_DFJrtvUi8HS5F9nkooKuDJsuD5BM","deploymentId":"dpl_DFJrtvUi8HS5F9nkooKuDJsuD5BM","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-rfhihCWU.js","utils-BmH1XFxk.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-BcNsxPKB.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-BAES3tkd.js","snippetPresets-DCMQBKLP.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-D6l_bzE9.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-BOktbnNh.js","shallow-BCs8SgM7.js","getApiPlaygroundDisplay-DEmW5bJB.js","CodeSnippet-CpZOpB9C.js","CodeSnippets-BOBDqibl.js","Page-D5fEM6aW.js","getPastedJson-DH2JBvmr.js","icon-BBJH-kKh.js","MethodPill-D2Sd5NLC.js","DuplicateIcon-CGgfL2qN.js","createIcon-BKudBBzi.js","DynamicMarkdown-85clUA0i.js","SectionHeading-D0JiMgDx.js","axios-vUo_bRtp.js","Markdown-Cfiy0xZO.js","clsx-rL8ZCCw4.js","lib--scc4DXi.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-aeztFa9U.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-BywkCr5C.js"]}