-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
🐛 Bug Report: Novu SDK layouts response DTO is not correct #3446
Comments
Bumping |
@underfisk sorry but could you clarify what you are receiving that doesn't match the interface
|
@p-fernandez @scopsy, Seem to me like @underfisk is explicitly typing Whereas, Correct use on the user's end should look like so: import { AxiosResponse } from "axios";
//@ts-ignore
const fff: AxiosResponse<ILayoutPaginationResponse> = await novu.layouts.list({
page: 0,
pageSize: 100,
});
fff.data.data // now you can see the right hint as you type @p-fernandez Is there any documentation on how to use types like
This seems to be all tied to the fact that most methods don't have explicit return types. Happy to make a PR Also see #3928 (comment) |
@jainpawan21 I think that you have made some adjustments based on that recently, any thoughts on this one? |
This should not happen Assigning this to myself |
What's the status on this @jainpawan21 :) |
📜 Description
Noticed while using the Novu Nodejs SDK that when attempting to fetch a list of layouts, the response DTO does not match the API response
👟 Reproduction steps
novu.layouts.list({ your params})
👍 Expected behavior
The interface should reflect the actual API response
👎 Actual Behavior with Screenshots
You'll observe that
list
will have the following content:When inspecting with my IDE, this is what I see:
📃 Provide any additional context for the Bug.
No response
👀 Have you spent some time to check if this bug has been raised before?
🏢 Have you read the Contributing Guidelines?
Are you willing to submit PR?
Yes I am willing to submit a PR!
The text was updated successfully, but these errors were encountered: