Parameter Field
AParamField component is used to define the parameters for your APIs or SDKs. Adding a ParamField will automatically add an API Playground.
An example of a parameter field
Props
Whether it is a query, path, body, or header parameter followed by the name
Expected type of the parameter’s valueSupports
number, string, bool, object.Arrays can be defined using the [] suffix. For example string[].Indicate whether the parameter is required
Indicate whether the parameter is deprecated
Default value used by the server if the request does not provide a value
Value that will be used to initialize the playground
Placeholder text for the input in the playground
Description of the parameter (markdown enabled)
Response Field
The<ResponseField> component is designed to define the return values of an API. Many docs also use <ResponseField> on pages when you need to list the types of something.
A response field example
Props
The name of the response value.
Expected type of the response value - this can be any arbitrary string.
The default value.
Show “required” beside the field name.
Whether a field is deprecated or not.
Labels that are shown before the name of the field
Labels that are shown after the name of the field