create_customer: Create a customer

Description Usage Arguments Details Value See Also

View source: R/customer.R

Description

Create a customer

Usage

1
2
3
4
create_customer(idempotency, account_balance = NULL, coupon = NULL,
  description = NULL, email = NULL, metadata = NULL, plan = NULL,
  quantity = NULL, shipping = NULL, source = NULL,
  tax_percent = NULL, trial_end = NULL)

Arguments

idempotency

A random string to ensure no repeat charges

account_balance

Integer amount in pence

coupon

A discount on recurring charges

description

Arbitary string

email

customer's email address

metadata

A named list

plan

ID of the plan to subscribe customer to

quantity

Quantity to apply to subscription. Needs plan.

shipping

Optional dictionary

source

A token from get_token

tax_percent

A positive decimal. Percentage added as tax.

trial_end

Unix timestamp when trial period ends. Needs plan.

Details

Setting account_balance to negative means the customer will have a credit. A positive amount means it will be added to the next invoice.

description, email, metadata will be set to empty if you POST an empty value.

Value

List object

See Also

Other customers: delete_customer, get_customer, list_customers, update_customer


MarkEdmondson1234/stripeR documentation built on Nov. 6, 2019, 3:21 p.m.