# Playbook: a monthly plan paid by card automatically

Sell a monthly plan on a quote, let the customer's first payment save their card, and have every later invoice charged automatically, with a dated timeline that includes one declined charge and its retries.

Source: https://support.rework.com/article/commerce-playbook-autopay

> **In plain words:** This playbook takes you from a blank workspace to a monthly subscription that runs without you. Each month Commerce creates the invoice, emails it, charges the customer's saved card on the due date, and marks the invoice paid. If a card is declined, Commerce tries again on its own. Follow the steps in order, once, and then only watch.

**Who this is for:** a seller who bills a customer the same amount every month and wants the card charged automatically. **What you'll have at the end:** a running subscription with a saved card, automatic invoicing and automatic charging, and a clear picture of what happens when a card is declined. **Time:** about 30 minutes the first time, most of it one-off setup you reuse for every later subscription.

## Why this matters

Without autopay, every invoice depends on the customer remembering to click a link. Some pay late, a few forget, and you spend time chasing. With autopay the customer agrees once, while paying the first invoice. The money arrives on the due date, and you only handle exceptions.

This playbook follows a fictional seller, **Northwind Analytics**, a small software company. It sells a Team plan at 49 per month to **Bluebird Bakery**, with a payment due 15 days after each invoice.

## Words used in this playbook

