pub struct CustomerSession {
pub client_secret: String,
pub components: Option<CustomerSessionResourceComponents>,
pub created: Timestamp,
pub customer: Expandable<Customer>,
pub expires_at: Timestamp,
pub livemode: bool,
}
Expand description
A Customer Session allows you to grant Stripe’s frontend SDKs (like Stripe.js) client-side access control over a Customer.
Related guides: Customer Session with the Payment Element,. Customer Session with the Pricing Table, Customer Session with the Buy Button.
Fields§
§client_secret: String
The client secret of this Customer Session.
Used on the client to set up secure access to the given customer
.
The client secret can be used to provide access to customer
from your frontend.
It should not be stored, logged, or exposed to anyone other than the relevant customer.
Make sure that you have TLS enabled on any page that includes the client secret.
components: Option<CustomerSessionResourceComponents>
§created: Timestamp
Time at which the object was created. Measured in seconds since the Unix epoch.
customer: Expandable<Customer>
The Customer the Customer Session was created for.
expires_at: Timestamp
The timestamp at which this Customer Session will expire.
livemode: bool
Has the value true
if the object exists in live mode or the value false
if the object exists in test mode.
Trait Implementations§
Source§impl Clone for CustomerSession
impl Clone for CustomerSession
Source§fn clone(&self) -> CustomerSession
fn clone(&self) -> CustomerSession
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more