My server IP is 8.218.240.232. From this server, I can send messages to my Workers via api-gptvip-workers-dev. My Workers are bound to the domain api-chatgptvpn-cn. However, when I try to access my Workers from my server (IP 8.218.240.232) via this domain, I receive a 403 error code. When I switch to other servers (with different IP addresses), I can normally access my Workers through api-chatgptvpn-cn. I would appreciate if a technician could help me resolve this issue. Thank you!( Please replace “-” with “.”)
Are you seeing anything in your WAF events that shows your request being blocked?
[root@iZj6cg9r90i26krocznp0rZ ~]# curl http-s://api-gptvip-workers-dev
{“detail”:“Api works!”}
The domain obtained through Cloudflare shows up correctly, but when using a custom domain, the correct page cannot be accessed.( Please replace “-” with “.”)
[root@iZj6cg9r90i26krocznp0rZ ~]# curl http-s://api-chatgptvpn-cn
Just a moment...Works fine
$ curl https://api.chatgptvpn.cn/ -i
HTTP/2 200
date: Wed, 23 Aug 2023 05:38:19 GMT
content-type: text/plain;charset=UTF-8
content-length: 23
report-to: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=wB9w7dQfimxvTVWXr1QGBK9w8RHwuDxPiz0K2TlSfXgvNyPKdChdMdYCBlwRmQS%2FGNoluPy4OltU6gktSD4CQstJU0dnjmUiq4iBZld8uHuUjvPV1keuiQRuOI6HqgPpgF%2F8DwmGUx7SoNqo4W%2BMEg%3D%3D"}],"group":"cf-nel","max_age":604800}
nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
server: cloudflare
cf-ray: 7fb102374a8d17ce-MEL
alt-svc: h3=":443"; ma=86400
{"detail":"Api works!"}
Other servers can access it normally, but I cannot access it from my server (IP 8.218.240.232) . The error code is 403, “Just a moment…”. When accessing the domain provided by Workers, api-gptvip-workers-dev, on my server, it works fine. However, I cannot access my own domain.
This is likely Cloudflare Bot Protection or some other Cloudflare service screening your request. If you check your WAF events, you’ll probably see the request getting challenged or blocked.
I have figured out the reason. The ‘Bot Fight Mode’ was enabled and causing the block. Just disable it, and everything will be fine.Thanks!