Calling AWS services with AWS SDK outside of AWS

0

Hi everyone,

This is probably a dumb question, but is there a way we can call AWS services with AWS SDK (e.g. boto3) outside of AWS / AWS lambda functions? i.e. Besides leveraging on AWS CLI, AWS API Gateway and/or Lambda functions with the right permissions.

Thank you!

3 réponses
3

You can use AWS SDK in applications running outside of AWS, the only thing you have to configure properly in that case is AWS credentials. Since you mentioned boto3 you can check the example documentation for boto3 on how credentials are used: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html

Based on the credentials you will get appropriate access to AWS resources.

répondu il y a 2 ans
profile pictureAWS
EXPERT
vérifié il y a 2 ans
  • Awesome, thank you so much for your help! I just thought about AWS Cognito Identity Pools but your suggestion and link provided answers my question perfectly, I had no idea we could embed credentials in functions like that

  • One thing I want to mention, is make sure you don't hard code credentials in functions/applications which you ship to end users. And AWS Cognito will be right choice when for example you want to allow your mobile app users to be able to upload to s3 bucket directly from you mobile app.

1

Yes, the SDKs can be used from anywhere where it runs: Raspberry Pi, macOS.....

AWS
répondu il y a 2 ans
  • Thanks! But if we write a function outside of AWS lambda, it needs to have the permissions to manage AWS resources. Without leveraging on AWS lambda functions and API gateway, can we assign the necessary permissions to those external functions?

  • Update: Thanks! I had no idea we could embed credentials in functions

0

Use AWS Toolkit for the Eclipse IDE to develop, debug, and deploy Java applications that use Amazon Web Services. https://docs.aws.amazon.com/toolkit-for-eclipse/v1/user-guide/welcome.html https://docs.aws.amazon.com/sdk-for-java/v1/developer-guide/setup-credentials.html

répondu il y a 2 ans

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions