Skip to content

V. Helpful Information

Mark Borja Gutierrez edited this page Sep 30, 2026 · 12 revisions

High-Code Tutorials

If you have a customer with an active Subscription and you would like their saved payment method to appear for their checkout pages, you can do it via bench console. Follow the steps below. Note: Communicate this to your customer beforehand to avoid issues.

  1. Go to your stripe.com dashboard.
  2. From the sidebar, click Subscriptions.
  3. In the list, click the customer's subscription to view the details.
  4. Scan the page for the payment method ID with the format: pmc_xxxxxxxxxx (usually found at the right sidebar).
  5. Copy the ID.
  6. Run bench --site <your_site> console in terminal.
  7. In the console, run these commands:
    • import stripe
    • doc = frappe.get_doc("Stripe Settings", <stripe_settings_doc_name>)
    • stripe.api_key = doc.get_password('secret_key')
    • stripe.PaymentMethod.modify(<payment_method_id>, allow_redisplay='always')
      • This command instructs the payment method to be displayed to the user again because by the default it is hidden.
  8. If the modification is successful, a dict will be displayed in the console; otherwise, an error message.

Stripe Plus Automation Workflows

There are two automation workflows that Stripe Plus facilitates—one for customer payments and one for payouts.

Customer Payment Workflow

The Customer Payment workflow starts with a Payment Request (sent to the customer via email). The email has a link where the customer can pay through Stripe. Once the customer completes the payment, Stripe will notify your site in the form of a webhook. This webhook event will then be logged through Stripe Log and will be recorded as a Stripe Transaction doc. If multiple events refer to the same transaction, the Stripe Transaction doc will just be updated instead of being created again. Afterwards, a confirmation email will be sent to the customer whether the transaction concerns a Charge; otherwise, no succeeding action will be done. After the email is sent, a Merchant Payment doc will be made/updated. And if the Charge has the status succeeded, it will proceed to the accounting workflow.

The Charge will be checked whether it’s a payment for a Sales Invoice or a Sales Order. If it’s the former, a Payment Entry will be created and no further action will ensue. If it’s the latter, the Payment Request will be checked for the do_not_create_sales_invoice value. If the value is 1 (checked), a Payment Entry will be created; otherwise, a Sales Invoice will be created first.

Customer Payment Workflow

Stripe Payout Workflow

When a Stripe Payout is close to being paid, Stripe will notify your site in the form of a webhook. The webhook event is logged through Stripe Log and will be recorded as a Stripe Payout doc. If the Payout status is paid, all the Stripe Transaction docs involved in the payout will be updated. Afterwards, a computation will be performed to determine whether there are additional charges and adjustments that Stripe Plus may not have accounted for. The computation will then be compared to the total sent by Stripe. If the totals match, a Journal Entry will be created. If there are discrepancies in the totals, the user will be notified of it through email.

Stripe Payout Workflow

Auto Repeat and Subscription Stripe Plus

With Stripe Plus, accounting in both Auto Repeat and Subscription can be streamlined. Each doctype can be uniquely configured to use Stripe and automate generation of Payment Request or Payment Entries.

Auto Repeat with Stripe Plus

In Auto Repeat, Stripe Plus automates the workflow by sending a Payment Request email instead of the default templated email. The Payment Request can be customized further to use a payment gateway account, similar to manually made requests.The advantage of using Auto Repeat with Stripe Plus is the hands-free accomplishment of (1) generating a recurring Sales Invoice, (2) making a Payment Request, and (3) creating a Payment Entry.

Subscription with Stripe Plus

In Subscription, Stripe Plus automates the workflow by facilitating an automatic payment with a one-time setup. After a payment method is authorized and registered, the Customer will be charged every new billing period of the Subscription. In every charge, a Payment Entry is created and assigned to a Sales Invoice generated by the Subscription.

Auto Repeat vs Subscription

Auto Repeat is best applied to billings where the Customer has to pay every time a Sales Invoice is created. Subscription is best used for consistent billing and automatic payments.

Clone this wiki locally