Skip to content

[Question] How do you send query parameters in a find call? #211

@yashsway

Description

@yashsway

My goal: use the findInvoices method to fetch a list of invoices by customer ID, with the InvoiceLink field included for each invoice.

According to https://developer.intuit.com/app/developer/qbo/docs/api/accounting/all-entities/invoice#the-invoice-object, the InvoiceLink field is only included if the query param include=invoiceLink is passed in.

Sharable link for the invoice sent to external customers. The link is generated only for invoices with online payment enabled and having a valid customer email address. Include query param include=invoiceLink to get the link back on query response.

Here's a snippet of my code:

  getInvoices(customerId: string, limit: number = 1000): Promise<QuickbooksInvoiceEntity[]> {
    return new Promise((res, rej) => {
      this.apiClient.findInvoices(
        {
          CustomerRef: customerId,
          limit,
        },
        (err, invoices: QuickbooksQueryResponse<QuickbooksInvoiceQueryResponse>) => {
          if (err) {
            rej(err);
            return;
          }

          res(invoices.QueryResponse.Invoice);
        },
      );
    });
  }

I can't find any details regarding how I pass in query parameters? Looks like the keys I specify are specifically for the where clause. (other than things like sorting, limits, pagination, and count)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions