def update(order)
      validate_type!(order)
      params = extract_params!(order, :id)
      id = params[:id]

      attributes = sanitize(order)
      _, _, root = @client.put("/orders/#{id}", attributes)

      Order.new(root[:data])
    end
def update(order)
      validate_type!(order)
      params = extract_params!(order, :id)
      id = params[:id]

      attributes = sanitize(order)
      _, _, root = @client.put("/orders/#{id}", attributes)

      Order.new(root[:data])
    end
Update an order

 put '/orders/{id}'

 Updates order information
 If the specified order does not exist, the request will return an error

 @param order [Order, Hash] Either object of the Order type or Hash. This object's attributes describe the object to be updated.
 @return [Order] The resulting object represting updated resource.