aws-amplify / amplify-js

A declarative JavaScript library for application development using cloud services.
https://docs.amplify.aws/lib/q/platform/js
Apache License 2.0
9.39k stars 2.11k forks source link

RecommendationId not supported in AWSPersonalizeProvider #9644

Open vn-fab opened 2 years ago

vn-fab commented 2 years ago

Before opening, please confirm:

JavaScript Framework

React

Amplify APIs

Analytics

Amplify Categories

analytics, interactions, predictions

Environment information

``` # Put output below this line ```

Describe the bug

Recommendation id is not supported in https://github.com/aws-amplify/amplify-js/blob/main/packages/analytics/src/Providers/AmazonPersonalizeProvider.ts

PutEvents api has recommendationid and impression data in the payload.

Also PutEventsCommand has support for same.

But AmazonPersonalizeProvider does not log recommendationId

Please add support for this

Expected behavior

Should be able send recommendationid and impression to AWS personalize using AmazonPersonalizeProvider

Reproduction steps

Try sending events like

Analytics.record( { eventType: 'View', userId: userId, recommendationId: rId, properties: { itemId: currentProduct.itemId.toString(), }, }, 'AmazonPersonalize', ) }

Code Snippet

// Put your code below this line.

Log output

``` // Put your logs below this line ```

aws-exports.js

No response

Manual configuration

No response

Additional configuration

No response

Mobile Device

No response

Mobile Operating System

No response

Mobile Browser

No response

Mobile Browser Version

No response

Additional information and screenshots

No response

chrisbonifacio commented 2 years ago

Hi @vn-fab 👋 thanks for raising this issue. There is separate Personalize team that owns the AWSPersonalizeProvider that we use in our library. We will reach out to them about this. Labeling this as a feature request.

danielrodcaball commented 1 month ago

Any updates on this guys? Is doing a fork the only way to do this right now?