Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 6 additions & 18 deletions api-playground/troubleshooting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -33,26 +33,14 @@ If your API pages aren't displaying correctly, check these common configuration
</Accordion>
<Accordion title="One of my OpenAPI pages is completely blank">
This is usually caused by a misspelled `openapi` field in the page metadata. Make sure
the HTTP method and path match the HTTP method and path in the OpenAPI document exactly.
the HTTP method and path match the HTTP method and path in the OpenAPI document.

Here's an example of how things might go wrong:
<Note>
Trailing slashes are handled automatically. For example, `GET /users/{id}/` in your
metadata will correctly match a `/users/{id}` path in the OpenAPI spec, and vice versa.
</Note>

```mdx get-user.mdx
---
openapi: "GET /users/{id}/"
---
```

```yaml openapi.yaml
paths:
"/users/{id}":
get: ...
```

Notice that the path in the `openapi` field has a trailing slash, whereas the path in the OpenAPI
document does not.

Another common issue is a misspelled filename. If you are specifying a particular OpenAPI document
A common issue is a misspelled filename. If you are specifying a particular OpenAPI document
in the `openapi` field, ensure the filename is correct. For example, if you have two OpenAPI
documents `openapi/v1.json` and `openapi/v2.json`, your metadata might look like this:

Expand Down
Loading