Comments for Test the APIs


The complete error message is
Authenticating with User Pool
Getting temporary credentials
Token is not from a supported provider of this identity pool.


Are you sure regarding the region ?


Yes I am using us-east-1 region


I have the same problem as @mikhaelbendavid.


Authenticating with User Pool
Getting temporary credentials
Inaccessible host:'. This service may not be available in the‘us-east-2’’ region.

Test user is created exactly like in the tutorial. But in my Users and groups, under username, it shows the UserSub. (that’s the only difference)
What could be the problem?

[ I’m in China tried with VPN on and off, neither worked ]

Many thanks!


I figured out the user pool id was not configured properly


@KatieChen1001Can you post the command you are running? I think it might have something to do with your regions.


Hi @jayair! Thanks for responding! Below is the command I ran:

npx aws-api-gateway-cli-test --username='' --password='Passw0rd!' --user-pool-id='us-east-1_ECL8IZghT' --app-client-id='3qt33ps0jjcbaktnhamned7grf' --cognito-region=‘us-east-1’ --identity-pool-id='us-east-1:d16ca28e-dde0-4d7d-9700-f6e1d0bf069a' --invoke-url='' --api-gateway-region=‘us-east-1’ --path-template=‘/supplierInfo’ --method='POST' --body='{"content":"hello world","attachment":"hello.jpg"}'


I just tried it on my end. I think your command has some weird single quote characters. For example, it should be this:


instead of this:



Resolved! Many thanks! Can’t believe it was because of that…


Yeah it’s unclear to me why the error message looked like that.


Hi @jayair

I am facing the same error 500 as you mentioned in the screenshot where should i need to check to resolve this ? And how can i able to see the logs that you attached here?



I’m getting two confusing things on windows

  1. The issue with the Path
  2. The POST getting stuck in the URL…
npx: installed 1 in 2.013s
Path must be a string. Received undefined
npx: installed 103 in 8.634s
Authenticating with User Pool
Getting temporary credentials
Making API request
{ status: 403,
  statusText: 'Forbidden',
   { Message: 'User: arn:aws:sts::358227436652:assumed-role/Cognito_NotesIdentityPoolAuth_Role/CognitoIdentityCredentials is not authorized to perform: execute-api:Invoke on resource: arn:aws:execute-api:us-east-1:********6652:k4k529wmxi/prod/POST/notes' } }


@Seeker You can read more about the logs here - But can you post the command and the full output with the error message?

@mgeiser Can I see your full command?


What I run (with the user, pswd and URL slighlty altered) - also…Windows 10.

npx aws-api-gateway-cli-test --username --password SomethingElse --user-pool-id us-east-1_IE9roIYdQ --app-client-id g1d7bmlgssg8umnep4gb1md70 --cognito-region us-east-1 --identity-pool-id us-east-1:05fb168b-d7ae-4643-b912-6495a6e2563a --invoke-url --api-gateway-region us-east-1 --path-template /notes --method POST --body "{\"content\":\"hello world\",\"attachment\":\"hello.jpg\"}"


I’m not sure about Windows but I think the error is complaining about the path parameter not being set? Maybe it needs quotes around it?


By the “path” do you mean the “invoke-url” or the “path-template”? I tried both and the various permutations before posting.

What would be helpful is if someone that actually was successful running it on windows could respond…

I also tried changing the / from the path-template to the invoke-url…no dice there either


update…it looks like the “path” issue is a red herring…when I ran npx in the next section to create the node project I got the same line but it completed

I recreated the identity pool but still getting the 403. Any help on how to debug?


I deleted the identity pool and recreated again and now it works…son of a b…


Hmm glad it worked out. A lot of times it is related to the way the Identity Pool was configured.


This fixed my problem! can I ask, how did you end up finding this problem existed? Sorry I am new, and I just want to learn the techniques and methods involved in troubleshooting issues. Thanks