-
Notifications
You must be signed in to change notification settings - Fork 67
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
Missing Typescript properties in Payment model #390
Comments
You're not missing anything :) The properties you mentioned have been introduced fairly recently to eventually enable transition from the Orders API to the Payments API. We will include them in a future version of this library to support this. |
Especially since payments should replace the orders API, these are very sensible additions. In the meantime, you can get around Typescript complaining by spreading them into your lines = {
[...]
}
client.payments.create({
amount: {
value: 100
currency: "EUR",
},
...{ lines }, // tmp syntax, until @mollie/api-client includes correct property types
}); This way you don't have to disable ts checking for the whole object. |
Ok. Thanks for your reply 🙇 Should we keep this opened until the types are added to the package? |
Yes! :) |
This seems to also apply to the |
@carderne, thanks for pointing this out. we will include it in the updates. |
Hello 👋
We're starting to consume Mollie APIs and I think I'm missing some properties in the Payment model typescript definition.
Based on the API documentation (reference), a payment can have these optional properties:
However the Typescript type describing this model does not contain those properties (reference).
Are we missing something?
Thanks.
The text was updated successfully, but these errors were encountered: