NAME
Net::API::Stripe::Billing::PortalSession - The session object
SYNOPSIS
my $portal = $stripe->portal_session({
created => 'now',
customer => 'cust_fake123456789',
livemode => $stripe->false,
return_url => 'https://example.com/ec/df63685a-6cd2-4c5d-9d4c-81b417646a58',
url => 'https://billing.stripe.com/session/{SESSION_SECRET}',
});
VERSION
v0.1.0
DESCRIPTION
A session describes the instantiation of the customer portal for a particular customer. By visiting the session's URL, the customer can manage their subscriptions and billing details. For security reasons, sessions are short-lived and will expire if the customer does not visit the URL. Create sessions on-demand when customers intend to manage their subscriptions and billing details. Integration guide: [Billing customer portal](/docs/billing/subscriptions/integrating-customer-portal).
METHODS
id string
Unique identifier for the object.
object string
String representing the object's type. Objects of the same type share the same value.
configuration string
Expandable to Net::API::Stripe::Billing::PortalConfiguration
The configuration used by this session, describing the features available.
created timestamp
Time at which the object was created. Measured in seconds since the Unix epoch.
customer string
The ID of the customer for this session.
livemode boolean
Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
locale enum
The IETF language tag of the locale Customer Portal is displayed in (e.g. ja
or en-GB
. If blank or set to auto
, the customer’s preferred_locales
or browser’s locale is used.
on_behalf_of string
Connect only
The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this on_behalf_of
account appear in the portal. For more information, see the docs. Use the Accounts API to modify the on_behalf_of
account’s branding settings, which the portal displays.
return_url string
The URL to which Stripe should send customers when they click on the link to return to your website.
url string
The short-lived URL of the session giving customers access to the customer portal.
API SAMPLE
{
"id": "bps_1LK7CQCeyNCl6fY2zTGZOzQa",
"object": "billing_portal.session",
"configuration": "bpc_1LK7CQCeyNCl6fY2ESFdGr6O",
"created": 1657486674,
"customer": "cus_AODr7KhjWjH7Yk",
"livemode": true,
"locale": null,
"on_behalf_of": null,
"return_url": "https://example.com/account",
"url": "https://billing.stripe.com/session/{SESSION_SECRET}"
}
HISTORY
v0.1.0
Initial version
AUTHOR
Jacques Deguest <jack@deguest.jp>
SEE ALSO
Stripe API documentation:
https://stripe.com/docs/api#portal_session_object
COPYRIGHT & LICENSE
Copyright (c) 2019-2022 DEGUEST Pte. Ltd.
You can use, copy, modify and redistribute this package and associated files under the same terms as Perl itself.