Stream API 10000 Error

Stream API: Linked to an old post below and am currently having the same issue. Getting a 500 response that says error code 10000, “Authentication error”. However, like the forum post I linked to I’m 100% sure my token is valid (I test it in a preceding request using the tokens/verify endpoint) and the token has permissions for read + edit Stream (along with the whole read permissions template). The other post did seem to get it to work with the legacy global API, but I’ve had no such luck. (Also, since the doc examples) use Authorization it should work) Considered it being a permissions issue and added all the ones I think could possibly be related to it but still nothing.

Any advice or words of wisdom? Thank you!

// here's a snippet of what my code looks like...
    const init = {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
        Authorization: `Bearer ${headers.get("authorization")}`,
    const response = await fetch(
      "" +
        headers.get("userid") +
    const body = await gatherResponse(response);

Here’s what it returns:

Can’t add links for some reason but here it is:
https:// community.Cloudflare .com/t/Cloudflare-stream-10000-authentication-error/149227

Hi, do you get the same error if you use a client like Insomnia to make a request?

Hi! Yes, unfortunately. Here’s a screenshot of it in Postman. Thanks for the reply!

My account ID is the top covered value and token key is the bottom covered value.

Thanks. Just dropped you an email.

1 Like

Fixed: Thank you @zaid for your help! The API requires you to use the Account ID. I was mistakenly using the User ID instead. You can find the accounts available to a user by using this endpoint: https:// api.Cloudflare .com/client/v4/accounts and then using the ID associated with the account.

1 Like

Hi, I’m having similar problems but I’m already using Account ID and this happens only occasionally, like 2-3 times a month. It works most of the time so I’m not sure why I’m getting this.

1 Like

I am having the same issue. This happens only a few times per day, but it is stil an annoying experience. Did you find a solution?

Yes, I did (see my reply on June 5). Probably not the same issue though.

1 Like

I’m also having this issue a handful of times per day. Also an annoying experience… I’m getting it intermittently when issuing a GET to the dns record endpoint (

My solution is a very unsatisfying one: retry my operation up to 3 times before failing. It works. It’s gross. Still curious what’s going on here. When it fails, the request always takes around 10 seconds, so i suspect there’s some internal auth component or service that’s busy or inaccessible which causes the request to timeout. Here’s the response body:

{"success":false,"errors":[{"code":10000,"message":"Internal authentication error: internal server error"}]}

Thanks @nibble . I could use that workaround, but I would love to avoid it. @zaid I know you sometimes have insights into these issues?