Usage
<ParamField> documents a single API parameter. Stack several together to describe an endpoint's full input contract.
<ParamField name="projectId" type="string" required path="path">
The UUID of the project. Copy it from the dashboard URL.
</ParamField>
<ParamField name="limit" type="number" default="20" path="query">
Number of results per page. Maximum 100.
</ParamField>projectIdstringpathrequiredThe UUID of the project. Copy it from the dashboard URL.
limitnumberquerydefault: 20Number of results per page. Maximum 100.
Parameter location badge
Set the path prop to show where the parameter lives in the request. The badge appears next to the type and helps readers parse a busy endpoint at a glance.
| Value | Renders as |
"path" | small uppercase PATH badge |
"query" | QUERY badge |
"header" | HEADER badge |
"body" | BODY badge |
<ParamField name="Authorization" type="string" required path="header">
Bearer token from your dashboard.
</ParamField>
<ParamField name="name" type="string" required path="body">
The new project name shown in the sidebar.
</ParamField>AuthorizationstringheaderrequiredBearer token from your dashboard.
namestringbodyrequiredThe new project name shown in the sidebar.
Enum options
Pass an enum array to render the allowed values inline below the description:
<ParamField name="theme" type="string" enum={["light", "dark", "system"]} default="system">
The default theme for visitors arriving without a saved preference.
</ParamField>themestringdefault: systemThe default theme for visitors arriving without a saved preference.
lightdarksystemDeprecated parameters
Mark a parameter as deprecated to strikethrough the name and add a warning badge:
<ParamField name="legacyId" type="string" deprecated>
Use `id` instead. This parameter will be removed in v2.
</ParamField>legacyIdstringdeprecatedUse id instead. This parameter will be removed in v2.
Default value
The default prop is rendered as inline metadata next to the type and badge:
<ParamField name="page" type="number" default="1" path="query">
Page number to fetch.
</ParamField>Auto-generation from OpenAPI
If your project has an OpenAPI spec configured via api.openapi, ParamField entries are generated automatically on the API reference pages — you don't need to write them by hand. See the OpenAPI integration guide for details. Manually-written ParamField components are still useful for examples in concept pages and tutorials.
Props
| Prop | Type | Required | Description |
name | string | Yes | Parameter name as it appears in the request |
type | string | No | Type annotation (e.g. string, number, UUID, MyEnum[]) |
required | boolean | No | Adds a red "required" label |
default | string | No | Default value when the parameter is omitted |
deprecated | boolean | No | Strikethrough name + "deprecated" badge |
enum | string[] | No | Allowed values rendered as inline pills |
path | "path" | "query" | "header" | "body" | No | Where the parameter lives in the request |
For documenting response fields, use <ResponseField> — it's the output twin.