AWSS3 upload and download file using AWSS3GetPreSignedURLRequest and custom AWSCognitoCredentialsProviderHelper with token and identityId, from API.
Important AWSCognito works only with AWSCognitoCredentialsProvider, it will not work if you set AWS Credentials in appdelegate.
- Get tokens, auth and other setups from API.
- Init singleton AmazonAuth with this fields.
- Make config: DeveloperAuthenticatedIdentityProvider
- Now you can upload/download images using PreSignedURL.
Code updated for swift 4.