Closed ianberdin closed 6 days ago
If we don't specify an operationId, the API will look like this:
api.users.usersControllerCreate() -> UsersControllerCreateResponse
api.carts.cartsControllerCreate() -> CartsControllerCreateResponse
api.bookings.bookingsControllerCreate() -> BookingsControllerCreateResponse
Hey @ianberdin, is this a regression?
No, it's not. I can't use the next version 0.46.* because it breaks completely, so I'm using 0.45.3.
There is no this
on root file, I see it does not use classes anymore (0.46.*):
Thank you for your quick response. The issue with this
has been resolved.
The main problem now is non-unique names when using a custom operationId. Is there a way to fix this?
And this, if I set new hey-api fetch client:
Not that I'm aware, will need to look at this. Thanks for reporting!
If I remove the operationId, it will look like this:
api.users.usersControllerCreate()
- not very appealing for a customer-facing API :(
Are you on Discord @ianberdin? Would like to understand your use case better
I've sent you a request in Discord. @ianberdin mine username.
I think you can resolve this with services.methodNameBuilder(), let me know if not
Description
Hi, thanks again for your huge contribution to Open Source with this package.
It seems like we're doing something wrong because the type in JSDoc doesn't match the actual return type. As a result, the return type, like
CreateResponse
, is the same for all services.We're trying to make an SDK that works like this using tags (users, carts, bookings) and operationIds (create):
But what we get is (always
CreateResponse
andCreateData
):OpenAPI specification (optional)
Configuration
System information (optional)
No response