*** title: Endpoint response snippet description: Reference an endpoint response from your API Reference ------------------------------------------------------------------- Use the `` component to reference an endpoint response from your API Reference. ## Usage
```jsx Markdown ``` ## Reference particular examples ### Set the example name in your spec ```yaml openapi.yml {13} paths: /pet/{petId}: put: summary: Get a pet operationId: pets_get responses: '200': content: application/json: schema: $ref: '#/components/schemas/Pet' examples: ExampleWithMarkley: summary: This is an example of a Pet value: name: Markley id: 44 ``` ```yaml pets.yml {11} service: auth: true base-path: "" endpoints: update: docs: Get a pet method: GET path: /pet/{petId} response: Pet examples: - name: ExampleWithMarkley docs: This is an example of a Pet response: body: name: Markley id: 44 ``` ### Directly reference the example ```jsx Markdown {3} ``` ## Properties The endpoint to display, in the format `METHOD /path` (e.g., `POST /chat/{domain}`). The name of a specific example to display. If the example includes a `summary` or `docs` field, use that value. Line numbers to highlight in the code snippet. Accepts a single number, an array of numbers, or ranges (e.g., `{[1-3, 5]}`).