aws-sdk-js-v3 icon indicating copy to clipboard operation
aws-sdk-js-v3 copied to clipboard

what to put as a config?

Open dhavalpacewisdom opened this issue 1 year ago • 1 comments

Describe the issue

const client = new PersonalizeEventsClient(config); In the above line, could you mention what to put as a config?

Links

https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/personalize-events/command/PutEventsCommand/

dhavalpacewisdom avatar May 15 '24 04:05 dhavalpacewisdom

Hi @dhavalpacewisdom - thanks for reaching out.

For service-level configuration, you can pass in objects like region or credentials which you'll have significant control over your default local configuration. If those configurations aren't defined, SDK will use your local config.

For example: const client = new PersonalizeEventsClient({ region: 'us-east-1', credentials: {...} }); or if you have credentials configured locally, you can run it like const client = new PersonalizeEventsClient();

You can read more about it here: https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/global-config-object.html

Hope it helps, John

aBurmeseDev avatar May 15 '24 19:05 aBurmeseDev

This issue has not received a response in 1 week. If you still think there is a problem, please leave a comment to avoid the issue from automatically closing.

github-actions[bot] avatar May 26 '24 00:05 github-actions[bot]

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

github-actions[bot] avatar Jun 14 '24 00:06 github-actions[bot]