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

Adding risk data params to the AdditionalData struct #77

Open
jpvergineperfectstay opened this issue Mar 29, 2019 · 0 comments
Open

Adding risk data params to the AdditionalData struct #77

jpvergineperfectstay opened this issue Mar 29, 2019 · 0 comments

Comments

@jpvergineperfectstay
Copy link

jpvergineperfectstay commented Mar 29, 2019

Hello, ( and thanks for your work ! )

We need to add risk datas parameters to our request ( description available here : https://docs.adyen.com/developers/api-reference/payments-api/paymentrequest/paymentrequest-additionaldata )

For our use, we we would need:

  • Two fields:
    • riskdata.shopperCountry and
    • riskdata.browserLanguage ( on a new struct RiskData ? )

and

  • Params exposed on "Basket content fields" part:
    • riskdata.basket.item ( itemID, productTitle, amountPerItem etc .... )

I made a "quick dirty" test, mapping the fields like this on current "AdditionnalData" struct:

RiskDataItemProductTitle string json:"riskdata.basket.item.productTitle,omitempty"
RiskDataItemCategory string json:"riskdata.basket.item.category,omitempty"
RiskDataItemSize int json:"riskdata.basket.item.size,omitempty"

It seems to work as I see the information on Adyen backOffice,

But what I don't uderstand is how to map/generate "itemNr" required by adyen for each item, if you have any idea your help should be welcome to purpose a struct for our need,

Kind regards,
Thanks in advance,
JP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant