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

# Introduction

> Connect your platform to the Seyaha activities marketplace.

Seyaha is an activities marketplace for Saudi Arabia and the wider region. We aggregate activity listings from partners, distribute them through affiliates, and let resellers embed the full booking flow into their own products.

There are three distinct API surfaces — pick the one that matches your integration type:

<CardGroup cols={3}>
  <Card title="Partner Integration" icon="plug" href="/pages/partner/quickstart">
    **You supply activities.** Connect your OCTO-compatible catalog so Seyaha can sync your products, manage availability, and handle bookings on your behalf.
  </Card>

  <Card title="Reseller API" icon="store" href="/pages/reseller/quickstart">
    **You sell activities.** Browse the full catalog, check availability, and create bookings for your customers using a static API token.
  </Card>

  <Card title="Affiliate API" icon="link" href="/pages/affiliate/quickstart">
    **You refer bookings.** List activities, create bookings, and process payments (Moyasar or Stripe) on behalf of authenticated end users via JWT.
  </Card>
</CardGroup>

## Base URL

All APIs are served under the same domain:

```text theme={null}
https://backend.seyaha.net/api/v1
```

| API surface         | Path prefix             |
| ------------------- | ----------------------- |
| Partner Integration | `/partner-integrations` |
| Reseller            | `/resellers`            |
| Affiliate           | `/affiliates`           |

## Response envelope

Every response is wrapped in a consistent envelope:

```json theme={null}
{
  "success": 1,
  "data": { ... },
  "pagination": { ... }
}
```

On error, `success` is `0` and the envelope includes `error` and `message`:

```json theme={null}
{
  "success": 0,
  "error": ["field: reason"],
  "message": "Validation Error",
  "code": 400
}
```

See [Errors](/pages/errors) for the full list of status codes and error shapes.

## Authentication at a glance

| API                 | Mechanism                           |
| ------------------- | ----------------------------------- |
| Partner Integration | `Authorization: Bearer <JWT>`       |
| Reseller            | `x-api-token: <token>` header       |
| Affiliate           | `Authorization: Bearer <JWT>`       |
| Webhooks (inbound)  | `x-webhook-secret: <secret>` header |

Full details in [Authentication](/pages/authentication).
