Dav*_*ano 5 authentication typescript supabase
signInWithPassword除了使用 React、TypeScript 和 Supabase之外,所有身份验证功能均有效。
我的背景:它允许我signIn创建个人资料并继续前进。我可以getUser()在登录后在会话期间进行操作。我signOut也可以。
但当我signInWithPassword它告诉我
当我将链接放入浏览器时,它显示:{“message”:“在请求中找不到 API 密钥”,“提示”:“找不到apikey请求标头或网址参数。”}
怎么了?
这是“未处理的服务器错误”错误
Log ID
2035d09a-e63c-451c-bc66-8386e50ebc42
Log Timestamp (UTC)
2022-11-20T23:10:56.481Z
Log Event Message
{"auth_event":{"action":"login","actor_id":"7888064c-0f26-4e88-9016-c8fe5c16e64e","actor_username":"*********","log_type":"account","traits":{"provider":"email"}},"component":"api","error":"write tcp 127.0.0.1:9999-\u003e127.0.0.1:50512: write: connection reset by peer","level":"error","method":"POST","msg":"Unhandled server error: write tcp 127.0.0.1:9999-\u003e127.0.0.1:50512: write: connection reset by peer","path":"/token","referer":"https://myintent.netlify.app/","remote_addr":"67.167.57.19","time":"2022-11-20T23:10:56Z","timestamp":"2022-11-20T23:10:56Z"}
Log Metadata
[
{
"__MONOTONIC_TIMESTAMP": null,
"CODE_FUNC": null,
"status": null,
"_CMDLINE": null,
"method": null,
"_SYSTEMD_CGROUP": null,
"CODE_FILE": null,
"EXECUTABLE": null,
"_EXE": null,
"UNIT": null,
"level": null,
"_COMM": null,
"duration": null,
"_LINE_BREAK": null,
"_SOURCE_REALTIME_TIMESTAMP": null,
"_UID": null,
"host": "db-sorcthuycbkwhrnjbntk",
"PRIORITY": null,
"_CAP_EFFECTIVE": null,
"_PID": null,
"INVOCATION_ID": null,
"_SYSTEMD_UNIT": null,
"source_type": "journald",
"SYSLOG_FACILITY": null,
"request_id": null,
"CODE_LINE": null,
"path": null,
"component": null,
"project": "sorcthuycbkwhrnjbntk",
"referer": null,
"remote_addr": null,
"_SYSTEMD_SLICE": null,
"_SYSTEMD_INVOCATION_ID": null,
"_MACHINE_ID": null,
"_TRANSPORT": null,
"_SELINUX_CONTEXT": null,
"MESSAGE_ID": null,
"__REALTIME_TIMESTAMP": null,
"_STREAM_ID": null,
"_GID": null,
"_BOOT_ID": null,
"SYSLOG_IDENTIFIER": null
}
]
Run Code Online (Sandbox Code Playgroud)
我尝试确保process.env设置正确,其中 url 和 anonKeys 都以 REACT_APP 前缀存储。没有改变。
我尝试通过仅使用电子邮件登录来使用signInWithOtp。当我单击电子邮件中的链接时,它会将我带到一个页面,其中显示:
{ "message":"从上游服务器收到无效响应" }
我遇到了同样的错误
{"message":"No API key found in request","hint":"No apikey request header or url param was found."}
当我在 Supabase Web 面板中错误配置重定向 URL 时。在下面Authentication > URL Configuration > Site URL,我已经列出了manifund.com,但它需要如此https://manifund.com。