mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
feat(customer_v2): add route for customer retrieve v2 (#5516)
Co-authored-by: Narayan Bhat <narayan.bhat@juspay.in> Co-authored-by: hrithikesh026 <hrithikesh.vm@juspay.in> Co-authored-by: Prajjwal Kumar <prajjwal.kumar@juspay.in> Co-authored-by: Sanchith Hegde <sanchith.hegde@juspay.in> Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com> Co-authored-by: Sahkal Poddar <sahkalpoddar@Sahkals-MacBook-Air.local>
This commit is contained in:
@ -282,6 +282,8 @@ pub struct CustomerResponse {
|
||||
/// The identifier for the default payment method.
|
||||
#[schema(max_length = 64, example = "pm_djh2837dwduh890123")]
|
||||
pub default_payment_method_id: Option<String>,
|
||||
/// Global id
|
||||
pub id: String,
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "v2", feature = "customer_v2"))]
|
||||
@ -308,6 +310,19 @@ impl CustomerId {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "v2", feature = "customer_v2"))]
|
||||
#[derive(Clone, Debug, Deserialize, Serialize)]
|
||||
pub struct GlobalId {
|
||||
pub id: String,
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "v2", feature = "customer_v2"))]
|
||||
impl GlobalId {
|
||||
pub fn new(id: String) -> Self {
|
||||
Self { id }
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "v2", feature = "customer_v2"))]
|
||||
#[derive(Clone, Debug, Deserialize, Serialize)]
|
||||
pub struct CustomerId {
|
||||
|
||||
Reference in New Issue
Block a user