Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Braintree

Braintree is a payments platform by PayPal. Process sale transactions, refunds, and voids, and manage customers and subscriptions.

Connectors

Choose the connector that matches your authentication method. The options below use the names shown in StackAI.

Connector
Authentication

Braintree

Credentials

Braintree

Connect to the Braintree payments platform (a PayPal service) to process transactions and manage customers via the GraphQL API.

Set up in Braintree

  1. Prepare the Braintree account or service that the workflow will access. Grant access to the required resources and operations.

  2. Public Key: Your Braintree public key, from the Control Panel under Settings > API Keys.

  3. Private Key: Your Braintree private key, from the Control Panel under Settings > API Keys.

Set up in StackAI

  1. Open Settings → Connections, add a connection, and select Braintree.

  2. Enter the credentials and connection details in the fields below.

  3. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

Connection fields

StackAI field
Required
What to enter

Public Key

Yes

Your Braintree public key, from the Control Panel under Settings > API Keys.

Private Key

Yes

Your Braintree private key, from the Control Panel under Settings > API Keys.

Sandbox

Optional / as applicable

Connect to the Braintree sandbox environment instead of production. API keys are environment-specific: enable this only for a sandbox keypair. Provider instructions.

Verify the connection

Check that the connection is healthy. Then run a read operation against a resource the connected account can access. A successful connection check confirms authentication; it does not guarantee permission for every action.

If access is denied, check the credential or OAuth permissions, the selected account or environment, and access to the specific resource. Update expired credentials or reconnect after permissions change.

Use an action

  1. Add the required Braintree action to the workflow.

  2. Select a connection when the action requests one.

  3. Complete the required fields. Use the reference picker when a value comes from another workflow step.

  4. Run the workflow and inspect the action’s output. Check the result before using it in a later step.

Actions

Create Transaction

Charge a payment method to create a Braintree sale transaction.

Inputs

Field
Type
Required
Description

Payment Method ID

string

Yes

Single-use or vaulted payment method to charge.

Amount

string

Yes

Amount to charge, as a decimal string.

Order ID

string

No

Optional merchant-defined order reference.

Customer ID

string

No

Optional Braintree customer to associate with the charge.

Merchant Account ID

string

No

Optional merchant account to process the charge with.

Idempotency Key

string

No

Optional idempotency key to prevent double-charging on retries.

Outputs

Field
Type
Description

Transaction ID

string

GraphQL ID of the created transaction.

Status

string

Status of the transaction (e.g. SUBMITTED_FOR_SETTLEMENT).

Transaction

object

The created transaction.

Refund Transaction

Refund a settled Braintree transaction, fully or partially.

Inputs

Field
Type
Required
Description

Transaction ID

string

Yes

The settled transaction to refund.

Amount

string

No

Optional partial-refund amount; leave empty for a full refund.

Order ID

string

No

Optional merchant-defined reference stored on the refund.

Idempotency Key

string

No

Optional idempotency key to prevent duplicate refunds on retries.

Outputs

Field
Type
Description

Refund ID

string

GraphQL ID of the created refund.

Status

string

Status of the refund (e.g. SUBMITTED_FOR_SETTLEMENT).

Refund

object

The created refund.

Create Customer

Create a new customer in the Braintree vault.

Inputs

Field
Type
Required
Description

First Name

string

No

Customer's first name.

Last Name

string

No

Customer's last name.

Email

string

No

Customer's email address.

Company

string

No

Customer's company name.

Phone Number

string

No

Customer's phone number.

Outputs

Field
Type
Description

Customer ID

string

GraphQL ID of the created customer.

Legacy ID

string

Legacy (Control Panel) ID of the created customer.

Customer

object

The created customer.

Void Transaction

Void an unsettled Braintree transaction, e.g. when an order is canceled.

Inputs

Field
Type
Required
Description

Transaction ID

string

Yes

The unsettled transaction to void.

Idempotency Key

string

No

Optional idempotency key to prevent duplicate reversals on retries.

Outputs

Field
Type
Description

Reversal ID

string

GraphQL ID of the voided transaction or resulting refund.

Reversal Type

string

'Transaction' when voided; 'Refund' when it had settled.

Status

string

Status of the reversal (e.g. VOIDED).

Reversal

object

The voided transaction or resulting refund.

Vault Payment Method

Store a single-use payment method in the Braintree vault for reuse.

Inputs

Field
Type
Required
Description

Payment Method ID

string

Yes

The single-use payment method to vault.

Customer ID

string

No

Optional customer to attach the vaulted payment method to.

Outputs

Field
Type
Description

Vaulted Payment Method ID

string

The permanent multi-use payment method ID.

Payment Method

object

The vaulted payment method.

Create Subscription

Enroll a payment method in a Braintree recurring subscription plan.

Inputs

Field
Type
Required
Description

Plan ID

string

Yes

The subscription plan to enroll the customer in.

Payment Method ID

string

Yes

Single-use or vaulted payment method to bill.

Price

string

No

Optional price override; leave empty to use the plan's price.

Merchant Account ID

string

No

Optional merchant account for the subscription's transactions.

Number of Billing Cycles

integer

No

Optional total billing cycles; leave empty to bill indefinitely.

Outputs

Field
Type
Description

Subscription ID

string

GraphQL ID of the created subscription.

Status

string

Status of the subscription (e.g. ACTIVE).

Subscription

object

The created subscription.

Important behavior

Actions that create, update, send, or delete data can change the connected service. Review their inputs before running them. A retry can repeat an operation; consider this when configuring retries for actions that change data.

The catalog lists the fields and capabilities available in the supplied provider definition. Availability can also depend on your deployment and organization’s Feature Access settings.

Last updated

Was this helpful?