# Betpawa — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Access upcoming, live, and popular sports events from BetPawa Ghana with real-time odds, markets, and detailed match statistics across multiple sports and leagues. Retrieve comprehensive event information including season fixtures, league details, and in-depth match stats.

**Category:** Sports | **Website:** [betpawa.com.gh/](https://betpawa.com.gh/) | **Docs:** [parse.bot/marketplace/c28eb4b6-0ec7-4424-8e87-e46dd11dfe01/betpawa-com-gh-api](https://parse.bot/marketplace/c28eb4b6-0ec7-4424-8e87-e46dd11dfe01/betpawa-com-gh-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_event_detail

Get full market and odds details for a specific event. Returns all available markets (1X2, Double Chance, Both Teams To Score, Over/Under, etc.) with complete odds. The event_id should be obtained from get_upcoming_events, get_live_events, or get_popular_events.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `event_id` | string | Yes | The numeric event ID to retrieve details for. Obtain from get_upcoming_events, get_live_events, or get_popular_events responses. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_event_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"event_id":"<string>"}'
```

### get_leagues_by_sport

Get leagues and competitions for a given sport, grouped by region. Returns competition names, event counts (live and upcoming), and weekly schedule breakdowns. Also includes summary counts for other sports.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `sport_id` | string | No | Sport category ID. Values: '2' (Football), '3' (Basketball), '452' (Tennis), '101' (eFootball). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_leagues_by_sport \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"sport_id":"<string>"}'
```

### get_live_events

Get currently live sports events across Football, Basketball, Tennis, and eFootball. Returns events with real-time scores, current period, odds, and market data. May return an empty list if no events are currently live.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_live_events \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_popular_events

Get popular/featured upcoming Football events sorted by start time ascending. Returns up to 20 events with 1X2 odds, market counts, and popularity scores.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_popular_events \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_sports_categories

Get all available sports categories with event counts (live, upcoming, hot) and weekly schedule. Returns a summary for each sport showing how many events are available.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_sports_categories \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_upcoming_events

Get upcoming sports events with odds for a given sport category. Returns a flat array of events including names, participants, start times, 1X2 odds, and market counts. Paginated via skip/take parameters.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `skip` | integer | No | Number of events to skip for pagination. |
| `sport_id` | string | No | Sport category ID. Values: '2' (Football), '3' (Basketball), '452' (Tennis), '101' (eFootball). |
| `take` | integer | No | Number of events to return per request (max 50). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-betpawa-com-gh-api-c28eb4b6/get_upcoming_events \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"skip":"<integer>","sport_id":"<string>","take":"<integer>"}'
```
