# Mega Millions API

> Mega Millions provides winning numbers and jackpot information for drawings as a workflow and API.

Mega Millions returns winning numbers, jackpot values, and drawing details for the latest draw or a chosen date. Get latest results takes a drawing date as input; leave it blank to retrieve the latest draw.

- Page: https://fous.com/tools/mega-millions
- Handle: `@mega-millions`
- Category: [Other](https://fous.com/tools/category/other)
- Source website: https://megamillions.com
- Last verified: Sep 29, 2026

## Methods

### Get latest results

Operation `get_latest_results`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

Get Mega Millions winning numbers and jackpot information for the latest draw or a chosen date. Recent draws do not have a single drawn multiplier, so multiplier is null; results for draws still being verified may lack winner information.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `draw_date` | string | no | `"2025-03-04"` | Drawing date to look up, for example 2025-03-04. Defaults to the latest draw. |

**Input schema**

```json
{
  "type": "object",
  "properties": {
    "draw_date": {
      "type": "string",
      "format": "date",
      "description": "Drawing date to look up, for example 2025-03-04. Defaults to the latest draw.",
      "examples": [
        "2025-03-04",
        "2026-09-22"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {},
    {
      "draw_date": "2025-03-04"
    },
    {
      "draw_date": "2026-09-22"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `currency` | string | `"USD"` | Currency for all money amounts (USD). |
| `draw_date` | string | `"2026-09-25"` | Date of the drawing. |
| `cash_value` | number or null | `117300000` | Cash value for the drawing, in US dollars. |
| `multiplier` | integer or null | `2` | Drawn multiplier for older draws; null when there is no single drawn multiplier. |
| `jackpot_won` | boolean or null | `false` | Whether the jackpot had a winner; null if winner counts have not been verified. |
| `mega_ball_number` | integer | `16` | The gold Mega Ball number. |
| `estimated_jackpot` | number or null | `277000000` | Estimated jackpot for the drawing, in US dollars. |
| `results_page_link` | string | `"https://www.megamillions.com/Winning-Numbers/Previous-Drawings/Previous-Drawing-Page.aspx?date=639258912000000000"` | Page for the drawing results. |
| `next_draw_datetime` | string | `"2026-09-29T23:00:00-04:00"` | Next drawing date and time in US Eastern time, ISO 8601 with offset. |
| `white_ball_numbers` | array |  | Five white-ball numbers in ascending order. |
| `next_estimated_jackpot` | number or null | `300000000` | Estimated next drawing jackpot in US dollars. |

**Example input**

```json
{}
```

**Example output**

```json
{
  "currency": "USD",
  "draw_date": "2026-09-25",
  "cash_value": 117300000,
  "multiplier": null,
  "jackpot_won": false,
  "mega_ball_number": 16,
  "estimated_jackpot": 277000000,
  "results_page_link": "https://www.megamillions.com/Winning-Numbers/Previous-Drawings/Previous-Drawing-Page.aspx?date=639258912000000000",
  "next_draw_datetime": "2026-09-29T23:00:00-04:00",
  "white_ball_numbers": [
    25,
    57,
    58
  ],
  "next_estimated_jackpot": 300000000
}
```

## Quick start

Replace `YOUR_API_KEY` with a Fous API key. To create one, open Developers at the bottom of Fous Studio, turn on Developer mode, then go to API keys (https://app.fous.com/keys). Change the values in `input` to run the same tool on new data.

```bash
curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 180 \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@mega-millions",
  "visibility": "public",
  "operation": "get_latest_results",
  "version": 1,
  "input": {},
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
import json
import urllib.error
import urllib.request

api_key = "YOUR_API_KEY"

body = json.loads("{\n  \"api\": \"@mega-millions\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_latest_results\",\n  \"version\": 1,\n  \"input\": {},\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=180) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
const apiKey = "YOUR_API_KEY";

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(180_000),
  body: JSON.stringify({
  "api": "@mega-millions",
  "visibility": "public",
  "operation": "get_latest_results",
  "version": 1,
  "input": {},
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

## Use from an AI assistant

Connect this tool to Claude Code, Claude Desktop, Cursor, VS Code, Codex and any MCP client as its own MCP server. Each method is a typed tool whose arguments are the method’s input.

- Server URL: `https://api.fous.com/mcp/tools/mega-millions`
- Authorization: `Authorization: Bearer <Fous API key>`

**Tools**

- `get_latest_results`: Get latest results. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `fous_get_run`: the result of a run that was still going, by its `request_id`. Free.

Claude Code:

```bash
claude mcp add --scope user --transport http fous-mega-millions https://api.fous.com/mcp/tools/mega-millions --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"
```

To give the assistant every tool, connect `https://api.fous.com/mcp`: it finds one with `fous_search_tools` and runs it with `fous_run_tool`. Setup for other clients: https://fous.com/llms-full.txt.

## Use cases

- Check winning numbers for a drawing
- Review estimated and cash jackpot values
- Check whether a drawing had a jackpot winner
- Find the next drawing time and estimated jackpot

## FAQ

### Can I run it with my own inputs?

Yes. Change the inputs in Studio and press Run, or send new inputs from your code, or ask a connected AI assistant.

### Can I call this Mega Millions tool as an API?

Yes. Send a POST request to /v1/query with your Fous API key and the inputs, and get JSON back.

### How much does it cost?

Each completed run costs 1 credit. Failed runs without a completed receipt are free; completed work can remain charged if delivery is interrupted. With pay as you go, a credit costs 1¢. Monthly plans cost less per credit.

### Do I need a Mega Millions account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from megamillions.com when you run it. Some results are reused for up to 24 hours, and results that use your account or key are never reused. It was last verified on Sep 29, 2026.

### What were the winning numbers for a drawing?

Use Get latest results with a drawing date, or leave the date blank for the latest draw.

### What was the estimated jackpot for a drawing?

Get latest results returns the estimated jackpot and cash value for the drawing.

### Did a drawing have a jackpot winner?

Get latest results returns whether the jackpot had a winner when winner information is verified.

## Related

- [All Other tools](https://fous.com/tools/category/other)
