Forum Xamarin.Forms

Authenticate requests from xamarin.forms to aws API Gateway with Cognito jwt token

nthingnthing USMember ✭✭

I am trying to authenticate requests from xamarin.forms app to aws API Gateway. Users are authenticated from a user pool and I am able to receive id/access/refresh tokens at the authentication.

I do not understand how to sign requests against the api gateway with the xamarin sdk.

This functionality is supported by the sdk?

Otherwise I could authenticate requests with aws signature v4. Even in this case I can't figure out how to use the tokens I receive from cognito to obtain the session token

from the docs (

Note You can use temporary security credentials provided by the AWS Security Token Service (AWS STS) to sign a request. The process is the same as using long-term credentials, but when you add signing information to the query string you must add an additional query parameter for the security token. The parameter name is X-Amz-Security-Token, and the parameter's value is the URI-encoded session token (the string you received from AWS STS when you obtained temporary security credentials).
How can I build the v4 signature headers using Cognito tokens?

stack overflow question:

Sign In or Register to comment.