square_api_client/models/
update_order_request.rs

1//! Model struct for UpdateOrderRequest type
2
3use serde::Serialize;
4
5use super::Order;
6
7/// This is a model struct for UpdateOrderRequest type.
8#[derive(Clone, Debug, Default, Eq, PartialEq, Serialize)]
9pub struct UpdateOrderRequest {
10    /// The [sparse
11    /// order](https://developer.squareup.com/docs/orders-api/manage-orders#sparse-order-objects)
12    /// containing only the fields to update and the version to which the update is being applied.
13    pub order: Order,
14    /// The [dot notation
15    /// paths](https://developer.squareup.com/docs/orders-api/manage-orders#on-dot-notation) fields
16    /// to clear. For example, `line_items[uid].note`. For more information, see [Deleting
17    /// fields](https://developer.squareup.com/docs/orders-api/manage-orders#delete-fields).
18    pub fields_to_clear: Option<Vec<String>>,
19    /// A value you specify that uniquely identifies this update request.
20    ///
21    /// If you are unsure whether a particular update was applied to an order successfully, you can
22    /// reattempt it with the same idempotency key without worrying about creating duplicate updates
23    /// to the order. The latest order version is returned.
24    ///
25    /// For more information, see
26    /// [Idempotency](https://developer.squareup.com/docs/basics/api101/idempotency).
27    pub idempotency_key: Option<String>,
28}