Create a mapping between an attribute and one of the company’s datasets. The created mapping is
owned by the company and has global scope.
The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows
GET /mappings?source=derived would return for it, in the same shape.
Supports mapping types: cached_mapping, object_mapping, and value_mapping.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
company_id
integer<int64>
required
The id of an existing company
Query Parameters
skip_validation
boolean
Skip validation of the mapping expressions against the query engine. Structural validation of the
request still runs. The flag is enabled by being present; any value is ignored.
Body
application/json
attribute_id
integer
required
The target attribute's ID.
dataset_id
integer
required
The source dataset's ID.
mapping
object
required
Mapping definition for create/update requests. Dependencies are computed server-side and not provided by the client.
Option 1
Option 2
Option 3
Show child attributes
status
enum<string> | null
Status to create the mapping in. Defaults to active when omitted. Narrower than
MappingStatus — a mapping cannot be created already archived.
Available options:
active,
pending,
null
tags
string[] | null
Free-form labels on the mapping. Null and an empty array both mean no tags; nio:-prefixed tags
are reserved for Narrative.
Example:
["nio:rosetta"]
source
enum<string> | null
Optional source for the mapping. Null or omitted defaults to company.
Only company and rosetta_stone are allowed for user-created mappings.
Available options:
company,
rosetta_stone,
null
Response
200 - application/json
Ok
The mapping that was created, plus the derived mappings it unlocks.
attribute_id
integer
required
The target attribute's ID.
created_at
string
required
ISO-8601 timestamp indicating when the mapping was created.
Example:
"2021-08-26T21:06:07.710357Z"
dataset_id
integer
required
The source dataset's ID.
mapping
object
required
Option 1
Option 2
Option 3
Show child attributes
status
enum<string>
required
The status of the mapping.
active - Active mappings can be used
archived - Archived/Deleted mappings - mapping no longer in use
pending - Proposed mappings that are not active
rejected - Proposed mappings the owner turned down
Available options:
active,
archived,
pending,
rejected
updated_at
string
required
ISO-8601 timestamp indicating when the mapping was last updated.
Example:
"2021-08-26T21:06:07.710357Z"
created_by
integer<int64>
required
Unique id from a user who created it.
Example:
20
updated_by
integer<int64>
required
Unique id from a user who updated it.
Example:
20
scope
enum<string>
required
The scope of the mapping.
global - Mappings available to all
private - Company private mappings
Available options:
global,
private
source
enum<string>
required
The source of the mapping.
company - Company private mapping
admin - Admin created/promoted mapping
system - System (Automated/ML) mappings
lineage - Lineage-derived mappings (editable without admin)
rosetta_stone - Rosetta Stone mappings (editable without admin)
derived - Computed on the request from a stored mapping and a derivation rule. Not stored, so it has
no id; listed only when asked for by source
Available options:
company,
admin,
system,
lineage,
rosetta_stone,
derived
derived_mappings
object[]
required
The derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for
it, in the same shape (source: derived, no id, a provenance). Empty when the mapping's attribute is
not the source of any derivation rule, when the mapping was created pending, or when every target
attribute already has an explicit mapping on the dataset.
Show child attributes
id
string<uuid>
Absent on a derived mapping (source: derived), which is computed per request and cannot be fetched or
changed by id.
Example:
"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0"
company_id
integer<int64> | null
The company that owns the mapping. Null for platform-wide mappings.
Example:
345
provenance
object
How a derived mapping was produced. Present only when source is derived.
Free-form labels on the mapping. Null and an empty array both mean no tags; nio:-prefixed tags
are reserved for Narrative.
Example:
["nio:rosetta"]
derived_from
string<uuid> | null
The stored mapping this one was copied from when it was authored (lineage). Unrelated to derivation rules;
see provenance for those. Null when the mapping was authored directly.
Example:
"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0"
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Narrative I/O Knowledge Base","colors":{"primary":"#1438F5","light":"#F4F7FB","dark":"#010A28"},"logo":{"light":"https://mintcdn.com/narrative-07c7a1f7/ia6SQX79O4nc7uYf/logo/banner.png?fit=max\u0026auto=format\u0026n=ia6SQX79O4nc7uYf\u0026q=85\u0026s=99860b25011c79366624a87d1f648861","dark":"https://mintcdn.com/narrative-07c7a1f7/ia6SQX79O4nc7uYf/logo/banner-dark.png?fit=max\u0026auto=format\u0026n=ia6SQX79O4nc7uYf\u0026q=85\u0026s=604f9688855cf1123b9eddfc8a5bf0e5"},"favicon":"https://mintcdn.com/narrative-07c7a1f7/DaYE2y2_p0IkASZU/favicon.svg?fit=max\u0026auto=format\u0026n=DaYE2y2_p0IkASZU\u0026q=85\u0026s=9961047bdb2aaf9298577e1c3e624c24","navbar":{"links":[{"href":"mailto:[email protected]","label":"Support"}],"primary":{"type":"button","label":"Open Narrative","href":"https://app.narrative.io"}},"footer":{"socials":{"github":"https://github.com/narrative-io","linkedin":"https://linkedin.com/company/narrative-io"}},"seo":{"indexing":"navigable"},"integrations":{"fathom":{"siteId":"WELVPSSZ"},"ga4":{"measurementId":"G-27FP7EFNFW"},"cookies":{}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"Release Notes","icon":"clock-rotate-left","href":"/release-notes"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"narrative-07c7a1f7","hasAudioNarration":false,"actualSubdomain":"narrative-07c7a1f7","customDomains":["docs.narrative.io"],"gitSource":{"type":"github","owner":"narrative-io","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true,"agentFeedback":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6b0d42c7dc3d787e20c32976","clientVersion":"0.0.4347","searchFilterCounts":[{"language":"default","tag":"API Documentation","count":233},{"language":"default","tag":"Reference","count":113},{"language":"default","tag":"Connectors","count":112},{"language":"default","tag":"All connectors","count":110},{"language":"default","tag":"Architecture Reference","count":78},{"language":"default","tag":"Agent Conversations","count":65},{"language":"default","tag":"Concepts","count":62},{"language":"default","tag":"Guides","count":59},{"language":"default","tag":"Errors","count":56},{"language":"default","tag":"API reference","count":43}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true,"deflection":{"enabled":true,"email":"[email protected]","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"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":[]}
{"page":{"pagePath":"api-reference/mappings/create-a-mapping","slug":"/api-reference/mappings/create-a-mapping","pageMetadata":{"title":"Create a mapping","description":"Create a mapping between an attribute and one of the company's datasets. The created mapping is\nowned by the company and has `global` scope.\n\nThe response also lists, under `derived_mappings`, the derived mappings the new mapping unlocks: the rows\n`GET /mappings?source=derived` would return for it, in the same shape.\n\nSupports mapping types: `cached_mapping`, `object_mapping`, and `value_mapping`.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mappings/companies/{company_id}","href":"/api-reference/mappings/create-a-mapping","autogeneratedByOpenApi":true},"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 code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_Fragment, {\n children: [_jsxs(_components.p, {\n children: [\"Create a mapping between an attribute and one of the company’s datasets. The created mapping is\\nowned by the company and has \", _jsx(_components.code, {\n children: \"global\"\n }), \" scope.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"The response also lists, under \", _jsx(_components.code, {\n children: \"derived_mappings\"\n }), \", the derived mappings the new mapping unlocks: the rows\\n\", _jsx(_components.code, {\n children: \"GET /mappings?source=derived\"\n }), \" would return for it, in the same shape.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Supports mapping types: \", _jsx(_components.code, {\n children: \"cached_mapping\"\n }), \", \", _jsx(_components.code, {\n children: \"object_mapping\"\n }), \", and \", _jsx(_components.code, {\n children: \"value_mapping\"\n }), \".\"]\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":{"title":"Create a mapping","description":"Create a mapping between an attribute and one of the company's datasets. The created mapping is\nowned by the company and has `global` scope.\n\nThe response also lists, under `derived_mappings`, the derived mappings the new mapping unlocks: the rows\n`GET /mappings?source=derived` would return for it, in the same shape.\n\nSupports mapping types: `cached_mapping`, `object_mapping`, and `value_mapping`.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mappings/companies/{company_id}","href":"/api-reference/mappings/create-a-mapping","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":["/_mintlify/custom/narrative-07c7a1f7/d5d45b2d00effc8b/secure-privacy.js"],"openApiReferenceData":{"operation":{"summary":"Create a mapping","description":"Create a mapping between an attribute and one of the company's datasets. The created mapping is\nowned by the company and has `global` scope.\n\nThe response also lists, under `derived_mappings`, the derived mappings the new mapping unlocks: the rows\n`GET /mappings?source=derived` would return for it, in the same shape.\n\nSupports mapping types: `cached_mapping`, `object_mapping`, and `value_mapping`.","tags":["Mappings"],"parameters":["ab165af3-797a-4caa-ada3-ce9faa8c2c06","bbd0b5eb-49c8-4a2f-b117-8e9218f3118e"],"security":["28d9458d-52c7-48d5-9ed6-b43f436a3312"],"requestBody":"1d8ec177-8a01-43aa-86da-823c9e829fb4","responses":{"200":"bbdcd7eb-81f8-401f-8907-d72db4ad58c3"},"method":"post","type":"path","servers":["c373cfef-d90d-409d-b76b-a55dea8a5d24","94de0478-ac55-41e7-a375-55d1494103a0"],"path":"/mappings/companies/{company_id}","baseUrlOptions":["https://api-dev.narrative.io","https://api.narrative.io"],"title":"Create a mapping","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"ab165af3-797a-4caa-ada3-ce9faa8c2c06":{"in":"path","name":"company_id","schema":{"type":"integer","format":"int64","isRequired":true,"description":"The id of an existing company","uniqueKey":"","typeLabel":"integer\u003cint64>"},"required":true,"description":"The id of an existing company","example":345},"bbd0b5eb-49c8-4a2f-b117-8e9218f3118e":{"in":"query","name":"skip_validation","required":false,"allowEmptyValue":true,"description":"Skip validation of the mapping expressions against the query engine. Structural validation of the\nrequest still runs. The flag is enabled by being present; any value is ignored.","schema":{"type":"boolean","isRequired":false,"description":"Skip validation of the mapping expressions against the query engine. Structural validation of the\nrequest still runs. The flag is enabled by being present; any value is ignored.","uniqueKey":"","typeLabel":"boolean"}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"attribute_id":{"type":"integer","description":"The target attribute's ID.","isRequired":true,"uniqueKey":"attribute_id","typeLabel":"integer"},"dataset_id":{"type":"integer","description":"The source dataset's ID.","isRequired":true,"uniqueKey":"dataset_id","typeLabel":"integer"},"mapping":{"oneOf":[{"type":"object","description":"Mapping definition for create/update requests. Dependencies are computed server-side and not provided by the client.","required":["type","property_mappings"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a type of `object`.","enum":["object_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.0.type","typeLabel":"enum\u003cstring>"},"property_mappings":{"type":"array","description":"`property_mappings` define how a value for each property of the target attribute is constructed from a row of the source dataset.\n\nA mapping must be provided for each of the target attribute's _required_ properties.","items":{"type":"object","properties":{"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].expression","typeLabel":"string"},"path":{"type":"string","description":"A string indicating which property of the target attribute the expression is producing a value for.\n\nE.g. for an attribute with the following type definition;\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"latitude\": {\n \"type\": \"double\"\n },\n \"longitude\": {\n \"type\": \"double\"\n },\n \"location_accuracy\": {\n \"type\": \"object\",\n \"properties\": {\n \"horizontal\": {\n \"type\": \"double\"\n },\n \"vertical\": {\n \"type\": \"double\"\n }\n }\n }\n },\n \"required\": [\n \"latitude\",\n \"longitude\"\n ]\n}\n```\n\nThe possible paths are:\n\n- `latitude`\n- `longitude`\n- `location_accuracy.horizontal`\n- `location_accuracy.vertical`","uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].path","typeLabel":"string"}},"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"mapping.oneOf.0.property_mappings","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"mapping.oneOf.0","typeLabel":"object"},{"type":"object","description":"Mapping definition for create/update requests. Dependencies are computed server-side and not provided by the client.","required":["type","expression"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a primitive type, i.e. one of `array`, `boolean`, `double`, `long`, `string`, or `timestamptz`.","enum":["value_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.1.type","typeLabel":"enum\u003cstring>"},"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","isRequired":true,"uniqueKey":"mapping.oneOf.1.expression","typeLabel":"string"}},"isRequired":true,"uniqueKey":"mapping.oneOf.1","typeLabel":"object"},{"type":"object","description":"Mapping definition for create/update requests. Dependencies are computed server-side and not provided by the client.","required":["type","input_expressions"],"properties":{"type":{"type":"string","enum":["cached_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.2.type","typeLabel":"enum\u003cstring>"},"input_expressions":{"type":"array","minItems":1,"description":"One or more SQL expressions evaluated against the source dataset to build the join key. Multi-column keys are concatenated with a separator at query time, so the cache dataset must populate its `input` column with the equivalent encoding.","items":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","uniqueKey":"mapping.oneOf.2.input_expressions.items.[INDEX]","typeLabel":"string"},"isRequired":true,"uniqueKey":"mapping.oneOf.2.input_expressions","typeLabel":"string[]"}},"isRequired":true,"uniqueKey":"mapping.oneOf.2","typeLabel":"object"}],"isRequired":true,"uniqueKey":"mapping","typeLabel":"object"},"status":{"oneOf":[{"description":"Status to create the mapping in. Defaults to `active` when omitted. Narrower than\n`MappingStatus` — a mapping cannot be created already archived.","type":"string","enum":["active","pending",null],"uniqueKey":"status.oneOf.0","typeLabel":"enum\u003cstring>"},{"description":"Status to create the mapping in. Defaults to `active` when omitted. Narrower than\n`MappingStatus` — a mapping cannot be created already archived.","type":"null","enum":["active","pending",null],"uniqueKey":"status.oneOf.1","typeLabel":"null"}],"uniqueKey":"status","typeLabel":"enum\u003cstring> | null"},"tags":{"oneOf":[{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"array","items":{"type":"string","uniqueKey":"tags.oneOf.0.items.[INDEX]","typeLabel":"string"},"example":["nio:rosetta"],"uniqueKey":"tags.oneOf.0","typeLabel":"string[]"},{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"null","items":{"type":"string"},"example":["nio:rosetta"],"uniqueKey":"tags.oneOf.1","typeLabel":"null"}],"uniqueKey":"tags","typeLabel":"string[] | null"},"source":{"oneOf":[{"type":"string","description":"Optional source for the mapping. Null or omitted defaults to `company`.\nOnly `company` and `rosetta_stone` are allowed for user-created mappings.","enum":["company","rosetta_stone",null],"uniqueKey":"source.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","description":"Optional source for the mapping. Null or omitted defaults to `company`.\nOnly `company` and `rosetta_stone` are allowed for user-created mappings.","enum":["company","rosetta_stone",null],"uniqueKey":"source.oneOf.1","typeLabel":"null"}],"uniqueKey":"source","typeLabel":"enum\u003cstring> | null"}},"required":["attribute_id","dataset_id","mapping"],"example":{"attribute_id":123,"dataset_id":456,"mapping":{"type":"object_mapping","property_mappings":[{"path":"product.brand","expression":"itemBrand"},{"path":"product.category","expression":"itemCategory"},{"path":"product.id.type","expression":"'SKU'"},{"path":"product.id.value","expression":"itemID"}]}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"attribute_id":123,"dataset_id":456,"mapping":{"type":"object_mapping","property_mappings":[{"path":"product.brand","expression":"itemBrand"},{"path":"product.category","expression":"itemCategory"},{"path":"product.id.type","expression":"'SKU'"},{"path":"product.id.value","expression":"itemID"}]}}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"bbdcd7eb-81f8-401f-8907-d72db4ad58c3":{"description":"Ok","content":{"application/json":{"schema":{"type":"object","description":"The mapping that was created, plus the derived mappings it unlocks.","required":["derived_mappings","attribute_id","created_at","dataset_id","mapping","status","updated_at","created_by","updated_by","scope","source"],"example":{"id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","attribute_id":291,"created_at":"2021-12-10T00:00:00Z","dataset_id":3,"mapping":{"type":"value_mapping","expression":"lower(email)","dependencies":{"properties":["email"]}},"status":"active","updated_at":"2021-12-10T00:00:00Z","created_by":1,"updated_by":1,"company_id":100,"scope":"global","source":"company","derived_from":null,"tags":[],"derived_mappings":[{"attribute_id":76,"created_at":"2021-12-10T00:00:00Z","dataset_id":3,"mapping":{"type":"value_mapping","expression":"SHA2(lower(email), 256)","dependencies":{"properties":["email"]}},"status":"active","updated_at":"2021-12-10T00:00:00Z","created_by":1,"updated_by":1,"company_id":100,"scope":"global","source":"derived","provenance":{"source_mapping_id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","source_attribute_id":291,"derivation_path":[42],"lossy":true,"imprecise":false},"tags":[],"derived_from":null}]},"properties":{"attribute_id":{"type":"integer","description":"The target attribute's ID.","isRequired":true,"uniqueKey":"attribute_id","typeLabel":"integer"},"created_at":{"type":"string","description":"ISO-8601 timestamp indicating when the mapping was created.","example":"2021-08-26T21:06:07.710357Z","isRequired":true,"uniqueKey":"created_at","typeLabel":"string"},"dataset_id":{"type":"integer","description":"The source dataset's ID.","isRequired":true,"uniqueKey":"dataset_id","typeLabel":"integer"},"mapping":{"oneOf":[{"type":"object","required":["type","property_mappings"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a type of `object`.","enum":["object_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.0.type","typeLabel":"enum\u003cstring>"},"property_mappings":{"type":"array","description":"`property_mappings` define how a value for each property of the target attribute is constructed from a row of the source dataset.\n\nA mapping must be provided for each of the target attribute's _required_ properties.","items":{"type":"object","required":["path","expression"],"properties":{"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","isRequired":true,"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].expression","typeLabel":"string"},"path":{"type":"string","description":"A string indicating which property of the target attribute the expression is producing a value for.\n\nE.g. for an attribute with the following type definition;\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"latitude\": {\n \"type\": \"double\"\n },\n \"longitude\": {\n \"type\": \"double\"\n },\n \"location_accuracy\": {\n \"type\": \"object\",\n \"properties\": {\n \"horizontal\": {\n \"type\": \"double\"\n },\n \"vertical\": {\n \"type\": \"double\"\n }\n }\n }\n },\n \"required\": [\n \"latitude\",\n \"longitude\"\n ]\n}\n```\n\nThe possible paths are:\n\n- `latitude`\n- `longitude`\n- `location_accuracy.horizontal`\n- `location_accuracy.vertical`","isRequired":true,"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].path","typeLabel":"string"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX].dependencies","typeLabel":"object"}},"uniqueKey":"mapping.oneOf.0.property_mappings.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"mapping.oneOf.0.property_mappings","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"mapping.oneOf.0","typeLabel":"object"},{"type":"object","required":["type","expression"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a primitive type, i.e. one of `array`, `boolean`, `double`, `long`, `string`, or `timestamptz`.","enum":["value_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.1.type","typeLabel":"enum\u003cstring>"},"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","isRequired":true,"uniqueKey":"mapping.oneOf.1.expression","typeLabel":"string"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"mapping.oneOf.1.dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"mapping.oneOf.1.dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"mapping.oneOf.1.dependencies","typeLabel":"object"}},"isRequired":true,"uniqueKey":"mapping.oneOf.1","typeLabel":"object"},{"type":"object","description":"Read shape for cached mappings. See `RawCachedMapping` for create/update requests and the surrounding constraints.","required":["type","cache_dataset_id","input_expressions"],"properties":{"type":{"type":"string","enum":["cached_mapping"],"isRequired":true,"uniqueKey":"mapping.oneOf.2.type","typeLabel":"enum\u003cstring>"},"cache_dataset_id":{"type":"integer","isRequired":true,"uniqueKey":"mapping.oneOf.2.cache_dataset_id","typeLabel":"integer"},"input_expressions":{"type":"array","minItems":1,"items":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","uniqueKey":"mapping.oneOf.2.input_expressions.items.[INDEX]","typeLabel":"string"},"isRequired":true,"uniqueKey":"mapping.oneOf.2.input_expressions","typeLabel":"string[]"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"mapping.oneOf.2.dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"mapping.oneOf.2.dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"mapping.oneOf.2.dependencies","typeLabel":"object"}},"isRequired":true,"uniqueKey":"mapping.oneOf.2","typeLabel":"object"}],"isRequired":true,"uniqueKey":"mapping","typeLabel":"object"},"status":{"type":"string","description":"The status of the mapping.\n * `active` - Active mappings can be used\n * `archived` - Archived/Deleted mappings - mapping no longer in use\n * `pending` - Proposed mappings that are not active\n * `rejected` - Proposed mappings the owner turned down\n","enum":["active","archived","pending","rejected"],"isRequired":true,"uniqueKey":"status","typeLabel":"enum\u003cstring>"},"updated_at":{"type":"string","description":"ISO-8601 timestamp indicating when the mapping was last updated.","example":"2021-08-26T21:06:07.710357Z","isRequired":true,"uniqueKey":"updated_at","typeLabel":"string"},"created_by":{"type":"integer","description":"Unique id from a user who created it.","format":"int64","example":20,"isRequired":true,"uniqueKey":"created_by","typeLabel":"integer\u003cint64>"},"updated_by":{"type":"integer","description":"Unique id from a user who updated it.","format":"int64","example":20,"isRequired":true,"uniqueKey":"updated_by","typeLabel":"integer\u003cint64>"},"scope":{"type":"string","description":"The scope of the mapping.\n * `global` - Mappings available to all\n * `private` - Company private mappings\n","enum":["global","private"],"isRequired":true,"uniqueKey":"scope","typeLabel":"enum\u003cstring>"},"source":{"type":"string","description":"The source of the mapping.\n * `company` - Company private mapping\n * `admin` - Admin created/promoted mapping\n * `system` - System (Automated/ML) mappings\n * `lineage` - Lineage-derived mappings (editable without admin)\n * `rosetta_stone` - Rosetta Stone mappings (editable without admin)\n * `derived` - Computed on the request from a stored mapping and a derivation rule. Not stored, so it has\n no `id`; listed only when asked for by source\n","enum":["company","admin","system","lineage","rosetta_stone","derived"],"isRequired":true,"uniqueKey":"source","typeLabel":"enum\u003cstring>"},"derived_mappings":{"type":"array","description":"The derived mappings the new mapping unlocks: the rows `GET /mappings?source=derived` would return for\nit, in the same shape (`source: derived`, no `id`, a `provenance`). Empty when the mapping's attribute is\nnot the source of any derivation rule, when the mapping was created `pending`, or when every target\nattribute already has an explicit mapping on the dataset.","items":{"type":"object","properties":{"attribute_id":{"type":"integer","description":"The target attribute's ID.","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].attribute_id","typeLabel":"integer"},"created_at":{"type":"string","description":"ISO-8601 timestamp indicating when the mapping was created.","example":"2021-08-26T21:06:07.710357Z","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].created_at","typeLabel":"string"},"dataset_id":{"type":"integer","description":"The source dataset's ID.","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].dataset_id","typeLabel":"integer"},"mapping":{"oneOf":[{"type":"object","required":["type","property_mappings"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a type of `object`.","enum":["object_mapping"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.type","typeLabel":"enum\u003cstring>"},"property_mappings":{"type":"array","description":"`property_mappings` define how a value for each property of the target attribute is constructed from a row of the source dataset.\n\nA mapping must be provided for each of the target attribute's _required_ properties.","items":{"type":"object","required":["path","expression"],"properties":{"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX].expression","typeLabel":"string"},"path":{"type":"string","description":"A string indicating which property of the target attribute the expression is producing a value for.\n\nE.g. for an attribute with the following type definition;\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"latitude\": {\n \"type\": \"double\"\n },\n \"longitude\": {\n \"type\": \"double\"\n },\n \"location_accuracy\": {\n \"type\": \"object\",\n \"properties\": {\n \"horizontal\": {\n \"type\": \"double\"\n },\n \"vertical\": {\n \"type\": \"double\"\n }\n }\n }\n },\n \"required\": [\n \"latitude\",\n \"longitude\"\n ]\n}\n```\n\nThe possible paths are:\n\n- `latitude`\n- `longitude`\n- `location_accuracy.horizontal`\n- `location_accuracy.vertical`","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX].path","typeLabel":"string"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX].dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX].dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX].dependencies","typeLabel":"object"}},"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0.property_mappings","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.0","typeLabel":"object"},{"type":"object","required":["type","expression"],"properties":{"type":{"type":"string","description":"A mapping from a dataset to an attribute with a primitive type, i.e. one of `array`, `boolean`, `double`, `long`, `string`, or `timestamptz`.","enum":["value_mapping"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1.type","typeLabel":"enum\u003cstring>"},"expression":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1.expression","typeLabel":"string"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1.dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1.dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1.dependencies","typeLabel":"object"}},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.1","typeLabel":"object"},{"type":"object","description":"Read shape for cached mappings. See `RawCachedMapping` for create/update requests and the surrounding constraints.","required":["type","cache_dataset_id","input_expressions"],"properties":{"type":{"type":"string","enum":["cached_mapping"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.type","typeLabel":"enum\u003cstring>"},"cache_dataset_id":{"type":"integer","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.cache_dataset_id","typeLabel":"integer"},"input_expressions":{"type":"array","minItems":1,"items":{"type":"string","description":"A raw SQL expression which produces a value from the source dataset for the target primitive attribute type.\n\nE.g. for a source dataset with the following type definition:\n\n```\n{\n \"type\": \"object\",\n \"properties\": {\n \"firstName\": {\n \"type\": \"string\"\n },\n \"lastName\": {\n \"type\": \"string\"\n }\n },\n \"required\": [\n \"lastName\"\n ]\n}\n```\n\n\nValid expressions include:\n\n- Lower casing the first name:\n\n```sql\nlower(firstName)\n```\n\n- Constructing a \"full name\" from the first and last name:\n\n```sql\nconcat_ws(' ', coalesce(firstName, ''), lastName)\n```\n\n- Taking the first initial of the first name if is not null:\n\n```sql\ncase when firstName is not null and char_length(firstName) > 0 then substr(firstName, 1) else null end\n```","uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.input_expressions.items.[INDEX]","typeLabel":"string"},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.input_expressions","typeLabel":"string[]"},"dependencies":{"type":"object","description":"Describes the dataset fields that a mapping expression depends on.","properties":{"properties":{"type":"array","description":"List of dataset field references that the mapping expression uses.","items":{"type":"string","uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.dependencies.properties.items.[INDEX]","typeLabel":"string"},"example":["firstName","lastName"],"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.dependencies.properties","typeLabel":"string[]"}},"example":{"properties":[]},"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2.dependencies","typeLabel":"object"}},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping.oneOf.2","typeLabel":"object"}],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].mapping","typeLabel":"object"},"status":{"type":"string","description":"The status of the mapping.\n * `active` - Active mappings can be used\n * `archived` - Archived/Deleted mappings - mapping no longer in use\n * `pending` - Proposed mappings that are not active\n * `rejected` - Proposed mappings the owner turned down\n","enum":["active","archived","pending","rejected"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].status","typeLabel":"enum\u003cstring>"},"updated_at":{"type":"string","description":"ISO-8601 timestamp indicating when the mapping was last updated.","example":"2021-08-26T21:06:07.710357Z","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].updated_at","typeLabel":"string"},"created_by":{"type":"integer","description":"Unique id from a user who created it.","format":"int64","example":20,"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].created_by","typeLabel":"integer\u003cint64>"},"updated_by":{"type":"integer","description":"Unique id from a user who updated it.","format":"int64","example":20,"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].updated_by","typeLabel":"integer\u003cint64>"},"scope":{"type":"string","description":"The scope of the mapping.\n * `global` - Mappings available to all\n * `private` - Company private mappings\n","enum":["global","private"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].scope","typeLabel":"enum\u003cstring>"},"source":{"type":"string","description":"The source of the mapping.\n * `company` - Company private mapping\n * `admin` - Admin created/promoted mapping\n * `system` - System (Automated/ML) mappings\n * `lineage` - Lineage-derived mappings (editable without admin)\n * `rosetta_stone` - Rosetta Stone mappings (editable without admin)\n * `derived` - Computed on the request from a stored mapping and a derivation rule. Not stored, so it has\n no `id`; listed only when asked for by source\n","enum":["company","admin","system","lineage","rosetta_stone","derived"],"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].source","typeLabel":"enum\u003cstring>"},"id":{"type":"string","description":"Absent on a derived mapping (`source: derived`), which is computed per request and cannot be fetched or\nchanged by id.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","uniqueKey":"derived_mappings.items.[INDEX].id","typeLabel":"string\u003cuuid>"},"company_id":{"oneOf":[{"type":"integer","description":"The company that owns the mapping. Null for platform-wide mappings.","format":"int64","example":345,"uniqueKey":"derived_mappings.items.[INDEX].company_id.oneOf.0","typeLabel":"integer\u003cint64>"},{"type":"null","description":"The company that owns the mapping. Null for platform-wide mappings.","uniqueKey":"derived_mappings.items.[INDEX].company_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"derived_mappings.items.[INDEX].company_id","typeLabel":"integer\u003cint64> | null"},"provenance":{"type":"object","description":"How a derived mapping was produced. Present only when `source` is `derived`.","required":["source_mapping_id","source_attribute_id","derivation_path","lossy","imprecise"],"example":{"source_mapping_id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","source_attribute_id":291,"derivation_path":[42],"lossy":true,"imprecise":false},"properties":{"source_mapping_id":{"type":"string","description":"The stored mapping the derivation was applied to.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].provenance.source_mapping_id","typeLabel":"string\u003cuuid>"},"source_attribute_id":{"type":"integer","description":"The attribute of the source mapping.","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].provenance.source_attribute_id","typeLabel":"integer"},"derivation_path":{"type":"array","minItems":1,"description":"The derivation rules applied, in order, from the source attribute to this mapping's attribute. One\nelement today; longer once derivations chain.","items":{"type":"integer","description":"A derivation rule id, as returned by `GET /derivations/{id}`.","uniqueKey":"derived_mappings.items.[INDEX].provenance.derivation_path.items.[INDEX]","typeLabel":"integer"},"isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].provenance.derivation_path","typeLabel":"integer[]"},"lossy":{"type":"boolean","description":"True when any rule on the path is lossy (the source value cannot be recovered).","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].provenance.lossy","typeLabel":"boolean"},"imprecise":{"type":"boolean","description":"True when any rule on the path is imprecise (the value may differ from ground truth).","isRequired":true,"uniqueKey":"derived_mappings.items.[INDEX].provenance.imprecise","typeLabel":"boolean"}},"uniqueKey":"derived_mappings.items.[INDEX].provenance","typeLabel":"object"},"tags":{"oneOf":[{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"array","items":{"type":"string","uniqueKey":"derived_mappings.items.[INDEX].tags.oneOf.0.items.[INDEX]","typeLabel":"string"},"example":["nio:rosetta"],"uniqueKey":"derived_mappings.items.[INDEX].tags.oneOf.0","typeLabel":"string[]"},{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"null","items":{"type":"string"},"example":["nio:rosetta"],"uniqueKey":"derived_mappings.items.[INDEX].tags.oneOf.1","typeLabel":"null"}],"uniqueKey":"derived_mappings.items.[INDEX].tags","typeLabel":"string[] | null"},"derived_from":{"oneOf":[{"type":"string","description":"The stored mapping this one was copied from when it was authored (lineage). Unrelated to derivation rules;\nsee `provenance` for those. Null when the mapping was authored directly.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","uniqueKey":"derived_mappings.items.[INDEX].derived_from.oneOf.0","typeLabel":"string\u003cuuid>"},{"type":"null","description":"The stored mapping this one was copied from when it was authored (lineage). Unrelated to derivation rules;\nsee `provenance` for those. Null when the mapping was authored directly.","uniqueKey":"derived_mappings.items.[INDEX].derived_from.oneOf.1","typeLabel":"null"}],"uniqueKey":"derived_mappings.items.[INDEX].derived_from","typeLabel":"string\u003cuuid> | null"}},"required":["attribute_id","created_at","dataset_id","mapping","status","updated_at","created_by","updated_by","scope","source"],"example":{"id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a7f0","attribute_id":1,"created_at":"2021-12-10T00:00:00Z","dataset_id":3,"mapping":{"type":"object_mapping","property_mappings":[{"path":"foo","expression":"upper(`US Kennel ID`)","dependencies":{"properties":["US Kennel ID"]}},{"path":"bar.baz.qux","expression":"weight * 10000","dependencies":{"properties":["weight"]}}]},"status":"active","updated_at":"2021-12-10T00:00:01Z","created_by":1,"updated_by":1,"company_id":100,"scope":"global","source":"admin","derived_from":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0"},"uniqueKey":"derived_mappings.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"derived_mappings","typeLabel":"object[]"},"id":{"type":"string","description":"Absent on a derived mapping (`source: derived`), which is computed per request and cannot be fetched or\nchanged by id.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","uniqueKey":"id","typeLabel":"string\u003cuuid>"},"company_id":{"oneOf":[{"type":"integer","description":"The company that owns the mapping. Null for platform-wide mappings.","format":"int64","example":345,"uniqueKey":"company_id.oneOf.0","typeLabel":"integer\u003cint64>"},{"type":"null","description":"The company that owns the mapping. Null for platform-wide mappings.","uniqueKey":"company_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"company_id","typeLabel":"integer\u003cint64> | null"},"provenance":{"type":"object","description":"How a derived mapping was produced. Present only when `source` is `derived`.","required":["source_mapping_id","source_attribute_id","derivation_path","lossy","imprecise"],"example":{"source_mapping_id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","source_attribute_id":291,"derivation_path":[42],"lossy":true,"imprecise":false},"properties":{"source_mapping_id":{"type":"string","description":"The stored mapping the derivation was applied to.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","isRequired":true,"uniqueKey":"provenance.source_mapping_id","typeLabel":"string\u003cuuid>"},"source_attribute_id":{"type":"integer","description":"The attribute of the source mapping.","isRequired":true,"uniqueKey":"provenance.source_attribute_id","typeLabel":"integer"},"derivation_path":{"type":"array","minItems":1,"description":"The derivation rules applied, in order, from the source attribute to this mapping's attribute. One\nelement today; longer once derivations chain.","items":{"type":"integer","description":"A derivation rule id, as returned by `GET /derivations/{id}`.","uniqueKey":"provenance.derivation_path.items.[INDEX]","typeLabel":"integer"},"isRequired":true,"uniqueKey":"provenance.derivation_path","typeLabel":"integer[]"},"lossy":{"type":"boolean","description":"True when any rule on the path is lossy (the source value cannot be recovered).","isRequired":true,"uniqueKey":"provenance.lossy","typeLabel":"boolean"},"imprecise":{"type":"boolean","description":"True when any rule on the path is imprecise (the value may differ from ground truth).","isRequired":true,"uniqueKey":"provenance.imprecise","typeLabel":"boolean"}},"uniqueKey":"provenance","typeLabel":"object"},"tags":{"oneOf":[{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"array","items":{"type":"string","uniqueKey":"tags.oneOf.0.items.[INDEX]","typeLabel":"string"},"example":["nio:rosetta"],"uniqueKey":"tags.oneOf.0","typeLabel":"string[]"},{"description":"Free-form labels on the mapping. Null and an empty array both mean no tags; `nio:`-prefixed tags\nare reserved for Narrative.","type":"null","items":{"type":"string"},"example":["nio:rosetta"],"uniqueKey":"tags.oneOf.1","typeLabel":"null"}],"uniqueKey":"tags","typeLabel":"string[] | null"},"derived_from":{"oneOf":[{"type":"string","description":"The stored mapping this one was copied from when it was authored (lineage). Unrelated to derivation rules;\nsee `provenance` for those. Null when the mapping was authored directly.","format":"uuid","example":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","uniqueKey":"derived_from.oneOf.0","typeLabel":"string\u003cuuid>"},{"type":"null","description":"The stored mapping this one was copied from when it was authored (lineage). Unrelated to derivation rules;\nsee `provenance` for those. Null when the mapping was authored directly.","uniqueKey":"derived_from.oneOf.1","typeLabel":"null"}],"uniqueKey":"derived_from","typeLabel":"string\u003cuuid> | null"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","attribute_id":291,"created_at":"2021-12-10T00:00:00Z","dataset_id":3,"mapping":{"type":"value_mapping","expression":"lower(email)","dependencies":{"properties":["email"]}},"status":"active","updated_at":"2021-12-10T00:00:00Z","created_by":1,"updated_by":1,"company_id":100,"scope":"global","source":"company","derived_from":null,"tags":[],"derived_mappings":[{"attribute_id":76,"created_at":"2021-12-10T00:00:00Z","dataset_id":3,"mapping":{"type":"value_mapping","expression":"SHA2(lower(email), 256)","dependencies":{"properties":["email"]}},"status":"active","updated_at":"2021-12-10T00:00:00Z","created_by":1,"updated_by":1,"company_id":100,"scope":"global","source":"derived","provenance":{"source_mapping_id":"ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0","source_attribute_id":291,"derivation_path":[42],"lossy":true,"imprecise":false},"tags":[],"derived_from":null}]}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"28d9458d-52c7-48d5-9ed6-b43f436a3312":{"BearerAuth":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"BearerAuth"}}},"servers":{"c373cfef-d90d-409d-b76b-a55dea8a5d24":{"url":"https://api-dev.narrative.io"},"94de0478-ac55-41e7-a375-55d1494103a0":{"url":"https://api.narrative.io"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"BearerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"BearerAuth","name":"Authorization"}],"title":"BearerAuth"}]},"originalFileLocation":"https://docs-cdn.narrative.io/api-reference/main/openapi.json"},"subdomain":"narrative-07c7a1f7","siteName":"Narrative I/O Knowledge Base","title":"Create a mapping - Narrative I/O Knowledge Base","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-26T15:43:54.219Z","originalFileLocation":"api-reference/mappings/create-a-mapping.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Create a mapping between an attribute and one of the company\u0026#x27;s datasets. The created mapping is owned by the company and has global scope. The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for it, in the same shape. Supports mapping types: cached_mapping, object_mapping, and value_mapping.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Narrative I/O Knowledge Base\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create a mapping - Narrative I/O Knowledge Base\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create a mapping between an attribute and one of the company\u0026#x27;s datasets. The created mapping is owned by the company and has global scope. The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for it, in the same shape. Supports mapping types: cached_mapping, object_mapping, and value_mapping.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Narrative I/O Knowledge Base\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.narrative.io/api-reference/mappings/create-a-mapping\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://narrative-07c7a1f7.mintlify.site/_mintlify/api/og/v2?division=Mappings\u0026amp;title=Create+a+mapping\u0026amp;description=Create+a+mapping+between+an+attribute+and+one+of+the+company%27s+datasets.+The+created+mapping+is%0Aowned+by+the+company+and+has+%60global%60+scope.%0A%0AThe+response+also+\u0026amp;theme=ea22b67648b2d3a364e0af75\u0026amp;signature=b9f1727def75cf2bfd7bf911b7a151d2a56f8a8c21a85b1c86874299ba5838d7\">\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 a mapping - Narrative I/O Knowledge Base\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create a mapping between an attribute and one of the company\u0026#x27;s datasets. The created mapping is owned by the company and has global scope. The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for it, in the same shape. Supports mapping types: cached_mapping, object_mapping, and value_mapping.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://narrative-07c7a1f7.mintlify.site/_mintlify/api/og/v2?division=Mappings\u0026amp;title=Create+a+mapping\u0026amp;description=Create+a+mapping+between+an+attribute+and+one+of+the+company%27s+datasets.+The+created+mapping+is%0Aowned+by+the+company+and+has+%60global%60+scope.%0A%0AThe+response+also+\u0026amp;theme=ea22b67648b2d3a364e0af75\u0026amp;signature=b9f1727def75cf2bfd7bf911b7a151d2a56f8a8c21a85b1c86874299ba5838d7\">\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/narrative-07c7a1f7/OOk68seBU2ePTAv6/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Narrative I/O Knowledge Base\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#1438F5\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.narrative.io/api-reference/mappings/create-a-mapping\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/mappings/create-a-mapping.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.narrative.io/#organization\",\"name\":\"Narrative I/O Knowledge Base\",\"url\":\"https://docs.narrative.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/narrative-07c7a1f7/ia6SQX79O4nc7uYf/logo/banner.png?fit=max\u0026auto=format\u0026n=ia6SQX79O4nc7uYf\u0026q=85\u0026s=99860b25011c79366624a87d1f648861\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.narrative.io#website\",\"name\":\"Narrative I/O Knowledge Base\",\"url\":\"https://docs.narrative.io\",\"publisher\":{\"@id\":\"https://docs.narrative.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping#webpage\",\"url\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping\",\"name\":\"Create a mapping\",\"description\":\"Create a mapping between an attribute and one of the company's datasets. The created mapping is owned by the company and has global scope. The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for it, in the same shape. Supports mapping types: cached_mapping, object_mapping, and value_mapping.\",\"dateModified\":\"2026-11-26T15:43:54.219Z\",\"isPartOf\":{\"@id\":\"https://docs.narrative.io#website\"},\"breadcrumb\":{\"@id\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Mappings\",\"item\":\"https://docs.narrative.io/api-reference/mappings/get-mappings\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create a mapping\",\"item\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping#apireference\",\"headline\":\"Create a mapping\",\"name\":\"Create a mapping\",\"description\":\"Create a mapping between an attribute and one of the company's datasets. The created mapping is owned by the company and has global scope. The response also lists, under derived_mappings, the derived mappings the new mapping unlocks: the rows GET /mappings?source=derived would return for it, in the same shape. Supports mapping types: cached_mapping, object_mapping, and value_mapping.\",\"url\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping\",\"mainEntityOfPage\":{\"@id\":\"https://docs.narrative.io/api-reference/mappings/create-a-mapping#webpage\"},\"dateModified\":\"2026-11-26T15:43:54.219Z\",\"publisher\":{\"@id\":\"https://docs.narrative.io/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.narrative.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Narrative I/O Knowledge Base\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Narrative I/O Knowledge Base\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/mappings/create-a-mapping.md","siteName":"Narrative I/O Knowledge Base","nav":{"global":{"anchors":[{"anchor":"Release Notes","icon":"clock-rotate-left","href":"/release-notes"}]},"tabs":[{"tab":"Getting Started","pages":[{"title":"Getting Started","href":"/getting-started/create-account"}]},{"tab":"Concepts","pages":[{"title":"Concepts","href":"/concepts"}]},{"tab":"Guides","pages":[{"title":"Guides","href":"/guides"}]},{"tab":"Cookbooks","pages":[{"title":"Cookbooks","href":"/cookbooks"}]},{"tab":"Reference","pages":[{"title":"Reference","href":"/reference"}]},{"tab":"Connectors","pages":[{"title":"Connectors","href":"/reference/connectors"}]},{"tab":"NQL","pages":[{"title":"NQL","href":"/nql"}]},{"tab":"API Documentation","groups":[{"group":"Overview","pages":[{"title":"REST API","href":"/api-reference/introduction"}]},{"group":"Access Rules","pages":[{"title":"Get an Access Rule by id (V2)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/access-rules/{access_rule_id}","href":"/api-reference/access-rules/get-an-access-rule-by-id-v2"},{"title":"Update an Access Rule by id (V2)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /v2/access-rules/{access_rule_id}","href":"/api-reference/access-rules/update-an-access-rule-by-id-v2"},{"title":"Delete an access rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/access-rules/{access_rule_id}","href":"/api-reference/access-rules/delete-an-access-rule"},{"title":"Get the query policy of an Access Rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/access-rules/{access_rule_id}/query-policy","href":"/api-reference/access-rules/get-the-query-policy-of-an-access-rule"},{"title":"Set the query policy of an Access Rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /v2/access-rules/{access_rule_id}/query-policy","href":"/api-reference/access-rules/set-the-query-policy-of-an-access-rule"},{"title":"Remove the query policy of an Access Rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/access-rules/{access_rule_id}/query-policy","href":"/api-reference/access-rules/remove-the-query-policy-of-an-access-rule"},{"title":"Get an Access Rule by name (V2)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/access-rules/{company_slug}/{access_rule_name}","href":"/api-reference/access-rules/get-an-access-rule-by-name-v2"},{"title":"Get all accessible Access Rules (V2)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/access-rules","href":"/api-reference/access-rules/get-all-accessible-access-rules-v2"},{"title":"Create a new Access Rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/access-rules","href":"/api-reference/access-rules/create-a-new-access-rule"}]},{"group":"Access Tokens","pages":[{"title":"List Access Tokens","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /access-tokens/tokens","href":"/api-reference/access-tokens/list-access-tokens"},{"title":"Create Access Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /access-tokens/tokens","href":"/api-reference/access-tokens/create-access-token"},{"title":"Get Access Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /access-tokens/tokens/{access_token_id}","href":"/api-reference/access-tokens/get-access-token"},{"title":"Update Access Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /access-tokens/tokens/{access_token_id}","href":"/api-reference/access-tokens/update-access-token"},{"title":"Delete Access Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /access-tokens/tokens/{access_token_id}","href":"/api-reference/access-tokens/delete-access-token"},{"title":"Rotate Access Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /access-tokens/tokens/{access_token_id}/rotate","href":"/api-reference/access-tokens/rotate-access-token"}]},{"group":"Agent Conversations","pages":[{"title":"List the calling user's agent conversations","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /agents/conversations","href":"/api-reference/agent-conversations/list-the-calling-users-agent-conversations"},{"title":"Create an agent conversation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /agents/conversations","href":"/api-reference/agent-conversations/create-an-agent-conversation"},{"title":"Get an agent conversation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /agents/conversations/{id}","href":"/api-reference/agent-conversations/get-an-agent-conversation"},{"title":"List conversation messages (delta read by version cursor)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /agents/conversations/{id}/messages","href":"/api-reference/agent-conversations/list-conversation-messages-delta-read-by-version-cursor"},{"title":"Start a new run on the conversation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /agents/conversations/{id}/runs","href":"/api-reference/agent-conversations/start-a-new-run-on-the-conversation"},{"title":"Stop waiting on a handle","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /agents/conversations/{id}/waitables/{handle}/cancel","href":"/api-reference/agent-conversations/stop-waiting-on-a-handle"},{"title":"Get a run's current state","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /agents/runs/{id}","href":"/api-reference/agent-conversations/get-a-runs-current-state"}]},{"group":"App API","pages":[{"title":"Delivery Commands","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v1/app/commands/delivery","href":"/api-reference/app-api/delivery-commands"},{"title":"Delivery Files","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v1/app/commands/delivery/{delivery_id}/files","href":"/api-reference/app-api/delivery-files"},{"title":"Download file","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v1/app/commands/delivery/{delivery_id}/download/{filename}","href":"/api-reference/app-api/download-file"}]},{"group":"App Invites","pages":[{"title":"List App Invites","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /app-invites","href":"/api-reference/app-invites/list-app-invites"},{"title":"Create App Invite","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /app-invites","href":"/api-reference/app-invites/create-app-invite"},{"title":"Get App Invite","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /app-invites/{id}","href":"/api-reference/app-invites/get-app-invite"},{"title":"Archive App Invite","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /app-invites/{id}","href":"/api-reference/app-invites/archive-app-invite"},{"title":"Activate App Invite","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /app-invites/{id}/activate","href":"/api-reference/app-invites/activate-app-invite"},{"title":"Get App Invite By Code","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /app-invites/codes/{code}","href":"/api-reference/app-invites/get-app-invite-by-code"}]},{"group":"Apps","pages":[{"title":"Lists apps","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps","href":"/api-reference/apps/lists-apps"},{"title":"Publish app event","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /apps/events","href":"/api-reference/apps/publish-app-event"},{"title":"List installed app interfaces","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps/installed/interfaces","href":"/api-reference/apps/list-installed-app-interfaces"},{"title":"List app interfaces","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps/{app_id}/interfaces","href":"/api-reference/apps/list-app-interfaces"},{"title":"Get an app interface","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps/{app_id}/interfaces/{interface_id}","href":"/api-reference/apps/get-an-app-interface"},{"title":"Lists profiles","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps/{app_slug}/profiles","href":"/api-reference/apps/lists-profiles"},{"title":"Get an app's v1 manifest","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /apps/{app_slug}/manifest","href":"/api-reference/apps/get-an-apps-v1-manifest"},{"title":"List Apps","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/apps","href":"/api-reference/apps/list-apps"},{"title":"Create App","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/apps","href":"/api-reference/apps/create-app"},{"title":"Get App","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/apps/{slug}","href":"/api-reference/apps/get-app"},{"title":"Archive App","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/apps/{slug}","href":"/api-reference/apps/archive-app"},{"title":"Replace App Manifest","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /v2/apps/{slug}/manifest","href":"/api-reference/apps/replace-app-manifest"},{"title":"Patch App Manifest","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json patch /v2/apps/{slug}/manifest","href":"/api-reference/apps/patch-app-manifest"},{"title":"Replace App Collaborators","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /v2/apps/{slug}/collaborators","href":"/api-reference/apps/replace-app-collaborators"},{"title":"Generate App Credentials","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/apps/{slug}/credentials/generate","href":"/api-reference/apps/generate-app-credentials"},{"title":"Get Admin App","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/admin/apps/{slug}","href":"/api-reference/apps/get-admin-app"},{"title":"Patch Admin App","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json patch /v2/admin/apps/{slug}","href":"/api-reference/apps/patch-admin-app"}]},{"group":"Attributes","pages":[{"title":"Get attributes","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /attributes","href":"/api-reference/attributes/get-attributes"},{"title":"Create an attribute","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /attributes","href":"/api-reference/attributes/create-an-attribute"},{"title":"Get an attribute","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /attributes/{attribute_name_or_id}","href":"/api-reference/attributes/get-an-attribute"},{"title":"Update an attribute","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /attributes/{attribute_name_or_id}","href":"/api-reference/attributes/update-an-attribute"},{"title":"Delete an attribute","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /attributes/{attribute_name_or_id}","href":"/api-reference/attributes/delete-an-attribute"},{"title":"Get attribute references.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /attributes/{attribute_name_or_id}/references","href":"/api-reference/attributes/get-attribute-references"},{"title":"Get the derivation graph around an attribute.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /attributes/{attribute_name_or_id}/derivation-graph","href":"/api-reference/attributes/get-the-derivation-graph-around-an-attribute"}]},{"group":"Auth","pages":[{"title":"Request or refresh an OAuth token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /oauth/token","href":"/api-reference/auth/request-or-refresh-an-oauth-token"}]},{"group":"Authentication","pages":[{"title":"Sign in with a Stytch B2B session token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/b2b/login","href":"/api-reference/authentication/sign-in-with-a-stytch-b2b-session-token"},{"title":"Register with a Stytch B2B session token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/b2b/register","href":"/api-reference/authentication/register-with-a-stytch-b2b-session-token"},{"title":"Check whether a Stytch B2B member is registered on Narrative","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/b2b/registration-status","href":"/api-reference/authentication/check-whether-a-stytch-b2b-member-is-registered-on-narrative"},{"title":"Exchange a user token for one scoped to another company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/exchange-token","href":"/api-reference/authentication/exchange-a-user-token-for-one-scoped-to-another-company"},{"title":"Sign in with a Stytch session token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/login","href":"/api-reference/authentication/sign-in-with-a-stytch-session-token"},{"title":"Register with a Stytch session token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/register","href":"/api-reference/authentication/register-with-a-stytch-session-token"},{"title":"Check whether a Stytch Magic Links or OAuth user is registered on Narrative","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /authentication/registration-status","href":"/api-reference/authentication/check-whether-a-stytch-magic-links-or-oauth-user-is-registered-on-narrative"}]},{"group":"Billings","pages":[{"title":"Get dataset storage billing","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /admin/billings/dataset-storage-billing","href":"/api-reference/billings/get-dataset-storage-billing"},{"title":"Get dataset storage billing for company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /billings/dataset-storage-billing","href":"/api-reference/billings/get-dataset-storage-billing-for-company"}]},{"group":"Companies","pages":[{"title":"Lists Company Domains","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /companies/{company_id}/domains","href":"/api-reference/companies/lists-company-domains"},{"title":"Get Company Settings","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /companies/{company_id}/settings","href":"/api-reference/companies/get-company-settings"},{"title":"Update Company Settings","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json patch /companies/{company_id}/settings","href":"/api-reference/companies/update-company-settings"},{"title":"Get a presigned URL to upload company logo","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /admin/companies/logo-upload-url","href":"/api-reference/companies/get-a-presigned-url-to-upload-company-logo"}]},{"group":"Company","pages":[{"title":"Get a company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /companies/{company_id}","href":"/api-reference/company/get-a-company"},{"title":"Get a company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /company/{company_id}","href":"/api-reference/company/get-a-company-1"},{"title":"Update a company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /company/{company_id}","href":"/api-reference/company/update-a-company"},{"title":"Delete (archive) a company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /company/{company_id}","href":"/api-reference/company/delete-archive-a-company"},{"title":"Clear the company's default compute pool for a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /company/{company_id}/data-planes/{data_plane_id}/default-compute-pool","href":"/api-reference/company/clear-the-companys-default-compute-pool-for-a-data-plane"},{"title":"Set the company's default compute pool for a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /company/{company_id}/data-planes/{data_plane_id}/default-compute-pool/{compute_pool_id}","href":"/api-reference/company/set-the-companys-default-compute-pool-for-a-data-plane"},{"title":"Update a user","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /users/{user_id}","href":"/api-reference/company/update-a-user"}]},{"group":"Company Marketing Information","pages":[{"title":"Returns the company and user associated with the token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /company-info/whoami","href":"/api-reference/company-marketing-information/returns-the-company-and-user-associated-with-the-token"},{"title":"Get marketing details on a company","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /company-info/{company_id}","href":"/api-reference/company-marketing-information/get-marketing-details-on-a-company"}]},{"group":"Compute Pools","pages":[{"title":"List compute pools","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /data-planes/{data_plane_id}/compute-pools","href":"/api-reference/compute-pools/list-compute-pools"},{"title":"Create a compute pool","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /data-planes/{data_plane_id}/compute-pools","href":"/api-reference/compute-pools/create-a-compute-pool"},{"title":"Get a compute pool by ID","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /data-planes/{data_plane_id}/compute-pools/{compute_pool_id}","href":"/api-reference/compute-pools/get-a-compute-pool-by-id"},{"title":"Update a compute pool","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /data-planes/{data_plane_id}/compute-pools/{compute_pool_id}","href":"/api-reference/compute-pools/update-a-compute-pool"},{"title":"Archive a compute pool","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /data-planes/{data_plane_id}/compute-pools/{compute_pool_id}","href":"/api-reference/compute-pools/archive-a-compute-pool"}]},{"group":"Connections","pages":[{"title":"List connections","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/connections","href":"/api-reference/connections/list-connections"},{"title":"Create a connection","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/connections","href":"/api-reference/connections/create-a-connection"},{"title":"Get a connection","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/connections/{connection_id}","href":"/api-reference/connections/get-a-connection"},{"title":"Archive a connection","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/connections/{connection_id}","href":"/api-reference/connections/archive-a-connection"}]},{"group":"Data Planes","pages":[{"title":"List data planes","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /data-planes","href":"/api-reference/data-planes/list-data-planes"},{"title":"Create a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /data-planes","href":"/api-reference/data-planes/create-a-data-plane"},{"title":"Get a data plane by ID","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /data-planes/{data_plane_id}","href":"/api-reference/data-planes/get-a-data-plane-by-id"},{"title":"Archive a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /data-planes/{data_plane_id}","href":"/api-reference/data-planes/archive-a-data-plane"},{"title":"Update a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json patch /data-planes/{data_plane_id}","href":"/api-reference/data-planes/update-a-data-plane"},{"title":"Data plane heartbeat","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /data-planes/{data_plane_id}/heartbeat","href":"/api-reference/data-planes/data-plane-heartbeat"},{"title":"Trigger a health check","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /data-planes/{data_plane_id}/health-check","href":"/api-reference/data-planes/trigger-a-health-check"},{"title":"Replace the collaborators on a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /data-planes/{data_plane_id}/collaborators","href":"/api-reference/data-planes/replace-the-collaborators-on-a-data-plane"},{"title":"Add a collaborator to a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /data-planes/{data_plane_id}/collaborators/{collaborator_company_id}","href":"/api-reference/data-planes/add-a-collaborator-to-a-data-plane"},{"title":"Remove a collaborator from a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /data-planes/{data_plane_id}/collaborators/{collaborator_company_id}","href":"/api-reference/data-planes/remove-a-collaborator-from-a-data-plane"},{"title":"Set the default compute pool for a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /data-planes/{data_plane_id}/default-compute-pool/{compute_pool_id}","href":"/api-reference/data-planes/set-the-default-compute-pool-for-a-data-plane"},{"title":"Clear the default compute pool for a data plane","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /data-planes/{data_plane_id}/default-compute-pool","href":"/api-reference/data-planes/clear-the-default-compute-pool-for-a-data-plane"}]},{"group":"Dataset Configuration","pages":[{"title":"Preview snapshot expirations","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/retention-policy/preview","href":"/api-reference/dataset-configuration/preview-snapshot-expirations"},{"title":"Upsert retention policies for a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/retention-policy","href":"/api-reference/dataset-configuration/upsert-retention-policies-for-a-dataset"}]},{"group":"Dataset Files","pages":[{"title":"Files added","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/snapshots/{snapshot_id}/files-added","href":"/api-reference/dataset-files/files-added"},{"title":"Find snapshots","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/find-snapshots","href":"/api-reference/dataset-files/find-snapshots"},{"title":"Find files","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/find-files","href":"/api-reference/dataset-files/find-files"},{"title":"Issue file download url","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/snapshots/{snapshot_id}/files-added/{file_id}/download","href":"/api-reference/dataset-files/issue-file-download-url"}]},{"group":"Dataset Refresh","pages":[{"title":"Update the materialized view refresh configuration","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/refresh-schedule","href":"/api-reference/dataset-refresh/update-the-materialized-view-refresh-configuration"},{"title":"Create a refresh schedule for an existing materialized view","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/refresh-schedule","href":"/api-reference/dataset-refresh/create-a-refresh-schedule-for-an-existing-materialized-view"},{"title":"Archive the materialized view refresh configuration","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /datasets/{dataset_id}/refresh-schedule","href":"/api-reference/dataset-refresh/archive-the-materialized-view-refresh-configuration"},{"title":"Run a materialized view refresh now","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/refresh-materialized-view","href":"/api-reference/dataset-refresh/run-a-materialized-view-refresh-now"}]},{"group":"Dataset Samples","pages":[{"title":"Sample a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/sample","href":"/api-reference/dataset-samples/sample-a-dataset"},{"title":"Upload a sample","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/sample","href":"/api-reference/dataset-samples/upload-a-sample"},{"title":"Delete a sample","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /datasets/{dataset_id}/sample","href":"/api-reference/dataset-samples/delete-a-sample"},{"title":"Sample a dataset (Admin)","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/admin/sample","href":"/api-reference/dataset-samples/sample-a-dataset-admin"},{"title":"Request Dataset Sample","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/request-sample","href":"/api-reference/dataset-samples/request-dataset-sample"},{"title":"Sample a dataset and redact the sample","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/datasets/{dataset_id}/request-sample","href":"/api-reference/dataset-samples/sample-a-dataset-and-redact-the-sample"},{"title":"Get a dataset's sample redaction","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/redaction","href":"/api-reference/dataset-samples/get-a-datasets-sample-redaction"},{"title":"Upload a dataset's sample redaction","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/redaction","href":"/api-reference/dataset-samples/upload-a-datasets-sample-redaction"},{"title":"Delete a dataset's sample redaction","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /datasets/{dataset_id}/redaction","href":"/api-reference/dataset-samples/delete-a-datasets-sample-redaction"},{"title":"Sample a dataset with its redaction applied","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/sample/redacted","href":"/api-reference/dataset-samples/sample-a-dataset-with-its-redaction-applied"},{"title":"Sampled Mappings","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/sample/mappings","href":"/api-reference/dataset-samples/sampled-mappings"}]},{"group":"Dataset Statistics","pages":[{"title":"Get Statistics Configuration","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/statistics-configuration","href":"/api-reference/dataset-statistics/get-statistics-configuration"},{"title":"Put Statistics Configuration","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/statistics-configuration","href":"/api-reference/dataset-statistics/put-statistics-configuration"},{"title":"Disable Statistics Configuration","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /datasets/{dataset_id}/statistics-configuration","href":"/api-reference/dataset-statistics/disable-statistics-configuration"}]},{"group":"Datasets","pages":[{"title":"Get datasets","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets","href":"/api-reference/datasets/get-datasets"},{"title":"Create a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets","href":"/api-reference/datasets/create-a-dataset"},{"title":"Get a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}","href":"/api-reference/datasets/get-a-dataset"},{"title":"Update a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}","href":"/api-reference/datasets/update-a-dataset"},{"title":"Delete a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /datasets/{dataset_id}","href":"/api-reference/datasets/delete-a-dataset"},{"title":"Activate a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/activate","href":"/api-reference/datasets/activate-a-dataset"},{"title":"Activate a dataset","deprecated":true,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/activate","href":"/api-reference/datasets/activate-a-dataset-1"},{"title":"Truncate a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/truncate","href":"/api-reference/datasets/truncate-a-dataset"},{"title":"Get admin info for a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/admin","href":"/api-reference/datasets/get-admin-info-for-a-dataset"},{"title":"Update a dataset's partition spec","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/admin/partition-spec","href":"/api-reference/datasets/update-a-datasets-partition-spec"},{"title":"Create Dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/datasets","href":"/api-reference/datasets/create-dataset"},{"title":"Register Dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/datasets/register","href":"/api-reference/datasets/register-dataset"},{"title":"Archive Dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/datasets/{dataset_id}","href":"/api-reference/datasets/archive-dataset"},{"title":"Refresh Materialized View","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/datasets/{dataset_id}/refresh-materialized-view","href":"/api-reference/datasets/refresh-materialized-view"},{"title":"Truncate Dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/datasets/{dataset_id}/truncate","href":"/api-reference/datasets/truncate-dataset"},{"title":"Get dataset statistics","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/stats","href":"/api-reference/datasets/get-dataset-statistics"},{"title":"Get detailed statistics","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/column-stats","href":"/api-reference/datasets/get-detailed-statistics"},{"title":"Create or Update detailed statistics","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /datasets/{dataset_id}/column-stats","href":"/api-reference/datasets/create-or-update-detailed-statistics"},{"title":"Submit recalculation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/column-stats/recalculate","href":"/api-reference/datasets/submit-recalculation"},{"title":"Ingest a file","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/upload","href":"/api-reference/datasets/ingest-a-file"},{"title":"Issue an ingestion token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /datasets/{dataset_id}/upload/token","href":"/api-reference/datasets/issue-an-ingestion-token"},{"title":"List connector interfaces compatible with a dataset","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /datasets/{dataset_id}/interfaces","href":"/api-reference/datasets/list-connector-interfaces-compatible-with-a-dataset"}]},{"group":"Derivations","pages":[{"title":"Get derivation rules","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /derivations","href":"/api-reference/derivations/get-derivation-rules"},{"title":"Create a derivation rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /derivations","href":"/api-reference/derivations/create-a-derivation-rule"},{"title":"Get a derivation rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /derivations/{derivation_id}","href":"/api-reference/derivations/get-a-derivation-rule"},{"title":"Delete a derivation rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /derivations/{derivation_id}","href":"/api-reference/derivations/delete-a-derivation-rule"},{"title":"Update a derivation rule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json patch /derivations/{derivation_id}","href":"/api-reference/derivations/update-a-derivation-rule"}]},{"group":"Encryption Materials","pages":[{"title":"List encryption materials","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /encryption-materials","href":"/api-reference/encryption-materials/list-encryption-materials"},{"title":"Create an encryption material","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /encryption-materials","href":"/api-reference/encryption-materials/create-an-encryption-material"},{"title":"List decrypted encryption materials","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /encryption-materials/decrypted","href":"/api-reference/encryption-materials/list-decrypted-encryption-materials"},{"title":"Get an encryption material","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /encryption-materials/{encryption_material_id}","href":"/api-reference/encryption-materials/get-an-encryption-material"},{"title":"Update an encryption material","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /encryption-materials/{encryption_material_id}","href":"/api-reference/encryption-materials/update-an-encryption-material"},{"title":"Archive an encryption material","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /encryption-materials/{encryption_material_id}","href":"/api-reference/encryption-materials/archive-an-encryption-material"}]},{"group":"Installations","pages":[{"title":"List Installations","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /installations","href":"/api-reference/installations/list-installations"},{"title":"Create Installation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations","href":"/api-reference/installations/create-installation"},{"title":"Whoami Installation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /installations/whoami","href":"/api-reference/installations/whoami-installation"},{"title":"Get Installation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /installations/{id}","href":"/api-reference/installations/get-installation"},{"title":"Delete Installation","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /installations/{id}","href":"/api-reference/installations/delete-installation"},{"title":"Create Installation Token","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations/{id}/token","href":"/api-reference/installations/create-installation-token"}]},{"group":"Jobs","pages":[{"title":"Get jobs","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /jobs","href":"/api-reference/jobs/get-jobs"},{"title":"Get a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /jobs/{job_id}","href":"/api-reference/jobs/get-a-job"},{"title":"Run a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/run","href":"/api-reference/jobs/run-a-job"},{"title":"Schedule a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/schedule","href":"/api-reference/jobs/schedule-a-job"},{"title":"Complete a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/complete","href":"/api-reference/jobs/complete-a-job"},{"title":"Fail a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/fail","href":"/api-reference/jobs/fail-a-job"},{"title":"Request cancellation of a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/request-cancellation","href":"/api-reference/jobs/request-cancellation-of-a-job"},{"title":"Cancel a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/cancel","href":"/api-reference/jobs/cancel-a-job"},{"title":"Reschedule a job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /jobs/{job_id}/reschedule","href":"/api-reference/jobs/reschedule-a-job"}]},{"group":"Mappings","pages":[{"title":"Get mappings","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mappings","href":"/api-reference/mappings/get-mappings"},{"title":"Get mapping","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mappings/{mapping_id}","href":"/api-reference/mappings/get-mapping"},{"title":"Update a mapping","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /mappings/{mapping_id}","href":"/api-reference/mappings/update-a-mapping"},{"title":"Delete a mapping","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /mappings/{mapping_id}","href":"/api-reference/mappings/delete-a-mapping"},{"title":"Get mappings for a company","description":"Return the mappings owned by a specific company based on its id, in every status (including\n`archived` and `rejected`). Optionally filter by attribute, dataset, source and/or the dataset field the\nmapping depends on. `source=derived` adds the derived mappings the company's `active` mappings imply, each\nwith a `provenance` and no `id`; the attribute, dataset and field filters apply to them too.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mappings/companies/{company_id}","href":"/api-reference/mappings/get-mappings-for-a-company"},{"title":"Create a mapping","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mappings/companies/{company_id}","href":"/api-reference/mappings/create-a-mapping"},{"title":"Get mapping preview","description":"Returns sampled dataset after attribute mapping for a given `mapping_id`\n\nThis endpoint should be used when mapping exist.\n\nA response is a list of JSON objects, where every object will have an `input` field, that represents the original key/value pairs from the dataset, and the `output` filed that will contain mapped fields where the key will be `attribute name`, and value will be JSON object of key/value pairs.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mappings/{mapping_id}/sample","href":"/api-reference/mappings/get-mapping-preview"},{"title":"Test Mapping","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mappings/test","href":"/api-reference/mappings/test-mapping"}]},{"group":"MCP Connections","pages":[{"title":"List the calling user's external MCP connections","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mcp-connections","href":"/api-reference/mcp-connections/list-the-calling-users-external-mcp-connections"},{"title":"Begin connecting an external MCP server","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mcp-connections","href":"/api-reference/mcp-connections/begin-connecting-an-external-mcp-server"},{"title":"OAuth redirect target that receives the authorization code","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mcp-connections/callback","href":"/api-reference/mcp-connections/oauth-redirect-target-that-receives-the-authorization-code"},{"title":"Finish connecting an external MCP server","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /mcp-connections/complete","href":"/api-reference/mcp-connections/finish-connecting-an-external-mcp-server"},{"title":"Get one of the calling user's MCP connections","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /mcp-connections/{id}","href":"/api-reference/mcp-connections/get-one-of-the-calling-users-mcp-connections"},{"title":"Delete one of the calling user's MCP connections","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /mcp-connections/{id}","href":"/api-reference/mcp-connections/delete-one-of-the-calling-users-mcp-connections"}]},{"group":"Model Inference","pages":[{"title":"Run model inference","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /model-inference/run","href":"/api-reference/model-inference/run-model-inference"}]},{"group":"Model Training","pages":[{"title":"Fine-tune a model","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /model-training/run","href":"/api-reference/model-training/fine-tune-a-model"},{"title":"Train a classifier","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v1/model-training/train-classifier","href":"/api-reference/model-training/train-a-classifier"}]},{"group":"Models","pages":[{"title":"Get models","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /models","href":"/api-reference/models/get-models"},{"title":"Get a model","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /models/{model_id}","href":"/api-reference/models/get-a-model"},{"title":"Update a model","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /models/{model_id}","href":"/api-reference/models/update-a-model"},{"title":"Archive a model","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /models/{model_id}","href":"/api-reference/models/archive-a-model"}]},{"group":"NQL","pages":[{"title":"Validate an NQL statement","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /nql/validate","href":"/api-reference/nql/validate-an-nql-statement"},{"title":"Simulate an NQL query against access rules","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/nql/simulate","href":"/api-reference/nql/simulate-an-nql-query-against-access-rules"},{"title":"Parse an NQL statement","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /nql/parse","href":"/api-reference/nql/parse-an-nql-statement"},{"title":"Check Name Availability","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /nql/name-availability","href":"/api-reference/nql/check-name-availability"},{"title":"Execute an NQL statement","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v1/nql/execute","href":"/api-reference/nql/execute-an-nql-statement"},{"title":"Get a forecast job","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /nql/{job_id}","href":"/api-reference/nql/get-a-forecast-job"}]},{"group":"Permissions","pages":[{"title":"Create a permission","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /admin/permissions","href":"/api-reference/permissions/create-a-permission"}]},{"group":"Profiles","pages":[{"title":"Returns app profiles","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /installations/{installation_id}/profiles","href":"/api-reference/profiles/returns-app-profiles"},{"title":"Creates an app profile","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations/{installation_id}/profiles","href":"/api-reference/profiles/creates-an-app-profile"},{"title":"Returns profile with {profile_id}","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /installations/{installation_id}/profiles/{app_profile_id}","href":"/api-reference/profiles/returns-profile-with-"},{"title":"Updates an existing app profile","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json put /installations/{installation_id}/profiles/{app_profile_id}","href":"/api-reference/profiles/updates-an-existing-app-profile"},{"title":"Enables a profile","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations/{installation_id}/profiles/{app_profile_id}/enable","href":"/api-reference/profiles/enables-a-profile"},{"title":"Disables a profile","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations/{installation_id}/profiles/{app_profile_id}/disable","href":"/api-reference/profiles/disables-a-profile"},{"title":"Archives a profile","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /installations/{installation_id}/profiles/{app_profile_id}/archive","href":"/api-reference/profiles/archives-a-profile"}]},{"group":"Queries","pages":[{"title":"Get a query by id","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/queries/{query_id}","href":"/api-reference/queries/get-a-query-by-id"},{"title":"Deletes a query","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /v2/queries/{query_id}","href":"/api-reference/queries/deletes-a-query"},{"title":"Get accessible queries","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /v2/queries","href":"/api-reference/queries/get-accessible-queries"},{"title":"Create a query","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/queries","href":"/api-reference/queries/create-a-query"}]},{"group":"Resources","pages":[{"title":"Get buckets","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /resources/buckets","href":"/api-reference/resources/get-buckets"},{"title":"Create bucket","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /resources/buckets","href":"/api-reference/resources/create-bucket"},{"title":"Update access type","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /resources/update-access","href":"/api-reference/resources/update-access-type"}]},{"group":"Schema Inference","pages":[{"title":"Infer the dataset schema of a file passed by multipart file.","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /v2/inference","href":"/api-reference/schema-inference/infer-the-dataset-schema-of-a-file-passed-by-multipart-file"}]},{"group":"Uploads","pages":[{"title":"Upload a file","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /uploads/{upload_path}","href":"/api-reference/uploads/upload-a-file"}]},{"group":"Usage","pages":[{"title":"Create a usage event","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /usage","href":"/api-reference/usage/create-a-usage-event"}]},{"group":"Webhooks","pages":[{"title":"List webhook subscriptions","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /webhooks","href":"/api-reference/webhooks/list-webhook-subscriptions"},{"title":"Create a webhook subscription","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /webhooks","href":"/api-reference/webhooks/create-a-webhook-subscription"},{"title":"Get a webhook subscription by ID","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /webhooks/{webhook_subscription_id}","href":"/api-reference/webhooks/get-a-webhook-subscription-by-id"},{"title":"Archive a webhook subscription","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /webhooks/{webhook_subscription_id}","href":"/api-reference/webhooks/archive-a-webhook-subscription"},{"title":"Event delivery","version":null,"deprecated":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json webhook webhookDelivery","href":"/api-reference/webhooks/event-delivery"}]},{"group":"Whoami","pages":[{"title":"Get a current user","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /whoami","href":"/api-reference/whoami/get-a-current-user"}]},{"group":"Workflows","pages":[{"title":"List workflows","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /workflows","href":"/api-reference/workflows/list-workflows"},{"title":"Create a workflow","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /workflows","href":"/api-reference/workflows/create-a-workflow"},{"title":"Get a workflow","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /workflows/{workflow_id}","href":"/api-reference/workflows/get-a-workflow"},{"title":"Archive a workflow","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /workflows/{workflow_id}","href":"/api-reference/workflows/archive-a-workflow"},{"title":"Trigger a workflow","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /workflows/{workflow_id}/trigger","href":"/api-reference/workflows/trigger-a-workflow"},{"title":"Schedule a workflow","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /workflows/{workflow_id}/schedule","href":"/api-reference/workflows/schedule-a-workflow"},{"title":"Remove a workflow schedule","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json delete /workflows/{workflow_id}/schedule","href":"/api-reference/workflows/remove-a-workflow-schedule"},{"title":"Cancel a workflow execution","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /workflows/{workflow_id}/cancel","href":"/api-reference/workflows/cancel-a-workflow-execution"},{"title":"List workflow runs","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json get /workflows/{workflow_id}/runs","href":"/api-reference/workflows/list-workflow-runs"},{"title":"Cancel a specific workflow run","deprecated":null,"version":null,"openapi":"https://docs-cdn.narrative.io/api-reference/main/openapi.json post /workflows/{workflow_id}/runs/{run_id}/cancel","href":"/api-reference/workflows/cancel-a-specific-workflow-run"}]}]}]},"basePath":"","title":"Create a mapping - Narrative I/O Knowledge Base","deploymentId":"dpl_6UE2cqB47X6P7P3F2hD3UphW6ijc","buildId":"dpl_6UE2cqB47X6P7P3F2hD3UphW6ijc","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-BMn8tSe3.js","snippetPresets-Dl5ZrD9W.js","utils-CddEzDcs.js","style-to-object-BY3JEAdk.js","utils-Dym31Pnf.js","v4-DIgz8zy6.js","addTypeLabelsToSchema-ZiqR8hPK.js","conditional-requirements-CFM0id0Q.js","cloneDeep-D3fPbylz.js","_Uint8Array-BcNtDki0.js","isObject-FP1Yky1u.js","ApiExamples-4Sf3CFhl.js","usePlaygroundInputsStore-Ck91l6q0.js","shallow-DapBSR9G.js","isEqual-Clu_sGzx.js","CodeSnippets-DAVHdSX2.js","CodeSnippet-Be6AcO_D.js","use-playground-group-access-CteWws2O.js","Page-_aL_PM_2.js","api-description-markdown-BPoPkVJQ.js","DynamicMarkdown-QJ7LkRm3.js","SectionHeading-DyxPTJti.js","MethodPill-CGjK-dNY.js","getPastedJson-C4YIGTOJ.js","Check2Icon-B7COpIZE.js","axios-CsQoIw0U.js","Markdown-Bquzb4Gw.js","AssistantPageLink-wSgGy_i5.js","dist-Bg48sGSz.js","lib-DMeTj1gb.js","lib-B8HbPgcC.js","katex-Dbtb6Wk7.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js"]}