Class: Stripe::PaymentLink::CreateParams
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::PaymentLink::CreateParams
- Defined in:
- lib/stripe/resources/payment_link.rb
Defined Under Namespace
Classes: AfterCompletion, AutomaticTax, ConsentCollection, CustomField, CustomText, InvoiceCreation, LineItem, PaymentIntentData, PhoneNumberCollection, Restrictions, ShippingAddressCollection, ShippingOption, SubscriptionData, TaxIdCollection, TransferData
Instance Attribute Summary collapse
-
#after_completion ⇒ Object
Behavior after the purchase is complete.
-
#allow_promotion_codes ⇒ Object
Enables user redeemable promotion codes.
-
#application_fee_amount ⇒ Object
The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner’s Stripe account.
-
#application_fee_percent ⇒ Object
A non-negative decimal between 0 and 100, with at most two decimal places.
-
#automatic_tax ⇒ Object
Configuration for automatic tax collection.
-
#billing_address_collection ⇒ Object
Configuration for collecting the customer’s billing address.
-
#consent_collection ⇒ Object
Configure fields to gather active consent from customers.
-
#currency ⇒ Object
Three-letter [ISO currency code](www.iso.org/iso-4217-currency-codes.html), in lowercase.
-
#custom_fields ⇒ Object
Collect additional information from your customer using custom fields.
-
#custom_text ⇒ Object
Display additional text for your customers using custom text.
-
#customer_creation ⇒ Object
Configures whether [checkout sessions](stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](stripe.com/docs/api/customers).
-
#expand ⇒ Object
Specifies which fields in the response should be expanded.
-
#inactive_message ⇒ Object
The custom message to be displayed to a customer when a payment link is no longer active.
-
#invoice_creation ⇒ Object
Generate a post-purchase Invoice for one-time payments.
-
#line_items ⇒ Object
The line items representing what is being sold.
-
#metadata ⇒ Object
Set of [key-value pairs](stripe.com/docs/api/metadata) that you can attach to an object.
-
#on_behalf_of ⇒ Object
The account on behalf of which to charge.
-
#payment_intent_data ⇒ Object
A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in ‘payment` mode.
-
#payment_method_collection ⇒ Object
Specify whether Checkout should collect a payment method.
-
#payment_method_types ⇒ Object
The list of payment method types that customers can use.
-
#phone_number_collection ⇒ Object
Controls phone number collection settings during checkout.
-
#restrictions ⇒ Object
Settings that restrict the usage of a payment link.
-
#shipping_address_collection ⇒ Object
Configuration for collecting the customer’s shipping address.
-
#shipping_options ⇒ Object
The shipping rate options to apply to [checkout sessions](stripe.com/docs/api/checkout/sessions) created by this payment link.
-
#submit_type ⇒ Object
Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button.
-
#subscription_data ⇒ Object
When creating a subscription, the specified configuration data will be used.
-
#tax_id_collection ⇒ Object
Controls tax ID collection during checkout.
-
#transfer_data ⇒ Object
The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
Instance Method Summary collapse
Methods inherited from RequestParams
Constructor Details
#initialize(after_completion: nil, allow_promotion_codes: nil, application_fee_amount: nil, application_fee_percent: nil, automatic_tax: nil, billing_address_collection: nil, consent_collection: nil, currency: nil, custom_fields: nil, custom_text: nil, customer_creation: nil, expand: nil, inactive_message: nil, invoice_creation: nil, line_items: nil, metadata: nil, on_behalf_of: nil, payment_intent_data: nil, payment_method_collection: nil, payment_method_types: nil, phone_number_collection: nil, restrictions: nil, shipping_address_collection: nil, shipping_options: nil, submit_type: nil, subscription_data: nil, tax_id_collection: nil, transfer_data: nil) ⇒ CreateParams
Returns a new instance of CreateParams.
1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 |
# File 'lib/stripe/resources/payment_link.rb', line 1000 def initialize( after_completion: nil, allow_promotion_codes: nil, application_fee_amount: nil, application_fee_percent: nil, automatic_tax: nil, billing_address_collection: nil, consent_collection: nil, currency: nil, custom_fields: nil, custom_text: nil, customer_creation: nil, expand: nil, inactive_message: nil, invoice_creation: nil, line_items: nil, metadata: nil, on_behalf_of: nil, payment_intent_data: nil, payment_method_collection: nil, payment_method_types: nil, phone_number_collection: nil, restrictions: nil, shipping_address_collection: nil, shipping_options: nil, submit_type: nil, subscription_data: nil, tax_id_collection: nil, transfer_data: nil ) @after_completion = after_completion @allow_promotion_codes = allow_promotion_codes @application_fee_amount = application_fee_amount @application_fee_percent = application_fee_percent @automatic_tax = automatic_tax @billing_address_collection = billing_address_collection @consent_collection = @currency = currency @custom_fields = custom_fields @custom_text = custom_text @customer_creation = customer_creation @expand = @inactive_message = @invoice_creation = invoice_creation @line_items = line_items @metadata = @on_behalf_of = on_behalf_of @payment_intent_data = payment_intent_data @payment_method_collection = payment_method_collection @payment_method_types = payment_method_types @phone_number_collection = phone_number_collection @restrictions = restrictions @shipping_address_collection = shipping_address_collection @shipping_options = @submit_type = submit_type @subscription_data = subscription_data @tax_id_collection = tax_id_collection @transfer_data = transfer_data end |
Instance Attribute Details
#after_completion ⇒ Object
Behavior after the purchase is complete.
911 912 913 |
# File 'lib/stripe/resources/payment_link.rb', line 911 def after_completion @after_completion end |
#allow_promotion_codes ⇒ Object
Enables user redeemable promotion codes.
914 915 916 |
# File 'lib/stripe/resources/payment_link.rb', line 914 def allow_promotion_codes @allow_promotion_codes end |
#application_fee_amount ⇒ Object
The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner’s Stripe account. Can only be applied when there are no line items with recurring prices.
917 918 919 |
# File 'lib/stripe/resources/payment_link.rb', line 917 def application_fee_amount @application_fee_amount end |
#application_fee_percent ⇒ Object
A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner’s Stripe account. There must be at least 1 line item with a recurring price to use this field.
920 921 922 |
# File 'lib/stripe/resources/payment_link.rb', line 920 def application_fee_percent @application_fee_percent end |
#automatic_tax ⇒ Object
Configuration for automatic tax collection.
923 924 925 |
# File 'lib/stripe/resources/payment_link.rb', line 923 def automatic_tax @automatic_tax end |
#billing_address_collection ⇒ Object
Configuration for collecting the customer’s billing address. Defaults to ‘auto`.
926 927 928 |
# File 'lib/stripe/resources/payment_link.rb', line 926 def billing_address_collection @billing_address_collection end |
#consent_collection ⇒ Object
Configure fields to gather active consent from customers.
929 930 931 |
# File 'lib/stripe/resources/payment_link.rb', line 929 def @consent_collection end |
#currency ⇒ Object
Three-letter [ISO currency code](www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](stripe.com/docs/currencies) and supported by each line item’s price.
932 933 934 |
# File 'lib/stripe/resources/payment_link.rb', line 932 def currency @currency end |
#custom_fields ⇒ Object
Collect additional information from your customer using custom fields. Up to 3 fields are supported.
935 936 937 |
# File 'lib/stripe/resources/payment_link.rb', line 935 def custom_fields @custom_fields end |
#custom_text ⇒ Object
Display additional text for your customers using custom text.
938 939 940 |
# File 'lib/stripe/resources/payment_link.rb', line 938 def custom_text @custom_text end |
#customer_creation ⇒ Object
Configures whether [checkout sessions](stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](stripe.com/docs/api/customers).
941 942 943 |
# File 'lib/stripe/resources/payment_link.rb', line 941 def customer_creation @customer_creation end |
#expand ⇒ Object
Specifies which fields in the response should be expanded.
944 945 946 |
# File 'lib/stripe/resources/payment_link.rb', line 944 def @expand end |
#inactive_message ⇒ Object
The custom message to be displayed to a customer when a payment link is no longer active.
947 948 949 |
# File 'lib/stripe/resources/payment_link.rb', line 947 def @inactive_message end |
#invoice_creation ⇒ Object
Generate a post-purchase Invoice for one-time payments.
950 951 952 |
# File 'lib/stripe/resources/payment_link.rb', line 950 def invoice_creation @invoice_creation end |
#line_items ⇒ Object
The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
953 954 955 |
# File 'lib/stripe/resources/payment_link.rb', line 953 def line_items @line_items end |
#metadata ⇒ Object
Set of [key-value pairs](stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to ‘metadata`. Metadata associated with this Payment Link will automatically be copied to [checkout sessions](stripe.com/docs/api/checkout/sessions) created by this payment link.
956 957 958 |
# File 'lib/stripe/resources/payment_link.rb', line 956 def @metadata end |
#on_behalf_of ⇒ Object
The account on behalf of which to charge.
959 960 961 |
# File 'lib/stripe/resources/payment_link.rb', line 959 def on_behalf_of @on_behalf_of end |
#payment_intent_data ⇒ Object
A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in ‘payment` mode.
962 963 964 |
# File 'lib/stripe/resources/payment_link.rb', line 962 def payment_intent_data @payment_intent_data end |
#payment_method_collection ⇒ Object
Specify whether Checkout should collect a payment method. When set to ‘if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
Can only be set in ‘subscription` mode. Defaults to `always`.
If you’d like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](stripe.com/docs/payments/checkout/free-trials).
969 970 971 |
# File 'lib/stripe/resources/payment_link.rb', line 969 def payment_method_collection @payment_method_collection end |
#payment_method_types ⇒ Object
The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
972 973 974 |
# File 'lib/stripe/resources/payment_link.rb', line 972 def payment_method_types @payment_method_types end |
#phone_number_collection ⇒ Object
Controls phone number collection settings during checkout.
We recommend that you review your privacy policy and check with your legal contacts.
977 978 979 |
# File 'lib/stripe/resources/payment_link.rb', line 977 def phone_number_collection @phone_number_collection end |
#restrictions ⇒ Object
Settings that restrict the usage of a payment link.
980 981 982 |
# File 'lib/stripe/resources/payment_link.rb', line 980 def restrictions @restrictions end |
#shipping_address_collection ⇒ Object
Configuration for collecting the customer’s shipping address.
983 984 985 |
# File 'lib/stripe/resources/payment_link.rb', line 983 def shipping_address_collection @shipping_address_collection end |
#shipping_options ⇒ Object
The shipping rate options to apply to [checkout sessions](stripe.com/docs/api/checkout/sessions) created by this payment link.
986 987 988 |
# File 'lib/stripe/resources/payment_link.rb', line 986 def @shipping_options end |
#submit_type ⇒ Object
Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](stripe.com/docs/api/payment_links/payment_links/object#url) property (example: ‘donate.stripe.com`).
989 990 991 |
# File 'lib/stripe/resources/payment_link.rb', line 989 def submit_type @submit_type end |
#subscription_data ⇒ Object
When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use ‘subscription_data`.
992 993 994 |
# File 'lib/stripe/resources/payment_link.rb', line 992 def subscription_data @subscription_data end |
#tax_id_collection ⇒ Object
Controls tax ID collection during checkout.
995 996 997 |
# File 'lib/stripe/resources/payment_link.rb', line 995 def tax_id_collection @tax_id_collection end |
#transfer_data ⇒ Object
The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
998 999 1000 |
# File 'lib/stripe/resources/payment_link.rb', line 998 def transfer_data @transfer_data end |