Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add customer_id to Spree::User #3

Open
nirebu opened this issue Sep 30, 2020 · 1 comment
Open

Add customer_id to Spree::User #3

nirebu opened this issue Sep 30, 2020 · 1 comment
Labels

Comments

@nirebu
Copy link
Collaborator

nirebu commented Sep 30, 2020

In order to create a KObject belonging to a customer to make it appear on their timeline we need to hit an endpoint such as

"/customers/#{kustomer_customer_UUID}/klasses/#{kobject_klass_name}"

to get that ID we need first to query Kustomer for it. We can get it by querying for a Spree::User id, which usually is used as externalId on Kustomer like so:

"/customers/externalId=#{Spree::User.id"

To reduce the amount of requests to Kustomer could be a good idea to store this ID in the user table.

@nirebu nirebu linked a pull request Oct 6, 2020 that will close this issue
@stale
Copy link

stale bot commented Jan 7, 2023

This issue has been automatically marked as stale because it has not had recent activity. It might be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jan 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant