/// <summary>
        /// Creates a new checkout order asynchronously.
        /// </summary>
        /// <param name="request">The <see cref="ICheckoutOrderRequest"/> object</param>
        /// <returns><see cref="CheckoutOrderResponse"/></returns>
        public virtual async Task <CheckoutOrderResponse> CreateCheckoutOrderAsync(ICheckoutOrderRequest request)
        {
            var url = UrlHelper.GetApiUrl(Session.BaseUrl, ResourceUrls.Checkout_CreateOrder);

            RestRequest req = CreateRestRequest(Method.POST, url, GetRequestBody(request.OrderData));
            var         res = await _client.ExecutePostTaskAsync(req).ConfigureAwait(false);

            var response = DeserializeOrDefault <CheckoutOrderResponse>(res);

            return(response);
        }
        /// <summary>
        /// Creates a new checkout order.
        /// </summary>
        /// <param name="request">The <see cref="ICheckoutOrderRequest"/> object</param>
        /// <returns><see cref="CheckoutOrderResponse"/></returns>
        public virtual CheckoutOrderResponse CreateCheckoutOrder(ICheckoutOrderRequest request)
        {
            var url = UrlHelper.GetApiUrl(Session.BaseUrl, ResourceUrls.Checkout_CreateOrder);

            RestRequest req = CreateRestRequest(Method.POST, url, GetRequestBody(request.OrderData));
            var         res = _client.Execute(req);

            var response = DeserializeOrDefault <CheckoutOrderResponse>(res);

            return(response);
        }