findById method

Future<RecurringInvoice?> findById(
  1. String id
)

Find an invoice by its id

Implementation

Future<RecurringInvoice?> findById(String id) async {
  final response = await WebClient().get(
      '${InvoiceNinjaAdmin.url}/api/v1/recurring_invoices/$id',
      token: InvoiceNinjaAdmin.token);

  return RecurringInvoiceItem.fromJson(response).data;
}