facebook / facebook-nodejs-business-sdk

Node.js SDK for Meta Marketing APIs
https://developers.facebook.com/docs/business-sdk
Other
489 stars 226 forks source link

Currency code capitalization? #292

Closed seanberto closed 1 week ago

seanberto commented 1 month ago

Which SDK version are you using?

Main branch.

What's the issue?

In the Main branch, here: https://github.com/facebook/facebook-nodejs-business-sdk/blob/main/src/objects/serverside/utils.js#L123, currency codes are lowercased.

However, in all of Meta's Pixel and CAPI documentation, currency codes are listed as capitalized, following the ISO 4217 specification.

Does Meta Pixel and CAPI accept either capitalized or lowercased versions of Currency codes? What does Meta want to receive for Pixel and CAPI? If it is the capitalized format, why does this Node.js library change currency codes to lower case?

Observed Results:

stcheng commented 1 week ago

@seanberto it doesn't seem that this will affect the behavior. could you submit a pull request to remove this or change it to toUpperCase to reduce the confusion?

seanberto commented 1 week ago

Thanks, @stcheng.

Here's a PR:

https://github.com/facebook/facebook-nodejs-business-sdk/pull/294