> For the complete documentation index, see [llms.txt](https://help.orderdesk.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.orderdesk.com/integration-setup-guides/payment-gateways/braintree-integration.md).

# Braintree Integration

Order Desk can connect to [Braintree](https://www.braintreepayments.com/) to allow you to process refunds on your orders from within Order Desk.

### Setup

To connect to Braintree, click on the **Manage Integrations** link in the left sidebar and under the **Gateways** tab find and enable the Braintree integration.

![](https://251457507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQOLMUJWMYtrpQ7Oxxca%2Fuploads%2FM4oo2TZkZbQh3onMOqLE%2Flegacy-6b57153bc6ff1d28add1.png?alt=media)

Once enabled, enter your **Braintree Merchant ID, Public Key, and Private Key**:

To find your Braintree credentials, please contact your rep from Braintree. **Order Desk support is not able to help with finding or resetting your Braintree credentials**, as they are created and provided by Braintree.

![](https://251457507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQOLMUJWMYtrpQ7Oxxca%2Fuploads%2Fag7o6YyVua4tOLWWpVoT%2Flegacy-ae53bfea3168e6bd47f6.png?alt=media)

#### Processing Servers

Set your environment to Production or Sandbox (Test)

#### Default Payment Status

Use to select the default status of payments captured with Braintree. Typically the default payment status is **Captured**..

### Refunding Braintree Payments Manually

As long as an order has a Braintree Transaction ID as the processor response, the option to process a full or partial refund can be found on the order details page.

Add the amount to be refunded for the order and click the Refund button:

![](https://251457507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQOLMUJWMYtrpQ7Oxxca%2Fuploads%2FEUHjykMXCtzguBQb7F1Z%2Flegacy-9d5701ba7e72eba3bcd4.png?alt=media)

### Using Braintree with Rules

In the Rule Builder, search the event and action dropdown menus for your Braintree options:

![](https://251457507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQOLMUJWMYtrpQ7Oxxca%2Fuploads%2F72eNj9W49oaEAvrLdZb5%2Flegacy-77e85a3bea6fda301259.png?alt=media)

If you are unfamiliar with how to use the Rule Builder, please refer to the [How to Work with Rules guide](/guided-walkthroughs/rules-and-automations/how-to-work-with-rules.md) for more information.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.orderdesk.com/integration-setup-guides/payment-gateways/braintree-integration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