- **Subscription:** an agreement to bill the same customer again and again. See [Subscriptions](https://support.rework.com/article/commerce-subscriptions-overview).
  
- **Cycle invoice:** the invoice for one billing period, created by Commerce.
  
- **Saved card:** the card the customer allowed you to charge again. Stripe keeps it.
  
- **Stripe:** the online payment provider that keeps the saved card. See [Connect Stripe](https://support.rework.com/article/commerce-connect-stripe).
  
- **Service:** a configured folder of one kind of record, such as a subscription service or an invoice service. See [Services](https://support.rework.com/article/commerce-services).
  
- **Due date:** the day an invoice should be paid by. Autopay charges on or just after it.
  

## Before you start

- You are a workspace admin, so you can open **Settings** and the service settings.
  
- You have a Stripe account with live keys, or test keys in a sandbox workspace.
  
- A subscription service, an invoice service, a payment service and a legal entity exist. If not, see [Services](https://support.rework.com/article/commerce-services) and [Legal entities](https://support.rework.com/article/commerce-legal-entities).
  
- The customer exists as an account with an email contact. See [Customer accounts](https://support.rework.com/article/commerce-customer-accounts).
  
- You have read [Autopay](https://support.rework.com/article/commerce-autopay) once, so the terms are familiar.
  
- The customer will pay the first invoice by card online. That payment is what saves the card.
  

## Steps

### Step 1: Connect Stripe

1. In Commerce, click **Settings** at the bottom of the left icon rail, then **Payment accounts** under **Accounts & integrations**.
   
2. Click **New account**, then **Stripe**.
   
3. Fill in **Name**, **Secret key** and **Webhook signing secret**, as described in [Connect Stripe](https://support.rework.com/article/commerce-connect-stripe).
   
4. Click **Create account**. You see the account in the table with the status **Enabled**.
   

### Step 2: Give your payment service the Stripe account

1. Click **Payment** in the left icon rail, then your payment service in the sidebar.
   
2. Click **Service settings** at the bottom of the sidebar, then **Payment accounts** under **Operations**.
   
3. Turn on **Online gateways** and tick your Stripe account.
   
4. Click **Save payment accounts**.
   

### Step 3: Point the invoice service at that payment service

1. Click **Invoice** in the left icon rail, then your invoice service in the sidebar.
   
2. Click **Service settings**, then **Payment**.
   
3. Under **Payment processor**, choose your payment service.
   
4. Click **Save collection**.
   

### Step 4: Make cycle invoices issue and email themselves

1. Click **Subs** in the left icon rail, then your subscription service in the sidebar.
   
2. Click **Service settings**, then **Billing**.
   
3. Under **Invoice book**, choose the invoice service from step 3.
   
4. Set **Invoice each cycle** to **At the start of the period (in advance)**. Services created in the app already use this setting. It applies to subscriptions started after you save. Cycle 1 is then invoiced the moment you start the subscription.
   
5. Set **When a cycle comes due** to **Draft + issue + email the customer (with pay link)**. Autopay only charges issued invoices, so this setting is what makes the whole chain run.
   
6. Click **Save billing**. You see "Billing settings saved".
   

> **Important:** The default mode, **Draft the cycle invoice automatically**, leaves invoices as drafts nobody issues. Autopay never charges a draft.

### Step 5: Sell it on a quote with Charge automatically

1. Click **Quotes** in the left icon rail, then **New quote**, and pick your quote service. See [Create a quote](https://support.rework.com/article/commerce-create-quote).
   
2. Choose **Bluebird Bakery** as the customer.
   
3. Add the line: Team plan, quantity 1, 49 per month. A recurring line is what makes **Charge automatically** available.
   
4. In the payment step, look under **Collection**. **Charge automatically** is already selected. A note says "The customer's card is saved when they pay, and later invoices are charged to it automatically." Choose **Net 15** for the payment terms.
   
5. Send the quote. See [Send and share a quote](https://support.rework.com/article/commerce-send-quote).
   

If **Charge automatically** is greyed out, read the sentence under it. It names the step above that is missing.

### Step 6: The customer accepts and pays

1. Bluebird Bakery opens the link, accepts the quote and clicks to pay.
   
2. Above the pay button they read "By paying, you allow Northwind Analytics to save this payment method and charge it automatically for each monthly invoice of the quote." There is nothing to tick: paying is the agreement.
   
3. They pay by card. The card is saved with the payment.
   
4. On your quote, the right column shows **Charges automatically** with the card brand and last four digits.
   

### Step 7: Convert and start

1. On the quote, click **Convert to subscription** and follow the dialog. See [Create a subscription](https://support.rework.com/article/commerce-create-subscription) for the start date and term.
   
2. The card moves to the new subscription, and the subscription is already on automatic collection. If the dialog says the card cannot be used, the card's gateway is not on this subscription's payment chain. The invoices then wait for a new card.
   
3. Click **Start** on the subscription. Commerce bills cycle 1 at once: an invoice for 49 is created, issued and emailed with a pay link. The due date is 15 days away.
   
4. In the right column, check that the card reads **Charged automatically at the due date**.
   

## The timeline: one month with a declined charge

Dates are examples. Commerce checks every hour. Here cycle 1 is invoiced on 1 March, due 16 March.

| 
Date

 | 

What Commerce does

 | 

What you do

 |
| --- | --- | --- |
| 

26 Feb

 | 

The quote is accepted and paid. The card is saved.

 | 

Send the quote.

 |
| 

27 Feb

 | 

The card moves to the subscription.

 | 

Convert, then **Start** on 1 March.

 |
| 

1 Mar

 | 

Cycle 1 is invoiced for 49, issued and emailed. Due 16 Mar.

 | 

Nothing.

 |
| 

16 Mar

 | 

**Attempt 1.** The bank declines (not enough funds). The customer is emailed with an update-card link.

 | 

Nothing.

 |
| 

17 Mar

 | 

**Attempt 2.** The charge succeeds. The invoice shows **Paid automatically**.

 | 

Nothing.

 |
| 

1 Apr

 | 

Cycle 2 is invoiced for 49 and emailed. Due 16 Apr.

 | 

Nothing.

 |
| 

16 Apr

 | 

The card is charged. Paid.

 | 

Nothing.

 |

### If every attempt fails

Commerce makes four attempts: on the due date, then 1, 3 and 7 days after it.

| 
Date

 | 

What happens

 |
| --- | --- |
| 

16, 17, 19 and 23 Mar

 | 

Four declined attempts. The customer is emailed after the first, the second and the last.

 |
| 

23 Mar

 | 

No attempts are left. The invoice shows **Waiting for a payment method**. Collection stays automatic, and overdue reminders do not take over.

 |
| 

Any day after

 | 

When the customer adds a new card, the invoice is charged again within the hour. You can also send them a pay link by hand.

 |

The subscription keeps running. Cycle 2 is invoiced on 1 April as usual. Use the **No card on file** filter on the **Subs** list to see which customers still need to add a card.

If the bank answers that the customer must confirm the payment themselves, or the card was removed, charging pauses at once and the customer is asked for a new card.

## Check it worked

1. Open the invoice from 1 March. After the charge it shows **Paid automatically**, with the payment listed under **Collection**.
   
2. Open the subscription. **Collected** equals what you billed, and **Open A/R** is 0.
   
3. Open the **Activity** tab and read the lines about the card and the charge.
   
4. In the right column, confirm **Charged automatically at the due date**.
   

## Troubleshooting

| 
Problem

 | 

Why it happens

 | 

What to do

 |
| --- | --- | --- |
| 

**Charge automatically** is greyed out on the quote.

 | 

The payment chain is incomplete, or the quote has no recurring line.

 | 

Read the sentence under the option. Repeat steps 1 to 3, or add a recurring line.

 |
| 

The invoice was created but never charged.

 | 

It stayed a draft because of the default billing mode.

 | 

Set **When a cycle comes due** to an issue mode (step 4). Issue the draft by hand once.

 |
| 

The invoice says **Waiting for a payment method**.

 | 

The card was declined on every attempt or was removed.

 | 

Wait for the customer to use the update-card link, or send them a pay link.

 |
| 

The subscription shows **No card on file**.

 | 

The customer paid the quote another way, or the card could not move at Convert.

 | 

Turn on **Charge automatically**, click **Copy customer's update link** on the subscription and send it. Paying an invoice with a card also saves the card.

 |
| 

The first invoice was not created at **Start**.

 | 

**Invoice each cycle** is set to the end of the period.

 | 

Use **At the start of the period (in advance)**, or bill with **Bill now**.

 |
