/// <summary>
 /// Find purchase order by Id
 /// </summary>
 /// For valid response try integer IDs with value &lt;= 5 or &gt; 10. Other
 /// values will generated exceptions
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='orderId'>
 /// Id of pet that needs to be fetched
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <Order> GetOrderByIdAsync(this ISwaggerPetstoreV2 operations, string orderId, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetOrderByIdWithHttpMessagesAsync(orderId, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Find purchase order by Id
 /// </summary>
 /// For valid response try integer IDs with value &lt;= 5 or &gt; 10. Other
 /// values will generated exceptions
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='orderId'>
 /// Id of pet that needs to be fetched
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse <Order> GetOrderByIdWithHttpMessages(this ISwaggerPetstoreV2 operations, string orderId, Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.GetOrderByIdWithHttpMessagesAsync(orderId, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }