openapi: 3.1.0
info:
  title: FastList API
  description: Read-only REST mirror of FastList classifieds for agents and integrations.
  version: 1.0.0
servers:
  - url: https://fastlist.org
paths:
  /api/v1/posts:
    get:
      summary: Browse classified listings
      parameters:
        - name: category
          in: query
          schema: { type: string }
        - name: zip
          in: query
          schema: { type: string, pattern: '^[0-9]{5}$' }
        - name: limit
          in: query
          schema: { type: integer, default: 50, maximum: 50 }
      responses:
        '200':
          description: List of posts
  /api/v1/categories:
    get:
      summary: List all post categories
      responses:
        '200':
          description: Category names
  /api/v1/posts/{id}:
    get:
      summary: Get a single post
      parameters:
        - name: id
          in: path
          required: true
          schema: { type: integer }
      responses:
        '200':
          description: Post details
        '404':
          description: Post not found
