square / square-nodejs-sdk

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Export apimatic schemas for models

mciuchitu opened this issue · comments

I would like to use this package to work with Webhooks API. It contains both typing definitions and apimatic schemas for models, that nicely suits my needs. But unfortunately, the schemas are not exported. Can you please export the schemas as well?

Thanks for the feedback! I will pass this along to our SDK team and let you know once I have more info.

Would the swagger spec (https://github.com/square/connect-api-specification) help you? It sounds like you'd like to use the spec to interpret the results in the Webhooks event body?

@sseaman We are using TypeScript. I want to use the interfaces from the package for the typings for the webhook events processing.
Before I can do it, the webhook response should be transformed via apimatic (as it is done in the SDK).
The issue is that the corresponding apimatic schemas are not exported.

I've added this to our feature backlog but I do not expect us to get anytime soon. If you require this in the next few months, I'd suggest investigating other alternatives. Apologies.

I'm going to close this for now but it is on our internal backlog. Thank you for the suggestion!