Open Eliav2 opened 9 months ago
Hey, @Eliav2 and thanks for opening up this issue. I'll mark it as a feature request for now and review it with our team internally, but have a question or two to clarify some context first. Are you trying to use Amplify exclusively on the server (with no intention to run on the client side/browser)? Do you have any user interaction on the client side at all? Thanks!
Hey! Thanks for the response.
It could be great if amplify sdk could accept authentication on the server side by local aws cli profile with proper credentials (currently a cognito user with proper credentials must be supplied in the auth flow)
@Eliav2, appreciate the clarity and reply! I'll review this feature request with the team and we'll update this issue with further questions or updates on progress as they come.
Is this related to a new or existing framework?
React
Is this related to a new or existing API?
Authentication
Is this related to another service?
No response
Describe the feature you'd like to request
I've used amplify SDK on my backend to run scripts that interact with my backend directly (execute db migrations scripts, etc).
I've used amplify SDK on my backend because it directly simulates user interactions and handle much of the complexity, for example, when creating a record in a table, the
createdAt
,upadtedAt
,id
is automatically defined and GQL validations based on your schema takes place, while using DynamoDB SDK to change the DB does not go through validation and fields are not automatically populated.So I have 2 questions to you guys:
My current method
which no longer works now, not sure why
getCredentials
to grab the credentials from the Cognito pool using aws-sdk for javascript.now each time I want to authenticate in a script that is making some useful operations i've simply imported the
auth.ts
file in the script:this used to work like charm, and i could easily run script from my backend as if each operation executed by the script was executed by the mock admin user defined in the
auth.ts
file.(consider enabling GitHub discussions for this repo to avoid 'issues' like that one)
Describe the solution you'd like
.
Describe alternatives you've considered
.
Additional context
No response
Is this something that you'd be interested in working on?