POST /api/pipelines/:pipeline_uuid/blocksCreate a new block in one or more pipelines.
string
required
Human readable block name. This is used to generate the UUID, e.g. restless dust. Names will be slugified to a safe-uuid.
string
required
Type of block:
callback, chart, conditional, custom, data_exporter, data_loader, dbt, extension, global_data_product, markdown, scratchpad, sensor, transformer
string
Block color displayed by the frontend for custom blocks. All other block types have predefined colors.
object
An optional parameter specifying a block configuration file For example, {data_source: "s3"} will create an s3 data loader.
object
Miscellaneous configuration settings for the block.
Show properties
string
Database or data warehouse for the SQL block to connect to.
string
Database name to use when saving the output of the SQL block.
string
Profile target for the dbt block.
string
Schema name to use when saving the output of the SQL block.
string
Table name to use when saving the output of the SQL block.
string
Whether to replace the existing table of the SQL block output, append, or
raise an error and fail.
string
Toggle writing raw SQL in the block. Read more here.
string
The content of block formatted as a string. Use /n for newlines. Omitting will create an empty block.
string
UUID of extensions, currently Great Expectations is the only extension supported.
string
The block language:
python, sql, r, yaml, markdown
[string]
Array of strings containing the pipeline uuids for which the block is a member.
integer
The 0-indexed position of the block in the pipeline, e.g. 0 is the first block location.
[string]
An array of strings representing the uuids of upstream blocks (the blocks on which the new block depends). For example, ["a", "b"] will create a block that depends on blocks a and b.
string
The unique id of the block. This is generated from name, so it’s not necessary to populate this field.
{"docsConfig":{"$schema":"https://mintlify.com/docs.json","theme":"mint","name":"Mage","colors":{"primary":"#7E53F8","light":"#BFA8FF","dark":"#4C22C0"},"favicon":"/favicon.png","logo":{"light":"https://mintcdn.com/mage-staging/F-coujhKYsL8TShc/logo/light.svg?fit=max\u0026auto=format\u0026n=F-coujhKYsL8TShc\u0026q=85\u0026s=771e75dc9069a1ba245e251f78951bcd","dark":"https://mintcdn.com/mage-staging/F-coujhKYsL8TShc/logo/dark.svg?fit=max\u0026auto=format\u0026n=F-coujhKYsL8TShc\u0026q=85\u0026s=8d66f112b5ad4b8007c46ea8cee832da"},"api":{"playground":{"display":"none"}},"background":{"image":"https://mintlify.s3.us-west-1.amazonaws.com/mage-staging/background.png","decoration":null,"color":{"light":null,"dark":"#121212"}},"navbar":{"primary":{"type":"github","href":"https://github.com/mage-ai/mage-ai"}},"search":{"prompt":"✨ Make magic..."},"seo":{"metatags":{"og:image":"https://github.com/mage-ai/mage-ai/blob/master/docs/og.png?raw=True","og:description":"Mage is an open-source, hybrid framework for transforming and integrating data. Our docs are the best place to learn about making magical data pipelines.","og:site_name":"Mage Docs","twitter:site":"@mage_ai"},"indexing":"navigable"},"footer":{"socials":{"linkedin":"https://www.linkedin.com/company/magetech/","twitter":"https://twitter.com/mage_ai","facebook":"https://www.facebook.com/mageai","instagram":"https://www.instagram.com/mage_ai/","github":"https://www.github.com/mage-ai"}},"integrations":{"amplitude":{"apiKey":"b3c3b09423fea2abaae92c08b44de1c3"}},"navigation":{"global":{"anchors":[{"anchor":"Releases","href":"https://docs.mage.ai/about/releases","icon":"megaphone"},{"anchor":"Roadmap","href":"https://docs.mage.ai/about/roadmap","icon":"map"},{"anchor":"Troubleshooting","href":"https://docs.mage.ai/development/troubleshooting","icon":"question"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"mage-staging","hasAudioNarration":false,"actualSubdomain":"mage-staging","customDomains":[],"gitSource":{"type":"github","owner":"mage-ai","repo":"mage-ai","deployBranch":"docs-dev","contentDirectory":"docs","mountPath":"","label":""},"feedback":{"thumbs":true,"edits":true,"issues":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6ae91d067d088452a25a2aa4:success","clientVersion":"0.0.4344","searchFilterCounts":[{"language":"default","tag":"Docs","count":142},{"language":"default","tag":"Concepts","count":99},{"language":"default","tag":"Reference","count":58},{"language":"default","tag":"Deploy","count":40},{"language":"default","tag":"Configuration","count":31},{"language":"default","tag":"API","count":30},{"language":"default","tag":"Blocks","count":29},{"language":"default","tag":"Get Started","count":29},{"language":"default","tag":"Streaming","count":27},{"language":"default","tag":"Endpoints","count":26}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","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":"site-roles","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":"treatment","enabled":true,"payload":{"type":"string","value":"treatment"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[{"filePath":"_css/main.css","content":"img{max-height:450px;display:block;margin-left:auto;margin-right:auto}"}]}
{"page":{"pagePath":"api-reference/blocks/create-block","slug":"/api-reference/blocks/create-block","pageMetadata":{"title":"Create block","api":"POST /api/pipelines/:pipeline_uuid/blocks","description":null,"href":"/api-reference/blocks/create-block"},"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`,..._provideComponents(),...props.components},{Expandable,ParamField,ResponseField}=_components;if(!Expandable)_missingMdxReference(`Expandable`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:_jsx(_components.code,{children:`POST /api/pipelines/:pipeline_uuid/blocks`})}),`\n`,_jsx(_components.p,{children:`Create a new block in one or more pipelines.`}),`\n`,_jsx(ParamField,{query:`name`,type:`string`,required:true,id:`param-name`,children:_jsxs(_components.p,{children:[`Human readable block name. This is used to generate the UUID, e.g. `,_jsx(_components.code,{children:`restless dust`}),`. Names will be slugified to a safe-uuid.`]})}),`\n`,_jsx(ParamField,{query:`type`,type:`string`,required:true,id:`param-type`,children:_jsxs(_components.p,{children:[`Type of block:\n`,_jsx(_components.code,{children:`callback`}),`, `,_jsx(_components.code,{children:`chart`}),`, `,_jsx(_components.code,{children:`conditional`}),`, `,_jsx(_components.code,{children:`custom`}),`, `,_jsx(_components.code,{children:`data_exporter`}),`, `,_jsx(_components.code,{children:`data_loader`}),`, `,_jsx(_components.code,{children:`dbt`}),`, `,_jsx(_components.code,{children:`extension`}),`, `,_jsx(_components.code,{children:`global_data_product`}),`, `,_jsx(_components.code,{children:`markdown`}),`, `,_jsx(_components.code,{children:`scratchpad`}),`, `,_jsx(_components.code,{children:`sensor`}),`, `,_jsx(_components.code,{children:`transformer`})]})}),`\n`,_jsx(ParamField,{query:`color`,type:`string`,id:`param-color`,children:_jsxs(_components.p,{children:[`Block color displayed by the frontend for `,_jsx(_components.code,{children:`custom`}),` blocks. All other block types have predefined colors.`]})}),`\n`,_jsx(ParamField,{query:`config`,type:`object`,id:`param-config`,children:_jsxs(_components.p,{children:[`An optional parameter specifying a block configuration file For example, `,_jsx(_components.code,{children:`{data_source: \"s3\"}`}),` will create an s3 data loader.`]})}),`\n`,_jsxs(ResponseField,{name:`configuration`,type:`object`,id:`param-configuration`,children:[_jsx(_components.p,{children:`Miscellaneous configuration settings for the block.`}),_jsxs(Expandable,{title:`properties`,children:[_jsx(ResponseField,{name:`data_provider`,type:`string`,id:`param-data-provider`,children:_jsx(_components.p,{children:`Database or data warehouse for the SQL block to connect to.`})}),_jsx(ResponseField,{name:`data_provider_database`,type:`string`,id:`param-data-provider-database`,children:_jsx(_components.p,{children:`Database name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`data_provider_profile`,type:`string`,id:`param-data-provider-profile`,children:_jsx(_components.p,{children:`Profile target for the dbt block.`})}),_jsx(ResponseField,{name:`data_provider_schema`,type:`string`,id:`param-data-provider-schema`,children:_jsx(_components.p,{children:`Schema name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`data_provider_table`,type:`string`,id:`param-data-provider-table`,children:_jsx(_components.p,{children:`Table name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`export_write_policy`,type:`string`,id:`param-export-write-policy`,children:_jsxs(_components.p,{children:[`Whether to `,_jsx(_components.code,{children:`replace`}),` the existing table of the SQL block output, `,_jsx(_components.code,{children:`append`}),`, or\nraise an error and `,_jsx(_components.code,{children:`fail`}),`.`]})}),_jsx(ResponseField,{name:`use_raw_sql`,type:`string`,id:`param-use-raw-sql`,children:_jsxs(_components.p,{children:[`Toggle writing raw SQL in the block. Read more `,_jsx(_components.a,{href:`/guides/blocks/sql-blocks#using-raw-sql`,children:`here`}),`.`]})})]})]}),`\n`,_jsx(ParamField,{query:`content`,type:`string`,id:`param-content`,children:_jsxs(_components.p,{children:[`The content of block formatted as a string. Use `,_jsx(_components.code,{children:`/n`}),` for newlines. Omitting will create an empty block.`]})}),`\n`,_jsx(ParamField,{query:`extension_uuid`,type:`string`,id:`param-extension-uuid`,children:_jsxs(_components.p,{children:[`UUID of extensions, currently `,_jsx(_components.a,{href:`/development/testing/great-expectations`,children:`Great Expectations`}),` is the only extension supported.`]})}),`\n`,_jsx(ParamField,{query:`language`,type:`string`,id:`param-language`,children:_jsxs(_components.p,{children:[`The block language:\n`,_jsx(_components.code,{children:`python`}),`, `,_jsx(_components.code,{children:`sql`}),`, `,_jsx(_components.code,{children:`r`}),`, `,_jsx(_components.code,{children:`yaml`}),`, `,_jsx(_components.code,{children:`markdown`})]})}),`\n`,_jsx(ParamField,{query:`pipelines`,type:`[string]`,id:`param-pipelines`,children:_jsx(_components.p,{children:`Array of strings containing the pipeline uuids for which the block is a member.`})}),`\n`,_jsx(ParamField,{query:`priority`,type:`integer`,id:`param-priority`,children:_jsx(_components.p,{children:`The 0-indexed position of the block in the pipeline, e.g. 0 is the first block location.`})}),`\n`,_jsx(ParamField,{query:`upstream_blocks`,type:`[string]`,id:`param-upstream-blocks`,children:_jsxs(_components.p,{children:[`An array of strings representing the uuids of upstream blocks (the blocks on which the new block depends). For example, `,_jsx(_components.code,{children:`[\"a\", \"b\"]`}),` will create a block that depends on blocks `,_jsx(_components.code,{children:`a`}),` and `,_jsx(_components.code,{children:`b`}),`.`]})}),`\n`,_jsx(ParamField,{query:`uuid`,type:`string`,id:`param-uuid`,children:_jsxs(_components.p,{children:[`The unique id of the block. This is generated from `,_jsx(_components.code,{children:`name`}),`, so it’s not necessary to populate this field.`]})})]})}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 block","api":"POST /api/pipelines/:pipeline_uuid/blocks","description":null,"href":"/api-reference/blocks/create-block"}}},"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`,..._provideComponents(),...props.components},{CodeBlock,Expandable,ParamField,RequestExample,ResponseExample,ResponseField}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Expandable)_missingMdxReference(`Expandable`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!RequestExample)_missingMdxReference(`RequestExample`,true);if(!ResponseExample)_missingMdxReference(`ResponseExample`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:_jsx(_components.code,{children:`POST /api/pipelines/:pipeline_uuid/blocks`})}),`\n`,_jsx(_components.p,{children:`Create a new block in one or more pipelines.`}),`\n`,_jsx(ParamField,{query:`name`,type:`string`,required:true,id:`param-name`,children:_jsxs(_components.p,{children:[`Human readable block name. This is used to generate the UUID, e.g. `,_jsx(_components.code,{children:`restless dust`}),`. Names will be slugified to a safe-uuid.`]})}),`\n`,_jsx(ParamField,{query:`type`,type:`string`,required:true,id:`param-type`,children:_jsxs(_components.p,{children:[`Type of block:\n`,_jsx(_components.code,{children:`callback`}),`, `,_jsx(_components.code,{children:`chart`}),`, `,_jsx(_components.code,{children:`conditional`}),`, `,_jsx(_components.code,{children:`custom`}),`, `,_jsx(_components.code,{children:`data_exporter`}),`, `,_jsx(_components.code,{children:`data_loader`}),`, `,_jsx(_components.code,{children:`dbt`}),`, `,_jsx(_components.code,{children:`extension`}),`, `,_jsx(_components.code,{children:`global_data_product`}),`, `,_jsx(_components.code,{children:`markdown`}),`, `,_jsx(_components.code,{children:`scratchpad`}),`, `,_jsx(_components.code,{children:`sensor`}),`, `,_jsx(_components.code,{children:`transformer`})]})}),`\n`,_jsx(ParamField,{query:`color`,type:`string`,id:`param-color`,children:_jsxs(_components.p,{children:[`Block color displayed by the frontend for `,_jsx(_components.code,{children:`custom`}),` blocks. All other block types have predefined colors.`]})}),`\n`,_jsx(ParamField,{query:`config`,type:`object`,id:`param-config`,children:_jsxs(_components.p,{children:[`An optional parameter specifying a block configuration file For example, `,_jsx(_components.code,{children:`{data_source: \"s3\"}`}),` will create an s3 data loader.`]})}),`\n`,_jsxs(ResponseField,{name:`configuration`,type:`object`,id:`param-configuration`,children:[_jsx(_components.p,{children:`Miscellaneous configuration settings for the block.`}),_jsxs(Expandable,{title:`properties`,children:[_jsx(ResponseField,{name:`data_provider`,type:`string`,id:`param-data-provider`,children:_jsx(_components.p,{children:`Database or data warehouse for the SQL block to connect to.`})}),_jsx(ResponseField,{name:`data_provider_database`,type:`string`,id:`param-data-provider-database`,children:_jsx(_components.p,{children:`Database name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`data_provider_profile`,type:`string`,id:`param-data-provider-profile`,children:_jsx(_components.p,{children:`Profile target for the dbt block.`})}),_jsx(ResponseField,{name:`data_provider_schema`,type:`string`,id:`param-data-provider-schema`,children:_jsx(_components.p,{children:`Schema name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`data_provider_table`,type:`string`,id:`param-data-provider-table`,children:_jsx(_components.p,{children:`Table name to use when saving the output of the SQL block.`})}),_jsx(ResponseField,{name:`export_write_policy`,type:`string`,id:`param-export-write-policy`,children:_jsxs(_components.p,{children:[`Whether to `,_jsx(_components.code,{children:`replace`}),` the existing table of the SQL block output, `,_jsx(_components.code,{children:`append`}),`, or\nraise an error and `,_jsx(_components.code,{children:`fail`}),`.`]})}),_jsx(ResponseField,{name:`use_raw_sql`,type:`string`,id:`param-use-raw-sql`,children:_jsxs(_components.p,{children:[`Toggle writing raw SQL in the block. Read more `,_jsx(_components.a,{href:`/guides/blocks/sql-blocks#using-raw-sql`,children:`here`}),`.`]})})]})]}),`\n`,_jsx(ParamField,{query:`content`,type:`string`,id:`param-content`,children:_jsxs(_components.p,{children:[`The content of block formatted as a string. Use `,_jsx(_components.code,{children:`/n`}),` for newlines. Omitting will create an empty block.`]})}),`\n`,_jsx(ParamField,{query:`extension_uuid`,type:`string`,id:`param-extension-uuid`,children:_jsxs(_components.p,{children:[`UUID of extensions, currently `,_jsx(_components.a,{href:`/development/testing/great-expectations`,children:`Great Expectations`}),` is the only extension supported.`]})}),`\n`,_jsx(ParamField,{query:`language`,type:`string`,id:`param-language`,children:_jsxs(_components.p,{children:[`The block language:\n`,_jsx(_components.code,{children:`python`}),`, `,_jsx(_components.code,{children:`sql`}),`, `,_jsx(_components.code,{children:`r`}),`, `,_jsx(_components.code,{children:`yaml`}),`, `,_jsx(_components.code,{children:`markdown`})]})}),`\n`,_jsx(ParamField,{query:`pipelines`,type:`[string]`,id:`param-pipelines`,children:_jsx(_components.p,{children:`Array of strings containing the pipeline uuids for which the block is a member.`})}),`\n`,_jsx(ParamField,{query:`priority`,type:`integer`,id:`param-priority`,children:_jsx(_components.p,{children:`The 0-indexed position of the block in the pipeline, e.g. 0 is the first block location.`})}),`\n`,_jsx(ParamField,{query:`upstream_blocks`,type:`[string]`,id:`param-upstream-blocks`,children:_jsxs(_components.p,{children:[`An array of strings representing the uuids of upstream blocks (the blocks on which the new block depends). For example, `,_jsx(_components.code,{children:`[\"a\", \"b\"]`}),` will create a block that depends on blocks `,_jsx(_components.code,{children:`a`}),` and `,_jsx(_components.code,{children:`b`}),`.`]})}),`\n`,_jsx(ParamField,{query:`uuid`,type:`string`,id:`param-uuid`,children:_jsxs(_components.p,{children:[`The unique id of the block. This is generated from `,_jsx(_components.code,{children:`name`}),`, so it’s not necessary to populate this field.`]})}),`\n`,_jsx(RequestExample,{children:_jsx(CodeBlock,{filename:`Request`,numberOfLines:`19`,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:`19`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'http://localhost:6789/api/pipelines/broken_wave/blocks?api_key=zkWlN0PkIKSN0C11CfUHUj84OT5XOJ6tDZ6bDRO2'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`-H `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'Accept: application/json, text/plain, */*'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`-H `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'Authorization: Bearer 018Cc8ydDUa6YWoLad2oMdw0EKdWWJuyg85D02GN1ww'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},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:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`--data-raw `}),_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:` \"block\": {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"name\": \"silent fire\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"priority\": 2,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"configuration\": {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"data_source\": null`})}),`\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:` \"language\": \"python\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"type\": \"data_exporter\"`})}),`\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:` \"api_key\": \"zkWlN0PkIKSN0C11CfUHUj84OT5XOJ6tDZ6bDRO2\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`}`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`--compressed`})}),`\n`]})})})}),`\n`,_jsx(ResponseExample,{children:_jsx(CodeBlock,{filename:`Response`,numberOfLines:`14`,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:`14`,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:` \"block\"`}),_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:` \"content\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`}),_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:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"silent fire\"`}),_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:` \"priority\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`2`}),_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:` \"config\"`}),_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_source\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"language\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"python\"`}),_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:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"data_loader\"`}),_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:` \"configuration\"`}),_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:` \"upstream_blocks\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: []`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})})]})}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 block","api":"POST /api/pipelines/:pipeline_uuid/blocks","description":null,"href":"/api-reference/blocks/create-block"}}}},"mdxExtracts":{"tableOfContents":[],"codeExamples":{"request":{"type":"RequestExample","children":[{"filename":"Request","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=\"19\">\u003cspan class=\"line\">\u003cspan style=\"color:#953800;--shiki-dark:#DCDCAA\">curl\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'http://localhost:6789/api/pipelines/broken_wave/blocks?api_key=zkWlN0PkIKSN0C11CfUHUj84OT5XOJ6tDZ6bDRO2'\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">-H \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'Accept: application/json, text/plain, */*'\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">-H \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'Authorization: Bearer 018Cc8ydDUa6YWoLad2oMdw0EKdWWJuyg85D02GN1ww'\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">-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:#1F2328;--shiki-dark:#D4D4D4\">--data-raw \u003c/span>\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\"> \"block\": {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"name\": \"silent fire\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"priority\": 2,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"configuration\": {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"data_source\": null\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\"> \"language\": \"python\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"type\": \"data_exporter\"\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\"> \"api_key\": \"zkWlN0PkIKSN0C11CfUHUj84OT5XOJ6tDZ6bDRO2\"\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>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">--compressed\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]},"response":{"type":"ResponseExample","children":[{"filename":"Response","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=\"14\">\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\"> \"block\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"content\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\">null\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"name\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"silent fire\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"priority\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">2\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"config\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"data_source\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\">null\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:#116329;--shiki-dark:#9CDCFE\"> \"language\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"python\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"type\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"data_loader\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"configuration\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: {},\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"upstream_blocks\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: []\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]}},"endpoint":{"title":"Create block","path":"/api/pipelines/:pipeline_uuid/blocks","method":"post","request":{"security":[],"parameters":{"query":{"name":{"schema":[{"type":"string","description":"Human readable block name. This is used to generate the UUID, e.g. `restless dust` . Names will be slugified to a safe-uuid.","required":true}]},"type":{"schema":[{"type":"string","description":"Type of block: `callback` , `chart` , `conditional` , `custom` , `data_exporter` , `data_loader` , `dbt` , `extension` , `global_data_product` , `markdown` , `scratchpad` , `sensor` , `transformer`","required":true}]},"color":{"schema":[{"type":"string","description":"Block color displayed by the frontend for `custom` blocks. All other block types have predefined colors."}]},"config":{"schema":[{"type":"object","properties":{},"description":"An optional parameter specifying a block configuration file For example, `{data_source: \"s3\"}` will create an s3 data loader."}]},"content":{"schema":[{"type":"string","description":"The content of block formatted as a string. Use `/n` for newlines. Omitting will create an empty block."}]},"extension_uuid":{"schema":[{"type":"string","description":"UUID of extensions, currently Great Expectations is the only extension supported."}]},"language":{"schema":[{"type":"string","description":"The block language: `python` , `sql` , `r` , `yaml` , `markdown`"}]},"pipelines":{"schema":[{"type":"object","properties":{},"description":"Array of strings containing the pipeline uuids for which the block is a member."}]},"priority":{"schema":[{"type":"integer","description":"The 0-indexed position of the block in the pipeline, e.g. 0 is the first block location."}]},"upstream_blocks":{"schema":[{"type":"object","properties":{},"description":"An array of strings representing the uuids of upstream blocks (the blocks on which the new block depends). For example, `[\"a\", \"b\"]` will create a block that depends on blocks `a` and `b` ."}]},"uuid":{"schema":[{"type":"string","description":"The unique id of the block. This is generated from `name` , so it’s not necessary to populate this field."}]}},"header":{},"cookie":{},"path":{}},"body":{}},"response":{"200":{"application/json":{"schemaArray":[{"type":"object","properties":{"configuration":[{"type":"object","properties":{"data_provider":[{"type":"string","description":"Database or data warehouse for the SQL block to connect to."}],"data_provider_database":[{"type":"string","description":"Database name to use when saving the output of the SQL block."}],"data_provider_profile":[{"type":"string","description":"Profile target for the dbt block."}],"data_provider_schema":[{"type":"string","description":"Schema name to use when saving the output of the SQL block."}],"data_provider_table":[{"type":"string","description":"Table name to use when saving the output of the SQL block."}],"export_write_policy":[{"type":"string","description":"Whether to `replace` the existing table of the SQL block output, `append` , or raise an error and `fail` ."}],"use_raw_sql":[{"type":"string","description":"Toggle writing raw SQL in the block. Read more here ."}]},"description":"Miscellaneous configuration settings for the block."}]}}],"examples":{"example":{"value":{"configuration":{"data_provider":"\u003cstring>","data_provider_database":"\u003cstring>","data_provider_profile":"\u003cstring>","data_provider_schema":"\u003cstring>","data_provider_table":"\u003cstring>","export_write_policy":"\u003cstring>","use_raw_sql":"\u003cstring>"}}}}}}},"deprecated":false}},"jsLinks":[],"subdomain":"mage-staging","siteName":"Mage","title":"Create block - Mage","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-01-06T23:43:56.065Z","originalFileLocation":"api-reference/blocks/create-block.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=\"application-name\" content=\"Mage\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_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/mage-staging/9hbSRsJaqH6uNa8l/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create block - Mage\">\u003cmeta data-mint-head property=\"og:description\" content=\"Mage is an open-source, hybrid framework for transforming and integrating data. Our docs are the best place to learn about making magical data pipelines.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Mage Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://mage-staging.mintlify.app/api-reference/blocks/create-block\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://github.com/mage-ai/mage-ai/blob/master/docs/og.png?raw=True\">\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 block - Mage\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Mage is an open-source, hybrid framework for transforming and integrating data. Our docs are the best place to learn about making magical data pipelines.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://github.com/mage-ai/mage-ai/blob/master/docs/og.png?raw=True\">\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/mage-staging/9hbSRsJaqH6uNa8l/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Mage\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#7E53F8\">\u003clink data-mint-head rel=\"canonical\" href=\"https://mage-staging.mintlify.app/api-reference/blocks/create-block\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/blocks/create-block.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://mage-staging.mintlify.app/#organization\",\"name\":\"Mage\",\"url\":\"https://mage-staging.mintlify.app\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/mage-staging/F-coujhKYsL8TShc/logo/light.svg?fit=max\u0026auto=format\u0026n=F-coujhKYsL8TShc\u0026q=85\u0026s=771e75dc9069a1ba245e251f78951bcd\"}},{\"@type\":\"WebSite\",\"@id\":\"https://mage-staging.mintlify.app#website\",\"name\":\"Mage\",\"url\":\"https://mage-staging.mintlify.app\",\"publisher\":{\"@id\":\"https://mage-staging.mintlify.app/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block#webpage\",\"url\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block\",\"name\":\"Create block\",\"dateModified\":\"2026-01-06T23:43:56.065Z\",\"isPartOf\":{\"@id\":\"https://mage-staging.mintlify.app#website\"},\"breadcrumb\":{\"@id\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Endpoints\",\"item\":\"https://mage-staging.mintlify.app/api-reference/backfills/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Blocks\",\"item\":\"https://mage-staging.mintlify.app/api-reference/blocks/overview\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Create block\",\"item\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block#apireference\",\"headline\":\"Create block\",\"name\":\"Create block\",\"url\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block\",\"mainEntityOfPage\":{\"@id\":\"https://mage-staging.mintlify.app/api-reference/blocks/create-block#webpage\"},\"image\":\"https://github.com/mage-ai/mage-ai/blob/master/docs/og.png?raw=True\",\"dateModified\":\"2026-01-06T23:43:56.065Z\",\"publisher\":{\"@id\":\"https://mage-staging.mintlify.app/#organization\"},\"isPartOf\":{\"@id\":\"https://mage-staging.mintlify.app#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Mage\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Mage\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/blocks/create-block.md","siteName":"Mage","nav":{"global":{"anchors":[{"anchor":"Releases","href":"https://docs.mage.ai/about/releases","icon":"megaphone"},{"anchor":"Roadmap","href":"https://docs.mage.ai/about/roadmap","icon":"map"},{"anchor":"Troubleshooting","href":"https://docs.mage.ai/development/troubleshooting","icon":"question"}]},"tabs":[{"tab":"Docs","pages":[{"title":"Docs","href":"/introduction/overview"}]},{"tab":"Guides","pages":[{"title":"Guides","href":"/guides/overview"}]},{"tab":"API","groups":[{"group":"Get Started","icon":"robot","pages":[{"title":"API overview","icon":"webhook","sidebarTitle":"Overview","href":"/api-reference/overview"},{"group":"Design","icon":"pencil","pages":[{"title":"API resources","sidebarTitle":"Resources","href":"/api-reference/resources"},{"title":"API policies","sidebarTitle":"Policies","href":"/api-reference/policies"},{"title":"API presenters","sidebarTitle":"Presenters","href":"/api-reference/presenters"}]}]},{"group":"Endpoints","icon":"robot","pages":[{"group":"Backfills","icon":"database","pages":[{"title":"Overview","href":"/api-reference/backfills/overview"},{"title":"Read backfills","api":"GET /api/backfills","href":"/api-reference/backfills/read-backfills"},{"title":"Create backfill","api":"POST /api/pipelines/:pipeline_uuid/backfills","href":"/api-reference/backfills/create-backfills"},{"title":"Update backfill","api":"PUT /api/pipelines/:pipeline_uuid/backfills/:backfill_id","href":"/api-reference/backfills/update-backfill"},{"title":"Delete backfill","api":"DELETE /api/backfills/:backfill_id","href":"/api-reference/backfills/delete-backfill"}]},{"group":"Blocks","icon":"block-brick","pages":[{"title":"Overview","href":"/api-reference/blocks/overview"},{"title":"Read block","api":"GET /api/pipelines/:pipeline_uuid/blocks/:block_uuid","description":null,"href":"/api-reference/blocks/read-block"},{"title":"Create block","api":"POST /api/pipelines/:pipeline_uuid/blocks","href":"/api-reference/blocks/create-block"},{"title":"Update block","api":"PUT /api/pipelines/:pipeline_uuid/blocks/:block_uuid","description":null,"href":"/api-reference/blocks/update-block"},{"title":"Delete block","api":"DELETE /api/pipelines/:pipeline_uuid/blocks/:block_uuid","href":"/api-reference/blocks/delete-block"}]},{"group":"Logs","icon":"scroll","pages":[{"title":"Overview","href":"/api-reference/logs/overview"},{"title":"Read logs","api":"GET /api/pipelines/:pipeline_uuid/logs","href":"/api-reference/logs/read-logs"}]},{"group":"OAuth access tokens","icon":"key","pages":[{"title":"Overview","href":"/api-reference/oauth-access-tokens/overview"},{"title":"Read OAuth tokens","sidebarTitle":"Read OAuth tokens","api":"GET /api/oauth_access_tokens","href":"/api-reference/oauth-access-tokens/read-oauth-access-tokens"}]},{"group":"Pipeline runs","icon":"pipe-valve","pages":[{"title":"Overview","href":"/api-reference/pipeline-runs/overview"},{"title":"Read pipeline runs","api":"GET /api/pipeline_schedules/:pipeline_schedule_id/pipeline_runs","href":"/api-reference/pipeline-runs/read-pipeline-runs"},{"title":"Trigger pipeline","api":"POST /api/pipeline_schedules/:pipeline_schedule_id/pipeline_runs/:token","href":"/api-reference/pipeline-runs/trigger-pipeline"}]},{"group":"Pipeline schedules","icon":"pipe-circle-check","pages":[{"title":"Overview","href":"/api-reference/pipeline-schedules/overview"},{"title":"Read pipeline schedules","api":"GET /api/pipelines/:pipeline_uuid/pipeline_schedules","href":"/api-reference/pipeline-schedules/read-pipeline-schedules"}]},{"group":"Pipelines","icon":"pipe-collar","pages":[{"title":"Overview","href":"/api-reference/pipelines/overview"},{"title":"Read pipelines","api":"GET /api/pipelines","href":"/api-reference/pipelines/read-pipeline"},{"title":"Create pipeline","api":"POST /api/pipelines","href":"/api-reference/pipelines/create-pipeline"},{"title":"Update pipeline","api":"PUT /api/pipelines/:uuid","href":"/api-reference/pipelines/update-pipeline"},{"title":"Delete pipeline","api":"DELETE /api/pipelines/:uuid","href":"/api-reference/pipelines/delete-pipeline"}]},{"group":"Sessions","icon":"window","pages":[{"title":"Overview","href":"/api-reference/sessions/overview"},{"title":"Create session","api":"POST /api/sessions","href":"/api-reference/sessions/create-session"}]}]}]},{"tab":"Deploy","pages":[{"title":"Deploy","href":"/production/deploying-to-cloud/architecture"}]},{"tab":"Contribute","pages":[{"title":"Contribute","href":"/contributing/overview"}]},{"tab":"Slack","href":"https://www.mage.ai/chat"}]},"basePath":"","title":"Create block - Mage","deploymentId":"dpl_EwfxjeKENdVkfzdag8rM6mKzcTUJ","buildId":"dpl_EwfxjeKENdVkfzdag8rM6mKzcTUJ","dynamics":["c2aa737661","2b790eda92","b0f84f53ff"],"chunks":["OpenApiReferenceProvider-B8kPdtB2.js","snippetPresets-C-p1aFQ1.js","utils-B9NnUZSZ.js","style-to-object-BY3JEAdk.js","utils-DFxl7cW2.js","v4-DIgz8zy6.js","addTypeLabelsToSchema-bSr9h7OB.js","conditional-requirements-CFM0id0Q.js","cloneDeep-Bw4Gcy_r.js","_Uint8Array-C68x8Gny.js","isObject-FP1Yky1u.js","ApiExamples-BXsp8PHs.js","usePlaygroundInputsStore-BlAOLmIF.js","shallow-C2F02mqa.js","isEqual-C8iG4q2G.js","CodeSnippets-45lHR04X.js","CodeSnippet-6Cemznl-.js","use-playground-group-access-Cyy8SXp5.js","Page-CeZ_ZB5X.js","api-description-markdown-DiOdv5rp.js","DynamicMarkdown-B_9ywLDq.js","SectionHeading-Cc2r-uqU.js","MethodPill-Df3Tcu4c.js","getPastedJson-B3vrV0wE.js","Check2Icon-YQhSFafd.js","axios-CsQoIw0U.js"]}