MongoDB数据API无效的会话错误与Postman和Python

发布于 2025-02-09 01:51:35 字数 1170 浏览 0 评论 0原文

我正在尝试通过使用Postman使用数据API在MongoDB数据库中更新/发布到我的文档,我遵循所有步骤并填写所有基本变量,并且始终遇到该错误。

无效的会话:错误查找端点用户

,这表明我成功将MongoDB数据API分配给了我的Postman集合,并填写了所有必要的变量。

第一个图像 - 邮政变量

这是我在我的数据库中找到文档(同样的确切错误不断显示所有其他端点,更新,插入等…)

second simage-请求和发生的错误

,这些是请求的标题和主体,表明变量已正确设置,并且请求毫无问题地进行,但是我每次都会收到相同的错误。

第三张图像 - 请求的标题和正文

所以我认为这可能是邮政事务的东西试图使用Python提出请求,而我在那里也有同样的错误。

第四映像 - python请求

这是我试图将请求发送到的文档。

第五映像 - mongodb compass中的数据库

,这是我的数据api游戏,所有群集都是设置和访问阅读和写作。

第六个映像 - mongodb data api api api page

所以我不确定是什么我没看到吗?

I’m trying to Update/Post to my documents in a MongoDB database through using the Data API via postman, I followed all the steps and filled in all the essential variables and I consistently get that error.

invalid session: error finding user for endpoint

Here it shows that I successfully forked the MongoDB Data API to my Postman collection and filled in all the necessary variables.

First Image - Postman Variables

This is me making the POST request to find a document in my database (this same exact error keeps on showing with all the other endpoints, update, insert, etc…)

Second Image - The Request And The Occurring Error

And these are the header and body of the request showing that the variables were correctly setup and the the request is going through with no problems but I get that same error every time.

Third Image - Header and Body of The Request

So I figured it might be a postman thing so I tried to make the request using Python instead and I got the same exact error there too.

Fourth Image - Python Request

This is the document I am trying to send the requests to.

Fifth Image - The database in MongoDB Compass

And this is my Data API game with the cluster all being setup and given access for both reading and writing.

Sixths Image - The MongoDB Data API Page

So I am not sure what is exactly going on or what am I not seeing.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文