GET request return code 10000

Reproduce the issue:
create api token with
template: Read all resources / Account Resources (All account)

zoneId = GET "/client/v4/zones"

curl -X GET -H "Accept: application/json, text/plain, */*" -H "Content-Type: application/json" -H "Authorization: Bearer xxx" -H "User-Agent: axios/1.5.0"${zoneId}/custom_hostnames',
  data: '{"success":false,"errors":[{"code":10000,"message":"Authentication error"}]}

That call requires the API key and does not support tokens.

Don’t know if this is intention, but your zone ID will not look like this. Can find it with Find zone and account IDs · Cloudflare Fundamentals docs

Hi Cyb3r-Jak3,
I am wondering if it’s safe to include the zoneId in my content. Could you tell me how you can help me with this?

HI Sandro, Thx for your reply, but it work with my test account.

curl -X GET -H "Accept: application/json, text/plain, */*" \
 -H "Content-Type: application/json" \
 -H "Authorization: Bearer xx" \
 -H "User-Agent: axios/1.5.0" \
  "result": [
      "id": "95520d...",
      "hostname": "...",
      "ssl": {
        "id": "5478f4...

According to the documentation it should not work and I get the same message with a token. Did you try the key and are you sure the feature is enabled for that domain?

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.