postCommerceStoreByStoreidCheckoutPaypalPayWithHttpInfo method

Future<Response> postCommerceStoreByStoreidCheckoutPaypalPayWithHttpInfo(
  1. String storeid
)

Start a PayPal authorization for a new order — the checkout spelling

Begins a PayPal authorization by running the ordinary store authorize flow, since the route binds that exact handler — body, store resolution, tally, reservations and failure behaviour are the authorize address's, unchanged. The processor is chosen from the body's payment type, so this path reaches PayPal only when that type says so. A successful PayPal authorization stamps a pay key onto the payment, which is the key the confirm and cancel addresses filter on. Build against the plain authorize address instead.

Note: This method returns the HTTP Response.

Parameters:

Implementation

Future<Response> postCommerceStoreByStoreidCheckoutPaypalPayWithHttpInfo(String storeid,) async {
  // ignore: prefer_const_declarations
  final path = r'/v1/commerce/store/{storeid}/checkout/paypal/pay'
    .replaceAll('{storeid}', storeid);

  // ignore: prefer_final_locals
  Object? postBody;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  const contentTypes = <String>[];


  return apiClient.invokeAPI(
    path,
    'POST',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
  );
}