Can't running Vue example
Preflight checklist
- [X] I could not find a solution in the existing issues, docs, nor discussions.
- [X] I agree to follow this project's Code of Conduct.
- [X] I have read and am following this repository's Contribution Guidelines.
- [ ] This issue affects my Ory Network project.
- [ ] I have joined the Ory Community Slack.
- [ ] I am signed up to the Ory Security Patch Newsletter.
Describe the bug
I follwed this tutorial step by step: https://www.ory.sh/docs/getting-started/integrate-auth/vue
but I can't get my Vue app running correctly:
Uncaught runtime errors:
ERROR
Request failed with status code 401
at createError (webpack-internal:///./node_modules/@ory/client/node_modules/axios/lib/core/createError.js:16:15)
at settle (webpack-internal:///./node_modules/@ory/client/node_modules/axios/lib/core/settle.js:17:12)
at XMLHttpRequest.onloadend (webpack-internal:///./node_modules/@ory/client/node_modules/axios/lib/adapters/xhr.js:49:7)
Is this a ory/client error?
Reproducing the bug
Follow the tutorial: https://www.ory.sh/docs/getting-started/integrate-auth/vue
Relevant log output
createError.js:16 Uncaught (in promise) Error: Request failed with status code 401
at createError (createError.js:16:1)
at settle (settle.js:17:1)
at XMLHttpRequest.onloadend (xhr.js:54:1)
Relevant configuration
No response
Version
"@ory/client": "^1.1.33"
On which operating system are you observing this issue?
None
In which environment are you deploying?
None
Additional Context
No response
The error is most likely coming from ory.toSession().then(({ data }).
Have you tried running the example directly from https://github.com/ory/docs/tree/master/code-examples/protect-page-login/ ?
Thank you, with that code it seems to work! What was the problem?
I don't know! The code in the docs page is the same as in the repository