Skip to content
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

Incorrect type for node API listIntegrations #1224

Closed
lukaso opened this issue Nov 3, 2023 · 0 comments · Fixed by #1227
Closed

Incorrect type for node API listIntegrations #1224

lukaso opened this issue Nov 3, 2023 · 0 comments · Fixed by #1227
Assignees
Labels
bug Something isn't working

Comments

@lukaso
Copy link

lukaso commented Nov 3, 2023

The result type of listIntegrations is incorrect.

I've written this code in order to use the results:

    const integrations = (await this.nango.listIntegrations()) as any as {
      configs: { unique_key: string; provider: string }[];
    };
    // Now I can use it
    return integrations.configs.map((i) => {
      return i.unique_key;
    });

The type in the SDK is declared as:

(method) Nango.listIntegrations(): Promise<Pick<Integration, "unique_key" | "provider">[]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants