Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.
Introduction
In this guide, you’ll learn how to integrate AWS Cognito authentication with a
Cube deployment. If you already have a pre-existing Cognito User Pool in AWS
that you’d like to re-use, please skip ahead to
Configure Cube.
To add custom claims to the JWT, you will need to associate a Lambda
function to the Pre Token Generation event
trigger available on your User Pool.First, go to the AWS Lambda Console and create new a Lambda function:
Then navigate to the Amazon Cognito User Pools Console, select Triggers from the
left sidebar and associate the Lambda function you created previously:
Now we’re ready to configure Cube to use AWS Cognito. Go to your Cube project
and open the .env file and add the following, replacing the values wrapped in
<>.
OIDC Client ID: Retrieve from App Client settings page in AWS Cognito User
Pool Console
OIDC Client Secret: Retrieve from App Client settings page in AWS Cognito
User Pool Console
Click ‘Use Discovery Document’ to auto-fill the remaining values, then click
Save.
If you haven’t already, go back to the AWS Cognito App Client’s settings and add
https://openidconnect.net/callback to the list of allowed callback URLs.
Now click Start; and in a separate tab, go to the App Client’s settings page and
click the Launch Hosted UI button.
If the login is successful, you should be redirected to the OpenID Connect
Playground. Click on the Exchange button to exchange the code for your tokens:
Click Next, and continue on to the next section and click the Verify button to
verify the JWT signature as well as decode the identity token:
Set JWT in Developer Playground
Now open the Developer Playground (at http://localhost:4000) and on the Build
page, click Add Security Context.
Click the Token tab, paste the id_token from OpenID Playground and click the
Save button.
Close the popup and use the Developer Playground to make a request. Any data
models using the Security Context should now work as expected.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Cube Documentation","colors":{"primary":"#5339CF","light":"#A5A3FF","dark":"#716EEE"},"logo":{"light":"https://mintcdn.com/cubed3/wCTntgEXVYYYnx4l/logo/light.svg?fit=max\u0026auto=format\u0026n=wCTntgEXVYYYnx4l\u0026q=85\u0026s=8bbf45ba64eac6116629064fac55aad7","dark":"https://mintcdn.com/cubed3/wCTntgEXVYYYnx4l/logo/dark.svg?fit=max\u0026auto=format\u0026n=wCTntgEXVYYYnx4l\u0026q=85\u0026s=d8fa230950c8c63b3c2f88d2768694d0"},"favicon":"https://mintcdn.com/cubed3/wCTntgEXVYYYnx4l/favicon.svg?fit=max\u0026auto=format\u0026n=wCTntgEXVYYYnx4l\u0026q=85\u0026s=3b0cb7aa770d2abd546ef19463fbba8c","navbar":{"links":[{"href":"https://cube.dev/demos","label":"Demos"},{"href":"https://cube.dev/changelog","label":"Changelog"},{"href":"https://slack.cube.dev","label":"Community"}],"primary":{"type":"button","label":"Get Started","href":"https://cubecloud.dev/auth/signup"}},"footer":{"socials":{"x":"https://x.com/the_cube_dev","github":"https://github.com/cube-js/cube","linkedin":"https://www.linkedin.com/company/cube-dev"},"links":[{"header":"Legal","items":[{"label":"Privacy Policy","href":"https://cube.dev/legal/privacy-policy"},{"label":"Cookie Preferences","href":"#cookie-preferences"}]}]},"seo":{"metatags":{"og:type":"website","og:site_name":"Cube Documentation"},"indexing":"navigable"},"icons":{"library":"tabler"},"styling":{"codeblocks":"dark","latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"cubed3","hasAudioNarration":false,"actualSubdomain":"cubed3","customDomains":["docs.cube.dev"],"gitSource":{"type":"github","owner":"cube-js","repo":"cube","deployBranch":"master","contentDirectory":"docs-mintlify","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aff77fbb5f9972b85a20c09","clientVersion":"0.0.4227","searchFilterCounts":[{"language":"default","tag":"API","count":238},{"language":"default","tag":"Platform Endpoints","count":231},{"language":"default","tag":"Documentation","count":101},{"language":"default","tag":"Admin","count":95},{"language":"default","tag":"Data Modeling","count":65},{"language":"default","tag":"Recipes","count":47},{"language":"default","tag":"Topics","count":47},{"language":"default","tag":"Reference","count":44},{"language":"default","tag":"Connect to data","count":31},{"language":"default","tag":"Explore \u0026 Analyze","count":30}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":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":"workos-onboarding","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":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#content-area table,.mdx-content table{width:100%!important}.cube-consent{position:fixed;right:16px;bottom:16px;z-index:2147483000;box-sizing:border-box;display:flex;flex-direction:column;gap:8px;width:min(440px, calc(100vw - 32px));padding:16px;background:#fff;color:#111827;border:1px solid #e5e7eb;border-radius:8px;box-shadow:0 8px 24px rgb(0 0 0 / 12%);font-size:14px;line-height:1.5}html.dark .cube-consent{background:#111318;color:#f3f4f6;border-color:#2b2f38}.cube-consent__title{margin:0;padding-right:24px;font-size:16px;font-weight:600}.cube-consent__text,.cube-consent__status{margin:0;color:#4b5563}html.dark .cube-consent__text,html.dark .cube-consent__status{color:#b6bcc8}.cube-consent__link{color:inherit;text-decoration:underline}.cube-consent__actions{display:flex;gap:8px}.cube-consent__button{flex:1;padding:8px 16px;border:1px solid #111827;border-radius:6px;background:#111827;color:#fff;font:inherit;font-weight:500;cursor:pointer}html.dark .cube-consent__button{border-color:#f3f4f6;background:#f3f4f6;color:#111318}.cube-consent__button:hover{opacity:0.88}.cube-consent__button:focus-visible,.cube-consent__close:focus-visible,.cube-consent__link:focus-visible{outline:2px solid #111827;outline-offset:2px}html.dark .cube-consent :focus-visible{outline-color:#f3f4f6}.cube-consent__close{position:absolute;top:8px;right:8px;width:24px;height:24px;padding:0;border:0;background:transparent;color:inherit;font-size:20px;line-height:1;cursor:pointer}"}]}
{"page":{"pagePath":"embedding/authentication/aws-cognito","slug":"/embedding/authentication/aws-cognito","pageMetadata":{"title":"Authenticate requests to Cube with AWS Cognito","sidebarTitle":"AWS Cognito","description":"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.","href":"/embedding/authentication/aws-cognito"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,OptimizedImage,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`introduction`,children:`Introduction`}),`\n`,_jsxs(_components.p,{children:[`In this guide, you’ll learn how to integrate AWS Cognito authentication with a\nCube deployment. If you already have a pre-existing Cognito User Pool in AWS\nthat you’d like to re-use, please skip ahead to\n`,_jsx(_components.a,{href:`#configure-cube`,children:`Configure Cube`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`create-and-configure-a-user-pool`,children:`Create and configure a User Pool`}),`\n`,_jsxs(_components.p,{children:[`If you haven’t already created a User Pool, please follow `,_jsx(_components.a,{href:`https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pools-app-integration.html#cognito-user-pools-create-an-app-integration`,children:`the instructions in\nthe AWS Cognito documentation`}),` to create one, along\nwith enabling the Hosted UI.`]}),`\n`,_jsx(Heading,{level:`3`,id:`custom-claims`,children:`Custom claims`}),`\n`,_jsxs(_components.p,{children:[`To add custom claims to the JWT, you will need to associate `,_jsx(_components.a,{href:`https://docs.aws.amazon.com/lambda/latest/dg/welcome.html`,children:`a Lambda\nfunction`}),` to the `,_jsx(_components.a,{href:`https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-lambda-pre-token-generation.html`,children:`Pre Token Generation event\ntrigger`}),` available on your User Pool.`]}),`\n`,_jsx(_components.p,{children:`First, go to the AWS Lambda Console and create new a Lambda function:`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/2545ca40-ff29-476b-8068-3f7119c13e08/`,style:{border:`none`},width:`80%`})}),`\n`,_jsx(_components.p,{children:`Add the following code to the Lambda function:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`15`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`15`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#4EC9B0`,\"--shiki-dark\":`#4EC9B0`},children:`exports`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:`handler`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` = (`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`event`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`context`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`callback`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` event`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`response`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` = {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` claimsOverrideDetails:`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` claimsToAddOrOverride:`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"http://localhost:4000/\"`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#4FC1FF`,\"--shiki-dark\":`#4FC1FF`},children:` JSON`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:`stringify`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` company_id:`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"company1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` user_id:`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` event`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`request`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`userAttributes`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` roles:`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` })`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` `})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:` callback`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`null`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`event`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Then navigate to the Amazon Cognito User Pools Console, select Triggers from the\nleft sidebar and associate the Lambda function you created previously:`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/42dc3c26-9574-4d69-a029-2914bacf7c9b/`,style:{border:`none`},width:`80%`})}),`\n`,_jsxs(_components.p,{children:[`You can find more examples of `,_jsx(_components.a,{href:`https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-lambda-pre-token-generation.html#aws-lambda-triggers-pre-token-generation-example-1`,children:`modifying claims in JWTs\nhere`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`configure-cube`,children:`Configure Cube`}),`\n`,_jsxs(_components.p,{children:[`Now we’re ready to configure Cube to use AWS Cognito. Go to your Cube project\nand open the `,_jsx(_components.code,{children:`.env`}),` file and add the following, replacing the values wrapped in\n`,_jsx(_components.code,{children:`\u003c>`}),`.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`dotenv`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`dotenv`,children:_jsxs(_components.code,{language:`dotenv`,numberOfLines:`5`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`CUBEJS_JWK_URL`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`=https://cognito-idp.\u003cAWS_REGION>.amazonaws.com/\u003cUSER_POOL_ID>/.well-known/jwks.json`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`CUBEJS_JWT_AUDIENCE`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`=\u003cAPPLICATION_URL>`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`CUBEJS_JWT_ISSUER`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`=https://cognito-idp.\u003cAWS_REGION>.amazonaws.com/\u003cUSER_POOL_ID>`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`CUBEJS_JWT_ALGS`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`=RS256`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`CUBEJS_JWT_CLAIMS_NAMESPACE`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`=\u003cCLAIMS_NAMESPACE>`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`testing-with-the-developer-playground`,children:`Testing with the Developer Playground`}),`\n`,_jsx(Heading,{level:`3`,id:`retrieving-a-jwt`,children:`Retrieving a JWT`}),`\n`,_jsxs(_components.p,{children:[`Go to the `,_jsx(_components.a,{href:`https://openidconnect.net/`,children:`OpenID Playground from Auth0`}),` to and click\nConfiguration.`]}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/a40aaeba-1a16-426c-b8a0-8e2be23572e2/`,style:{border:`none`},width:`80%`})}),`\n`,_jsx(_components.p,{children:`Change the Server Template to Custom, and enter the following values:`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/bdbbc8ab-0274-479c-aae3-98507722d0b7/`,style:{border:`none`},width:`80%`})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Discovery Document URL`}),`:\n`,_jsx(_components.code,{children:`https://cognito-idp.\u003cAWS_REGION>.amazonaws.com/\u003cUSER_POOL_ID>/.well-known/openid-configuration`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`OIDC Client ID`}),`: Retrieve from App Client settings page in AWS Cognito User\nPool Console`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`OIDC Client Secret`}),`: Retrieve from App Client settings page in AWS Cognito\nUser Pool Console`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`Click ‘Use Discovery Document’ to auto-fill the remaining values, then click\nSave.`}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`If you haven’t already, go back to the AWS Cognito App Client’s settings and add\n`,_jsx(_components.code,{children:`https://openidconnect.net/callback`}),` to the list of allowed callback URLs.`]})}),`\n`,_jsx(_components.p,{children:`Now click Start; and in a separate tab, go to the App Client’s settings page and\nclick the Launch Hosted UI button.`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/fdeda9b5-d00e-4236-baf7-1a026bce942a/`,style:{border:`none`},width:`80%`})}),`\n`,_jsx(_components.p,{children:`If the login is successful, you should be redirected to the OpenID Connect\nPlayground. Click on the Exchange button to exchange the code for your tokens:`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/38c9c14f-6825-4dc6-8d24-847fb3f17c95/`,style:{border:`none`},width:`80%`})}),`\n`,_jsx(_components.p,{children:`Click Next, and continue on to the next section and click the Verify button to\nverify the JWT signature as well as decode the identity token:`}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/a7dd0870-f4ce-410a-88a4-40a5c42ee835/`,style:{border:`none`},width:`80%`})}),`\n`,_jsx(Heading,{level:`3`,id:`set-jwt-in-developer-playground`,children:`Set JWT in Developer Playground`}),`\n`,_jsxs(_components.p,{children:[`Now open the Developer Playground (at `,_jsx(_components.code,{children:`http://localhost:4000`}),`) and on the Build\npage, click Add Security Context.`]}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/f63817d8-9729-4b7f-a36c-02518de422e9/`,style:{border:`none`},width:`80%`})}),`\n`,_jsxs(_components.p,{children:[`Click the Token tab, paste the `,_jsx(_components.code,{children:`id_token`}),` from OpenID Playground and click the\nSave button.`]}),`\n`,_jsx(`div`,{style:{textAlign:`center`},children:_jsx(OptimizedImage,{src:`https://ucarecdn.com/892b39e7-4d57-4dba-957a-dad8ec34fe68/`,style:{border:`none`},width:`80%`})}),`\n`,_jsxs(_components.p,{children:[`Close the popup and use the Developer Playground to make a request. Any data\nmodels using the `,_jsx(_components.a,{href:`/docs/data-modeling/access-control/context`,children:`Security Context`}),` should now work as expected.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"dark","config":{},"pageMetadata":{"title":"Authenticate requests to Cube with AWS Cognito","sidebarTitle":"AWS Cognito","description":"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.","href":"/embedding/authentication/aws-cognito"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Introduction","slug":"introduction","depth":2,"children":[]},{"title":"Create and configure a User Pool","slug":"create-and-configure-a-user-pool","depth":2,"children":[{"title":"Custom claims","slug":"custom-claims","depth":3,"children":[]}]},{"title":"Configure Cube","slug":"configure-cube","depth":2,"children":[]},{"title":"Testing with the Developer Playground","slug":"testing-with-the-developer-playground","depth":2,"children":[{"title":"Retrieving a JWT","slug":"retrieving-a-jwt","depth":3,"children":[]},{"title":"Set JWT in Developer Playground","slug":"set-jwt-in-developer-playground","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/cubed3/73c42f6b43b9b3b0/scripts/extract-chat.js","/_mintlify/custom/cubed3/08d502537a7bd0d7/scripts/extract-core-data.js","/_mintlify/custom/cubed3/476a9fa93e98d93b/consent.js"],"subdomain":"cubed3","siteName":"Cube Documentation","title":"Authenticate requests to Cube with AWS Cognito - Cube Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-04-01T14:53:29.852Z","originalFileLocation":"embedding/authentication/aws-cognito.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=\"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Cube Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_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/cubed3/JtLYPWhDFrYGSK8W/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Authenticate requests to Cube with AWS Cognito - Cube Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Cube Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.cube.dev/embedding/authentication/aws-cognito\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://cubed3.mintlify.site/_mintlify/api/og/v2?division=Authentication\u0026amp;title=Authenticate+requests+to+Cube+with+AWS+Cognito\u0026amp;description=Step-by-step+wiring+of+AWS+Cognito+User+Pools+and+Hosted+UI+to+Cube%2C+including+optional+Lambda+hooks+for+custom+JWT+claims.\u0026amp;theme=6d1e003873cec4de62649d7c\u0026amp;signature=2b2f8f8dc3ee62429432c18c0db54f60176a4931180c2a8d6413e96a260f7956\">\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=\"Authenticate requests to Cube with AWS Cognito - Cube Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://cubed3.mintlify.site/_mintlify/api/og/v2?division=Authentication\u0026amp;title=Authenticate+requests+to+Cube+with+AWS+Cognito\u0026amp;description=Step-by-step+wiring+of+AWS+Cognito+User+Pools+and+Hosted+UI+to+Cube%2C+including+optional+Lambda+hooks+for+custom+JWT+claims.\u0026amp;theme=6d1e003873cec4de62649d7c\u0026amp;signature=2b2f8f8dc3ee62429432c18c0db54f60176a4931180c2a8d6413e96a260f7956\">\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/cubed3/JtLYPWhDFrYGSK8W/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Cube Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#5339CF\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.cube.dev/embedding/authentication/aws-cognito\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/embedding/authentication/aws-cognito.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.cube.dev/#organization\",\"name\":\"Cube Documentation\",\"url\":\"https://docs.cube.dev\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/cubed3/wCTntgEXVYYYnx4l/logo/light.svg?fit=max\u0026auto=format\u0026n=wCTntgEXVYYYnx4l\u0026q=85\u0026s=8bbf45ba64eac6116629064fac55aad7\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.cube.dev#website\",\"name\":\"Cube Documentation\",\"url\":\"https://docs.cube.dev\",\"publisher\":{\"@id\":\"https://docs.cube.dev/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.cube.dev/embedding/authentication/aws-cognito#webpage\",\"url\":\"https://docs.cube.dev/embedding/authentication/aws-cognito\",\"name\":\"Authenticate requests to Cube with AWS Cognito\",\"description\":\"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\",\"dateModified\":\"2026-04-01T14:53:29.852Z\",\"isPartOf\":{\"@id\":\"https://docs.cube.dev#website\"},\"breadcrumb\":{\"@id\":\"https://docs.cube.dev/embedding/authentication/aws-cognito#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.cube.dev/embedding/authentication/aws-cognito#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Using Core Data APIs\",\"item\":\"https://docs.cube.dev/embedding/authentication/jwt\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Authentication\",\"item\":\"https://docs.cube.dev/embedding/authentication/jwt\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Authenticate requests to Cube with AWS Cognito\",\"item\":\"https://docs.cube.dev/embedding/authentication/aws-cognito\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.cube.dev/embedding/authentication/aws-cognito#article\",\"headline\":\"Authenticate requests to Cube with AWS Cognito\",\"name\":\"Authenticate requests to Cube with AWS Cognito\",\"description\":\"Step-by-step wiring of AWS Cognito User Pools and Hosted UI to Cube, including optional Lambda hooks for custom JWT claims.\",\"url\":\"https://docs.cube.dev/embedding/authentication/aws-cognito\",\"mainEntityOfPage\":{\"@id\":\"https://docs.cube.dev/embedding/authentication/aws-cognito#webpage\"},\"dateModified\":\"2026-04-01T14:53:29.852Z\",\"publisher\":{\"@id\":\"https://docs.cube.dev/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.cube.dev#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Cube Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Cube Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/embedding/authentication/aws-cognito.md","siteName":"Cube Documentation","nav":{"global":null,"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/docs/introduction"}]},{"tab":"Admin","pages":[{"title":"Admin","href":"/admin/connect-to-data"}]},{"tab":"Embedding","groups":[{"group":"Embedding","pages":[{"title":"Overview","href":"/embedding"},{"title":"React Embed SDK","href":"/embedding/react-embed-sdk"}]},{"group":"Iframe embedding","pages":[{"title":"Dashboards","href":"/embedding/iframe/dashboards"},{"title":"Analytics Chat","href":"/embedding/iframe/analytics-chat"},{"title":"Creator Mode","href":"/embedding/iframe/creator-mode"},{"title":"Show and hide features","href":"/embedding/iframe/feature-visibility"},{"title":"Customization","href":"/embedding/iframe/customization"},{"title":"Localization","href":"/embedding/iframe/localization"},{"title":"Time zones","href":"/embedding/iframe/time-zones"},{"title":"Events \u0026 actions","href":"/embedding/iframe/events"},{"group":"Authentication","pages":[{"title":"Private embedding","href":"/embedding/iframe/auth/private"},{"title":"Signed embedding","href":"/embedding/iframe/auth/signed"}]}]},{"group":"Using Core Data APIs","pages":[{"group":"Authentication","pages":[{"title":"JSON Web Token authentication","href":"/embedding/authentication/jwt"},{"title":"Security context","href":"/embedding/authentication/security-context"},{"title":"Authenticate requests to Cube with Auth0","sidebarTitle":"Auth0","description":"Step-by-step Auth0 application and API setup, rules for enriching JWTs with claims, and Cube configuration for Auth0-issued tokens.","href":"/embedding/authentication/auth0"},{"title":"Authenticate requests to Cube with AWS Cognito","sidebarTitle":"AWS Cognito","href":"/embedding/authentication/aws-cognito"}]},{"title":"Multitenancy","description":"Reference for tenant-aware Cube configuration—per-tenant drivers, schemas, repositories, refresh, and query rewrite driven by security context.","href":"/embedding/multitenancy"}]}]},{"tab":"Reference","pages":[{"title":"Reference","href":"/reference/data-modeling/cube"}]},{"tab":"Cube Core","pages":[{"title":"Cube Core","href":"/cube-core"}]},{"tab":"Recipes","pages":[{"title":"Recipes","href":"/recipes"}]},{"tab":"API","pages":[{"title":"API","href":"/api-reference/introduction"}]}]},"basePath":"","title":"Authenticate requests to Cube with AWS Cognito - Cube Documentation","deploymentId":"dpl_vSEmv961Ncyvz1psVwgUnTXQMSYk","buildId":"dpl_vSEmv961Ncyvz1psVwgUnTXQMSYk","dynamics":["a74be98ba7"],"chunks":["zoom-image-lightbox-BguUeq2N.js","lightbox-handle-r17bVUz3.js"]}