Skip to main content

stripe_pay_core/id/
struct.rs

1use super::*;
2
3/// A typed Stripe object identifier such as `pi_3Abc...` or `cus_9Xyz...`.
4///
5/// The `kind` records which resource the identifier points at, and
6/// `raw` keeps the original wire value untouched so it round-trips
7/// back to Stripe byte-for-byte.
8#[derive(Clone, Debug, Eq, Getter, Hash, Ord, PartialEq, PartialOrd, serde::Serialize)]
9pub struct StripeId {
10    /// The resource family this identifier addresses.
11    #[get(type(copy))]
12    pub(super) kind: StripeIdKind,
13    /// The full wire value including its type prefix.
14    pub(super) raw: String,
15}