> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flowyte.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Shopify

> Answer "where is my order?" by looking up live order status as a skill.

Connect your store, then provision an **order lookup** action as a [skill](/concepts/skills). When
a caller asks where their order is (WISMO), the agent collects the order number or email, looks up
the live status, and reads it back — no transfer to a human required.

## Connect with an API key

Shopify connects with an API-key credential, so it completes in a single call — no browser hop.
Pass the credential in the connect body; it's encrypted at rest and never echoed back.

<CodeGroup>
  ```bash curl theme={null}
  curl -X POST https://builder.flowyte.com/api/v1/integrations/shopify/connect \
    -H "Authorization: Bearer flowyte_sk_…" \
    -H "Content-Type: application/json" \
    -d '{ "credentials": { "shop": "your-store.myshopify.com", "access_token": "shpat_…" } }'
  # → { "data": { "status": "connected" } }
  ```

  ```js Node theme={null}
  const res = await fetch(
    "https://builder.flowyte.com/api/v1/integrations/shopify/connect",
    {
      method: "POST",
      headers: {
        Authorization: "Bearer flowyte_sk_…",
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        credentials: { shop: "your-store.myshopify.com", access_token: "shpat_…" },
      }),
    },
  );
  const { data } = await res.json(); // { status: "connected" }
  ```

  ```python Python theme={null}
  import requests

  res = requests.post(
      "https://builder.flowyte.com/api/v1/integrations/shopify/connect",
      headers={"Authorization": "Bearer flowyte_sk_…"},
      json={"credentials": {"shop": "your-store.myshopify.com", "access_token": "shpat_…"}},
  )
  print(res.json()["data"]["status"])  # connected
  ```
</CodeGroup>

<Tip>
  A store-scoped admin API token (a custom app token) is the fastest path — no OAuth app to publish.
  The exact credential keys are listed on the connect form in the dashboard.
</Tip>

## Provision the lookup skill

```bash theme={null}
# Browse the actions
curl https://builder.flowyte.com/api/v1/integrations/shopify/actions \
  -H "Authorization: Bearer flowyte_sk_…"

# Provision onto an agent (omit "actions" to take every important one)
curl -X POST \
  https://builder.flowyte.com/api/v1/agents/AGENT_ID/integrations/shopify/provision \
  -H "Authorization: Bearer flowyte_sk_…" \
  -H "Content-Type: application/json" \
  -d '{ "actions": ["lookup_order"] }'
```

Lookups are read-only, so the agent answers without taking any action on the store. Re-running
provision is idempotent — already-created skills return `created: false`.

## In the API

| Action            | Endpoint                                                  | Scope                |
| ----------------- | --------------------------------------------------------- | -------------------- |
| Connect (API key) | `POST /integrations/shopify/connect`                      | `integrations:write` |
| List actions      | `GET /integrations/shopify/actions`                       | `integrations:read`  |
| Provision skills  | `POST /agents/{agentId}/integrations/shopify/provision`   | `skills:write`       |
| Remove skills     | `DELETE /agents/{agentId}/integrations/shopify/provision` | `skills:write`       |
| Disconnect        | `DELETE /integrations/shopify`                            | `integrations:write` |

<Warning>
  Provisioning edits the **draft**. [Publish](/concepts/agents) so live callers get real order status.
</Warning>
