createPurchaseExpress function

Future<ApiResponse<PurchaseExpress>> createPurchaseExpress(
  1. ExsitedClient client,
  2. Object payload, {
  3. bool? raiseOnError,
  4. String? responseFormat,
})

POST /api/{api_version}/purchase_express

Create a purchase order, and its purchase invoice and payment if the body nests them, in one call, body account.purchase_order; 201.

Implementation

Future<ApiResponse<PurchaseExpress>> createPurchaseExpress(
  ExsitedClient client,
  Object payload, {
  bool? raiseOnError,
  String? responseFormat,
}) =>
    client.sendPostRequest(PurchaseExpressUrls.purchaseExpress,
        jsonBody: payload,
        raiseOnError: raiseOnError,
        responseFormat: responseFormat,
        dtoDecoder: PurchaseExpress.fromMap);