Response fields
Document API response fields using the ResponseField component with type annotations, descriptions, and required or optional indicators.
Use the <ResponseField> component to define the return values of an API. Many docs also use <ResponseField> on pages when you need to list the types of something.
responsestringrequiredA response field example
<ResponseField name="response" type="string" required>
A response field example
</ResponseField>Props
namestringrequiredThe name of the response value.
typestringrequiredExpected type of the response value - this can be any arbitrary string.
defaultstringThe default value.
requiredbooleanShow “required” beside the field name.
deprecatedbooleanWhether you have deprecated a field or not.
prestring[]Labels that appear before the name of the field
poststring[]Labels that appear after the name of the field
<ResponseField name="response" type="string" required>
A response field example
</ResponseField>Was this page helpful?Suggest editsRaise issue