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

# Wolfram|Alpha

> Computational answers to natural-language questions (math, science, units, data on places, finance, dates and more): LLM-ready text, one-line answers, structured result pods or a rendered result image.

![](https://mintcdn.com/webrouter/8QP9EZc8V07Kl-0I/logo/data-apis/wolframalpha.webp?fit=max\&auto=format\&n=8QP9EZc8V07Kl-0I\&q=85\&s=4dacd2f193bce0c840b1744e466761d1)

[Web Catalog · AI](https://docs.webrouter.net/data-apis.md?category=ai)

Needs&#x20;

`WOLFRAM_ALPHA_APPID`

Endpoints

4

Auth

Key in query

[Vendor docs](https://products.wolframalpha.com/api)

&#x20;·&#x20;

[Pricing](https://products.wolframalpha.com/api)

## Setup

| Variable | | What it is | |
| - | - | - | - |
| `WOLFRAM_ALPHA_APPID` | required | A Wolfram | Alpha AppID from the Developer Portal (developer.wolframalpha.com); one per application. Sent as the appid query parameter. |

Put them in your environment or `.env`; [Data APIs](https://docs.webrouter.net/vendors.md) covers the other ways.

## Notes

* Free non-commercial access covers up to 2,000 API calls per month; commercial use needs a paid plan under the Commercial Terms of Use.
* HTTP 501 means the input could not be interpreted (or, for short answers, has no short result); rephrase rather than retry. 400 means the input parameter is missing.
* Some topics are restricted by default; access is granted on request.
* Short answers and the simple image use the parameter i; the LLM and full-results APIs use input.

## Endpoints

GET

Ask for an LLM-ready answer

A plain-text result with input interpretation, results, image URLs and a link to the full Wolfram|Alpha page, made for language models.

[Open](#wolframalpha-llm-query)

GET

Get a one-line answer

A single short plain-text result, e.g. '2464 miles'.

[Open](#wolframalpha-short-answer)

GET

Get full structured results

Every result pod (interpretation, result, plots, tables) with plaintext and image renderings.

[Open](#wolframalpha-full-query)

GET

Get the result as an image

A single static image of the whole result page.

[Open](#wolframalpha-simple-image)

### Ask for an LLM-ready answer

GET

`/api/v1/llm-api`

`wolframalpha.llm.query`

A plain-text result with input interpretation, results, image URLs and a link to the full Wolfram|Alpha page, made for language models.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`input` required</td><td>string</td><td>query</td><td>The question, in natural language. Example `population of France / population of Germany`</td></tr>

    <tr>
      <td>
        `maxchars`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Response length cap, default 6800.
      </td>
    </tr>

    <tr><td>`units`</td><td>string</td><td>query</td><td>metric or imperial; default inferred from the caller's location. One of `metric`, `imperial`</td></tr>

    <tr>
      <td>
        `location`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Location for location-dependent queries.
      </td>
    </tr>

    <tr>
      <td>
        `latlong`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        lat,long for location-dependent queries.
      </td>
    </tr>

    <tr>
      <td>
        `timezone`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Time zone for time-dependent queries.
      </td>
    </tr>

    <tr>
      <td>
        `currency`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Currency for money results.
      </td>
    </tr>

    <tr>
      <td>
        `countrycode`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Country code.
      </td>
    </tr>

    <tr>
      <td>
        `languagecode`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Language code.
      </td>
    </tr>

    <tr>
      <td>
        `assumption`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        An assumption value from a previous answer, to pick an interpretation.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://products.wolframalpha.com/llm-api/documentation)

```python Python theme={null}
router.call_data_api("wolframalpha.llm.query", {'input': 'population of France / population of Germany'})
```

```text MCP theme={null}
call_data_api(endpoint="wolframalpha.llm.query", params={"input": "population of France / population of Germany"})
```

> [!NOTE]
>
> * Plain text, not JSON. The AppID can also go in 'Authorization: Bearer \<AppID>'.

### Get a one-line answer

GET

`/v1/result`

`wolframalpha.short.answer`

A single short plain-text result, e.g. '2464 miles'.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`i` required</td><td>string</td><td>query</td><td>The question. Example `How far is Los Angeles from New York?`</td></tr>
    <tr><td>`units`</td><td>string</td><td>query</td><td>metric or imperial; default inferred from the caller's location. One of `metric`, `imperial`</td></tr>

    <tr>
      <td>
        `timeout`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Max processing seconds, default 5.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://products.wolframalpha.com/short-answers-api/documentation)

```python Python theme={null}
router.call_data_api("wolframalpha.short.answer", {'i': 'How far is Los Angeles from New York?'})
```

```text MCP theme={null}
call_data_api(endpoint="wolframalpha.short.answer", params={"i": "How far is Los Angeles from New York?"})
```

> [!NOTE]
>
> * Fails with 501 when no short result exists even though Wolfram|Alpha has data; fall back to llm.query.

### Get full structured results

GET

`/v2/query`

`wolframalpha.full.query`

Every result pod (interpretation, result, plots, tables) with plaintext and image renderings.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `input`

        required
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        The question.
      </td>
    </tr>

    <tr><td>`output`</td><td>string</td><td>query</td><td>xml (default) or json. One of `xml`, `json` Example `json`</td></tr>

    <tr>
      <td>
        `format`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Pod formats, comma-separated, e.g. plaintext,image,mathml.
      </td>
    </tr>

    <tr>
      <td>
        `includepodid`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Only pods with this id.
      </td>
    </tr>

    <tr>
      <td>
        `excludepodid`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Leave out pods with this id.
      </td>
    </tr>

    <tr>
      <td>
        `podtitle`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Only pods with this title.
      </td>
    </tr>

    <tr>
      <td>
        `podindex`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Only pods at these indexes.
      </td>
    </tr>

    <tr>
      <td>
        `scanner`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Only pods from this scanner.
      </td>
    </tr>

    <tr><td>`units`</td><td>string</td><td>query</td><td>metric or imperial; default inferred from the caller's location. One of `metric`, `imperial`</td></tr>

    <tr>
      <td>
        `location`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Location for location-dependent queries.
      </td>
    </tr>

    <tr>
      <td>
        `latlong`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        lat,long.
      </td>
    </tr>

    <tr>
      <td>
        `ip`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        IP to locate the caller by.
      </td>
    </tr>

    <tr>
      <td>
        `assumption`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Assumption value from a previous answer.
      </td>
    </tr>

    <tr>
      <td>
        `podstate`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Pod state (e.g. more digits, step-by-step) from a previous answer.
      </td>
    </tr>

    <tr>
      <td>
        `reinterpret`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Reinterpret input that is not understood.
      </td>
    </tr>

    <tr>
      <td>
        `translation`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Translate non-English input.
      </td>
    </tr>

    <tr>
      <td>
        `totaltimeout`
      </td>

      <td>
        number
      </td>

      <td>
        query
      </td>

      <td>
        Overall time limit, seconds.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://products.wolframalpha.com/api/documentation)

> [!NOTE]
>
> * Answers XML unless output=json.

### Get the result as an image

GET

`/v1/simple`

`wolframalpha.simple.image`

A single static image of the whole result page.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `i`

        required
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        The question.
      </td>
    </tr>

    <tr><td>`layout`</td><td>string</td><td>query</td><td>Default divider. One of `divider`, `labelbar`</td></tr>

    <tr>
      <td>
        `background`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Color name, hex RGB, decimal RGB, or transparent; default white.
      </td>
    </tr>

    <tr><td>`foreground`</td><td>string</td><td>query</td><td>Default black. One of `black`, `white`</td></tr>

    <tr>
      <td>
        `fontsize`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Points, default 14.
      </td>
    </tr>

    <tr>
      <td>
        `width`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Image width in pixels, default 500.
      </td>
    </tr>

    <tr><td>`units`</td><td>string</td><td>query</td><td>metric or imperial; default inferred from the caller's location. One of `metric`, `imperial`</td></tr>

    <tr>
      <td>
        `timeout`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Max processing seconds, default 5.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://products.wolframalpha.com/simple-api/documentation)

> [!NOTE]
>
> * Answers an image, not text.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.