# Joy and GoodAPI

> Source: https://help.joy.so/integrations/goodapi/ · Last updated: 2026-07-30

Let customers redeem points to plant trees or remove ocean plastic — verified by GoodAPI, no discount code involved.

### Why integrate GoodAPI with Joy Loyalty?

GoodAPI (Sprout) turns real-world environmental actions — tree planting and ocean-plastic removal — into an API you can call. Connecting it to Joy adds a new kind of reward next to your discounts and free gifts:

- **Points-funded impact** — customers spend points to fund a tree or a plastic bottle removed, instead of getting a coupon
- **Verified, not promised** — every redemption is a real call to GoodAPI; Joy only confirms the reward once GoodAPI accepts it
- **Impact customers can see** — confirmed totals show up on the storefront widget, the Loyalty Hub page, and the customer's admin profile

Setup takes about 10 minutes once you have your Sprout API key.

### Before you start

You will need:

| Item                                    | Where it comes from                                                                                                                                                                                                      |
| --------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **GoodAPI (Tree Planting) Shopify app** | Installed from the [Shopify App Store](https://apps.shopify.com/tree-planting) — complete GoodAPI's own onboarding first                                                                                                 |
| **Sprout API key**                      | GoodAPI app → API section. Use a `TEST-` key while you're testing the setup, and switch to your production key before going live — keys starting with `TEST-` are sandbox keys, everything else is a live/production key |
| **GoodAPI User ID** *(optional)*        | Only needed if GoodAPI gave you a separate legacy User ID — most merchants can leave this blank                                                                                                                          |

> **Note:** **Billing is separate.** GoodAPI charges your GoodAPI account for every tree planted or plastic bottle removed. Joy does not add fees on top of those impact charges — it only spends the customer's points.

### Step 1: Connect GoodAPI in Joy

**Step 1: Copy your Sprout API key from GoodAPI**

Open the GoodAPI Shopify app and go to its API section. Copy the API key shown there (and the User ID too, if GoodAPI gave you one).

**Step 2: Paste it into Joy**

Go to **Integrations → GoodAPI**, paste the **Sprout API key** in, and click **Connect**. Joy verifies the key with GoodAPI immediately and tells you if it's invalid.

**Step 3: Confirm you're connected**

Once connected, Joy shows a masked version of your key (e.g. `TEST-••••••••ab12`) so you can confirm it's the right one, plus which key type — test or live — you're using.

[Embedded video or demo](https://app.arcade.software/share/2nP6hUuif3OF52PL1QFG)

> **Tip:** GoodAPI can also create impact automatically after every order — that automation lives entirely inside GoodAPI and runs independently of the point redemptions described below.

### Step 2: Create the environmental impact reward program

**Step 1: Add the program**

Choose **Reward programs → Redeeming programs**, then **Add program** and pick the **Environmental impact** event.

**Step 2: Choose the impact type**

Pick **Plant trees** or **Remove plastic bottles**. Only types your Sprout key supports are usable — Joy shows a warning if you pick a type your GoodAPI account isn't enabled for.

**Step 3: Set the quantity and points cost**

Enter how many trees (or bottles) each redemption funds, and how many points a customer spends to redeem — for example, *500 points → 1 tree planted*.

**Step 4**

**Add a dashboard link** *(optional)*

Paste your public GoodAPI impact dashboard URL. When set, customers see a **View impact dashboard** link next to their totals.

**Step 5: Activate the program**

Save and turn the program on. Joy blocks activation until GoodAPI is connected — you'll see a **Connect GoodAPI** banner on the program if it isn't yet.

[Embedded video or demo](https://app.arcade.software/share/SK1RSZKvIm9gfVM9rxzV)

> **Warning:** **The impact provider and type lock after the first redemption.** Once a customer has redeemed on this program, you can still edit the points cost and quantity, but you can no longer switch between trees and plastic bottles — create a second program instead if you want to offer both.

### What happens when a customer redeems

Joy deducts the customer's points immediately, then calls GoodAPI to fund the tree or bottle removal. From there:

| Outcome                                                                   | What the customer sees                                                                                                                                                    |
| ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **GoodAPI accepts the request**                                           | The redemption is confirmed and their impact total goes up right away                                                                                                     |
| **GoodAPI rejects the request** (e.g. account issue on your GoodAPI side) | Joy automatically refunds the points — nothing is deducted                                                                                                                |
| **Joy can't confirm the result** *(rare)*                                 | The tree or bottle is still funded on GoodAPI's side, but the activity briefly shows as pending in Joy while it's investigated — points are never taken back in this case |

No Shopify discount code is created for these redemptions, since there's nothing to apply at checkout — the reward is the confirmed environmental impact itself.

### Where customers see their impact

| Surface                                              | Shows                                                                                                                                                                                  | Notes                                                                                            |
| ---------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------ |
| **Storefront widget → Profile**                      | Impact card with trees + plastic bottles totals and recent activity                                                                                                                    | Shown when the customer has impact, GoodAPI is connected, and the block is enabled               |
| **Joy: Loyalty Hub page**                            | Impact section with tree total + recent tree activities                                                                                                                                | Trees only here — plastic bottle totals are covered by GoodAPI's own Shopify profile block below |
| **Shopify Customer Account → Profile**               | GoodAPI's own **Environmental Impact** card — Total Trees Planted, CO2 to be Sequestered, Impact Regions, Plastic Bottles Saved, Plastic Waste (kg), plus a **View Impact Hub** button | Comes from GoodAPI directly, not Joy — see below                                                 |
| **Activity history** (widget, Loyalty Hub, checkout) | A line per redemption, e.g. "Redeem 500 points to plant 1 tree"                                                                                                                        | Only appears once a customer has at least one impact redemption                                  |

Both the widget block and the Loyalty Hub section can be reordered or hidden — the widget block from **Branding → Widget design → Profile**, and the Loyalty Hub section from **Loyalty Hub settings**.

> **Note:** **GoodAPI ships its own block for the Shopify Customer Account Profile page.** It's a separate app block, added and customized from **Shopify admin → Settings → Customer accounts → Customize** (drag it onto the **Profile** page), not from Joy. It shows richer stats than Joy tracks — CO2 sequestered, impact regions, plastic waste in kg — pulled straight from your GoodAPI account. Add both: GoodAPI's block for the full impact story on the native Profile page, and Joy's widget/Loyalty Hub surfaces for the loyalty-program view (points spent, redemption history) tied to this program.

### Tracking performance in Joy admin

Open the environmental impact program to see:

- **Confirmed units** — total trees or bottles successfully funded through this program
- **Redemptions this month**
- **Success rate**
- A **Redemption activities** button that jumps to the filtered activity list

On any customer's profile page, an **Environmental impact** card shows their confirmed totals with a **Refresh** button — this re-checks the live totals with GoodAPI rather than only trusting Joy's stored counters, which is useful if you ever suspect the two are out of sync.

### Managing the connection

| Action                     | What happens                                                                                      |
| -------------------------- | ------------------------------------------------------------------------------------------------- |
| **Reconnect / update key** | Overwrites the saved key after re-verifying it with GoodAPI                                       |
| **Disconnect**             | Clears your credentials **and deactivates every active environmental impact program** on the shop |

> **Important:** **Disconnecting turns off every active environmental impact program.** Left active without a connection, such a program could only deduct a customer's points and immediately refund them — Joy deactivates them instead so that never happens. Reconnect and reactivate each program to resume.

### FAQ

**Do customers get a discount code for these rewards?**

No. There's nothing to apply at checkout — the reward is the confirmed tree or plastic bottle removal itself, tracked on their impact totals.

**What if I want to offer both trees and plastic bottle removal?**

Create two environmental impact programs — one per impact type. A single program can't switch types once it has a redemption.

**Why does my program say a plastic bottle isn't available even though I'm connected?**

Your Sprout API key doesn't have plastic removal enabled on the GoodAPI side. Contact GoodAPI to enable it, then reopen the program in Joy — Joy re-checks your key's features periodically.

**A customer redeemed but their impact total didn't go up. What happened?**

Check the redemption activity's status. If it refunded, GoodAPI rejected the request and the customer got their points back automatically — no action needed from you. If it still shows pending after a while, use the **Refresh** button on the customer's profile, or contact Joy support.

**Can I retry a failed plant or bottle removal?**

Not automatically today — a failed redemption refunds points rather than retrying, since Sprout doesn't guarantee that retrying is safe. The customer can simply redeem again.

**Does GoodAPI charge Joy or my store per API call?**

GoodAPI bills your GoodAPI account directly for the impact created (each tree, each bottle). Joy doesn't add any fee on top.
