Create Transaction

paddle.create_transaction
ActionBusiness appsconnection required

Calls the Paddle API with the connection's credentials.

Bill a customer for one or more prices, or draft an invoice for them.

Connection

Required
Yes — the node will not save without one
Auth type
API key
Providers
Paddle
Secret shape
the Paddle API key (pdl_…), or {"api_key": "…"}
Config it needs
environment, base_url
Resolved by
config.connection_id, else node.connection_id

Configuration

11 fields, none required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.

FieldTypeRequiredDefaultConstraintsExample
items
JSON array of line items, each with a price_id and a quantity.
arrayNo—≥ 1 characters; array of object[{"price_id":"pri_01gsz8x8sawmvhz1pv30nge1ke","quantity":1}]
price_id
Shortcut for a single line item instead of filling in items.
stringNo——pri_01gsz8x8sawmvhz1pv30nge1ke
quantity
How many units of price_id to bill for.
numberConditional1≥ 1; only with price_id—
customer_id
The customer to bill; without it Paddle keeps the transaction a draft.
stringNo———
address_id
The customer address to bill, needed before an automatic charge.
stringNo———
business_id
The customer business to invoice, for B2B transactions.
stringNo———
discount_id
A discount to apply to the whole transaction.
stringNo———
currency_code
Three-letter currency to bill in.
stringNo—3–3 characters—
collection_mode
automatic to charge the saved card, manual to issue an invoice.
stringNo—one of "automatic", "manual"—
status
billed marks it a legal invoice at once; leave empty to let Paddle pick.
stringNo—one of "billed"—
custom_data
Your own key-value data to store on the transaction (JSON).
objectNo———
  • At least one of price_id, items must be set.

Example configuration

Every value below is the contract’s own example or default — nothing invented.

{
  "items": [
    {
      "price_id": "pri_01gsz8x8sawmvhz1pv30nge1ke",
      "quantity": 1
    }
  ],
  "price_id": "pri_01gsz8x8sawmvhz1pv30nge1ke",
  "quantity": 1
}

Output

One shape.

result

FieldTypeExample
id
The transaction id, prefixed txn_.
string—
status
draft, ready, billed, paid, completed, canceled or past_due.
string—
customer_id
The customer being billed, or null on a draft.
string—
subscription_id
The subscription this transaction belongs to, or null.
string—
invoice_number
Paddle's invoice number once the transaction is billed.
string—
collection_mode
automatic when Paddle charges, manual for an invoice.
string—
currency_code
Three-letter currency this is billed in.
string—
origin
What created the transaction, such as api or subscription_charge.
string—
items
The priced line items on the transaction.
array—
details
Paddle's calculated totals, tax and payout amounts.
object—
checkout
The hosted checkout, including its url.
object—
{
  "checkout": {},
  "collection_mode": "",
  "currency_code": "",
  "customer_id": "",
  "details": {},
  "id": "",
  "invoice_number": "",
  "items": [],
  "origin": "",
  "status": "",
  "subscription_id": ""
}

Notes

  • Paddle decides the status: a transaction without a customer, or without an address when collection is automatic, comes back as a draft rather than failing, so read the returned status before treating it as billed. billed is the only status this endpoint lets you ask for.

See Create Transaction run in a workflow.

In a technical demo we add the Paddle connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.