Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Flutter integration with AWS (With and without Amplify)

We are building a Flutter app which for Web, Android and iOS. We plan to use AWS for backend using services like Cognito, Dynamodb, S3 and few others.

We have tried to use to Amplify - but understand it is not yet available for Flutter web.

What is best way to connect with Cognito ? and then other services like Dynamodb, S3 etc in AWS

We tried https://pub.dev/packages/amazon_cognito_identity_dart and it is very slow and we are not able to connect.

like image 550
Deepak Dolas Avatar asked Dec 22 '25 15:12

Deepak Dolas


1 Answers

You should try the a packed based on the one you are mentioning: https://pub.dev/packages/amazon_cognito_identity_dart_2

It worked pretty well for me - I was able to use S3, Lambda, API Gateway, AppSync (with websockets) etc. Note that it does not support Data Store; and if you can live without it - it should work fine.

The only issue is - login is very slow on the web (not on android or ios), there is an open issue about it: https://github.com/furaiev/amazon-cognito-identity-dart-2/issues/123. There seems to be a solution for it now, you may give it a try.

Amplify team implemented Flutter support by using already existing Android and iOS libraries, and just doing the Flutter wrapper around it. I guess it helped them roll it out much faster; but the proper solution (in my opinion) would be to re-write the JavaScript libraries in Dart, and have it compile natively to iOS, Android, Web and all other platforms. My guess is this will come in the future; Amplify Flutter is still in version 0.x.x.

like image 165
Andrija Avatar answered Dec 24 '25 03:12

Andrija



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!