Skip to content

[Bug] Monday.api method to include errors in default return type #147

@kostekd

Description

@kostekd

The monday.api() method does not include errors in its default return type. This requires additional handling in the client code and extending existing types.

Steps to reproduce

  1. Call `monday.api(). Which will not be valid.
  2. See the request fails
  3. It returns an array of objects errors.
  4. Observe that the response does not include an errors in the type definition.
api<T = any>(query: string, options?: APIOptions): Promise<{ data: T, account_id: number }>;

Expected behavior
Behavior is acceptable but the type definition could be extended.

Context and environment
-SDK Version: 0.5.6
-Environment: Node.js 22

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions