Stripe.PaymentLink (stripity_stripe v2.17.2) View Source
Work with Stripe payment_link
objects.
You can:
Link to this section Summary
Functions
Creates a payment link.
Returns a list of PaymentLinks.
Returns a list of PaymentLink's Line Items.
Retrieves the details of a PaymentLink that has previously been created.
Updates a PaymentLink object.
Link to this section Types
Specs
Specs
line_items() :: %{ price: Stripe.id(), quantity: non_neg_integer(), adjustable_quantity: map() }
Specs
t() :: %Stripe.PaymentLink{ active: boolean(), after_completion: after_completion(), allow_promotion_codes: boolean(), application_fee_amount: non_neg_integer() | nil, application_fee_percent: non_neg_integer() | nil, automatic_tax: map(), billing_address_collection: [String.t()], id: Stripe.id(), livemode: boolean(), metadata: Stripe.Types.metadata(), object: String.t(), on_behalf_of: String.t() | nil, payment_method_types: [String.t()] | nil, phone_number_collection: map(), shipping_address_collection: map() | nil, subscription_data: map() | nil, transfer_data: transfer_data() | nil, url: String.t() }
Specs
transfer_data() :: %{destination: String.t()}
Link to this section Functions
Specs
create(params) :: {:ok, t()} | {:error, Stripe.Error.t()} when params: %{ :line_items => [line_items()], optional(:metadata) => map(), optional(:payment_method_types) => [String.t()], optional(:after_completion) => after_completion(), optional(:allow_promotion_codes) => boolean(), optional(:application_fee_amount) => pos_integer(), optional(:application_fee_percent) => pos_integer(), optional(:automatic_tax) => map(), optional(:billing_address_collection) => [String.t()], optional(:on_behalf_of) => map(), optional(:phone_number_collection) => map(), optional(:shipping_address_collection) => map(), optional(:subscription_data) => map(), optional(:transfer_data) => transfer_data() } | %{}
Creates a payment link.
Specs
list(params) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.Error.t()} when params: %{ optional(:active) => boolean(), optional(:ending_before) => Stripe.id(), optional(:limit) => pos_integer(), optional(:starting_after) => Stripe.id() }
Returns a list of PaymentLinks.
Specs
list_line_items(Stripe.id() | t(), params) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.Error.t()} when params: %{ optional(:ending_before) => Stripe.id(), optional(:limit) => pos_integer(), optional(:starting_after) => Stripe.id() }
Returns a list of PaymentLink's Line Items.
Specs
retrieve(Stripe.id()) :: {:ok, t()} | {:error, Stripe.Error.t()}
Retrieves the details of a PaymentLink that has previously been created.
Specs
update(Stripe.id() | t(), params) :: {:ok, t()} | {:error, Stripe.Error.t()} when params: %{ optional(:active) => boolean(), optional(:line_items) => [line_items()], optional(:metadata) => map(), optional(:payment_method_types) => [String.t()], optional(:after_completion) => after_completion(), optional(:allow_promotion_codes) => boolean(), optional(:automatic_tax) => map(), optional(:billing_address_collection) => [String.t()], optional(:shipping_address_collection) => map() } | %{}
Updates a PaymentLink object.