Jamdesk Documentation logo

OpenAPI Example

See a live OpenAPI-generated endpoint page and learn how Jamdesk renders requests, responses, and authentication directly from your spec.

POSThttps://api.acme.com/v1/tickets

Create a new ticket for a customer issue or request.

Authorizations

Authorizationstringheaderrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

customer_idstringrequired

Customer identifier in Acme.

subjectstringrequired

Short summary of the issue.

priority"low" | "normal" | "high" | "urgent"
Allowed values: "low" | "normal" | "high" | "urgent"
tagsarray<string>
messagestringrequired

Detailed problem description.

Response

application/json

Ticket created

idstring
customer_idstring
subjectstring
prioritystring
status"open" | "pending" | "resolved"
Allowed values: "open" | "pending" | "resolved"
created_atstring<date-time>

This page demonstrates a live endpoint generated from an OpenAPI specification. The request schema, response models, and code examples in the right panel are all auto-generated from the spec — no manual authoring required.

This example uses the Acme Support API. Update api.openapi in your docs.json to point at your own spec file to generate real endpoints.

What Gets Generated

From a single openapi frontmatter line, Jamdesk auto-generates:

  • Endpoint badge — method and path with color coding
  • Parameter documentation — path, query, header, and body parameters
  • Request/response schemas — including nested objects and arrays
  • Code examples — cURL, Python, JavaScript, and more
  • Authentication details — pulled from the spec's security schemes

All $ref references in your spec are automatically resolved, so you can organize schemas with components/schemas as usual.

Setting Up OpenAPI

Place your OpenAPI 3.x spec (YAML or JSON) in the openapi/ directory, register it in docs.json under api.openapi, then add openapi: /openapi/your-spec.yaml METHOD /path to any page's frontmatter. See the OpenAPI setup guide for full details.

Request/Response Examples

Hand-authored endpoint example using MDX components

OpenAPI Setup

Where to store and reference OpenAPI files

docs.json Reference

Full configuration reference including api.openapi

Examples Component

Use RequestExample and ResponseExample for manual endpoints