{
  "openapi": "3.1.0",
  "info": {
    "title": "Motel Vujeva API",
    "summary": "Read-only Motel Vujeva JSON API, Markdown resources, and MCP discovery for the family motel in Livno.",
    "description": "Motel Vujeva is a family motel in Livno, Bosnia and Herzegovina. Versioning: public JSON lives at /api/v1/. Breaking changes ship as /api/v2/. Deprecated versions send Deprecation and Sunset headers at least 90 days before removal. There is no public checkout, OAuth, or webhook API. Room availability is requested through https://motelvujeva.com/rezervacija/, email vujeva@vujeva.info, or phone +387 63 371 103.\n\nErrors use RFC 9457 application/problem+json with a machine-readable code, human-readable detail, and a resolution hint. Successful JSON responses send RateLimit, RateLimit-Policy, and X-RateLimit-* headers. HTTP 429 also sends Retry-After.\n\nCLI: npx motel-vujeva property (npm package motel-vujeva). MCP Streamable HTTP is at /mcp. RFC 9727 catalog: /.well-known/api-catalog. MCP registry card: /server.json.",
    "version": "1.0.0",
    "contact": {
      "name": "Motel Vujeva",
      "email": "vujeva@vujeva.info",
      "url": "https://motelvujeva.com/developers/"
    },
    "license": {
      "name": "Content belonging to Bili Kamen d.o.o.",
      "identifier": "LicenseRef-Motel-Vujeva"
    }
  },
  "servers": [
    {
      "url": "https://motelvujeva.com",
      "description": "Motel Vujeva canonical site"
    }
  ],
  "tags": [
    {
      "name": "v1",
      "description": "Versioned Motel Vujeva JSON API (/api/v1/)"
    },
    {
      "name": "discovery",
      "description": "Indexes and instructions for agents"
    },
    {
      "name": "content",
      "description": "Public Markdown representations of lodging pages"
    }
  ],
  "paths": {
    "/api/v1/health": {
      "get": {
        "tags": ["v1"],
        "summary": "Motel Vujeva API health",
        "description": "Liveness probe for the Motel Vujeva v1 JSON API.",
        "operationId": "getApiV1Health",
        "responses": {
          "200": {
            "description": "API is up",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/Health" }
              }
            }
          },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/api/v1/property": {
      "get": {
        "tags": ["v1"],
        "summary": "Motel Vujeva property",
        "description": "Lodging facts for Motel Vujeva: location, capacity, amenities, and the four public room types.",
        "operationId": "getApiV1Property",
        "responses": {
          "200": {
            "description": "Property document",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/PropertyResponse" }
              }
            }
          },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/api/v1/rooms": {
      "get": {
        "tags": ["v1"],
        "summary": "List Motel Vujeva rooms",
        "description": "Public room types. Availability is not live inventory; send guests to /rezervacija/.",
        "operationId": "listApiV1Rooms",
        "responses": {
          "200": {
            "description": "Room list",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/RoomListResponse" }
              }
            }
          },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/api/v1/rooms/{roomId}": {
      "get": {
        "tags": ["v1"],
        "summary": "Get one Motel Vujeva room",
        "description": "Fetch a single public room type by id.",
        "operationId": "getApiV1Room",
        "parameters": [
          {
            "name": "roomId",
            "in": "path",
            "required": true,
            "description": "Public room id",
            "schema": {
              "type": "string",
              "enum": ["view", "single", "double-single", "triple"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Room document",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/RoomResponse" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/api/v1/contact": {
      "get": {
        "tags": ["v1"],
        "summary": "Motel Vujeva contact",
        "description": "Phone, email, and booking URL for Motel Vujeva in Livno.",
        "operationId": "getApiV1Contact",
        "responses": {
          "200": {
            "description": "Contact document",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/ContactResponse" }
              }
            }
          },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/api/v1/version": {
      "get": {
        "tags": ["v1"],
        "summary": "Motel Vujeva API version policy",
        "description": "Current API version, sunset policy, and resource list.",
        "operationId": "getApiV1Version",
        "responses": {
          "200": {
            "description": "Version document",
            "headers": {
              "API-Version": { "$ref": "#/components/headers/ApiVersion" },
              "RateLimit": { "$ref": "#/components/headers/RateLimit" },
              "RateLimit-Policy": { "$ref": "#/components/headers/RateLimitPolicy" },
              "X-RateLimit-Limit": { "$ref": "#/components/headers/XRateLimitLimit" },
              "X-RateLimit-Remaining": { "$ref": "#/components/headers/XRateLimitRemaining" },
              "X-RateLimit-Reset": { "$ref": "#/components/headers/XRateLimitReset" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/VersionResponse" }
              }
            }
          },
          "429": { "$ref": "#/components/responses/TooManyRequests" },
          "500": { "$ref": "#/components/responses/ServerError" }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "tags": ["discovery"],
        "summary": "Motel Vujeva llms.txt index",
        "description": "Markdown index of Motel Vujeva pages, when-to-use guidance, and developer URLs.",
        "operationId": "getLlmsTxt",
        "responses": {
          "200": {
            "description": "Markdown index",
            "content": {
              "text/plain": {
                "schema": { "type": "string" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    },
    "/agent-instructions.md": {
      "get": {
        "tags": ["discovery"],
        "summary": "When to use Motel Vujeva and how to call it",
        "description": "Agent instructions for Motel Vujeva: channels, NAP, and anti-patterns.",
        "operationId": "getAgentInstructions",
        "responses": {
          "200": {
            "description": "Agent instructions",
            "content": {
              "text/markdown": {
                "schema": { "type": "string" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "tags": ["discovery"],
        "summary": "This OpenAPI document",
        "description": "OpenAPI 3.1 description of the Motel Vujeva API and developer resources.",
        "operationId": "getOpenApi",
        "responses": {
          "200": {
            "description": "OpenAPI 3.1 document",
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/OpenApiDocument" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    },
    "/sitemap.xml": {
      "get": {
        "tags": ["discovery"],
        "summary": "XML sitemap",
        "description": "Sitemap of canonical Motel Vujeva URLs.",
        "operationId": "getSitemap",
        "responses": {
          "200": {
            "description": "Sitemap of canonical Motel Vujeva URLs",
            "content": {
              "application/xml": {
                "schema": { "type": "string" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    },
    "/index.md": {
      "get": {
        "tags": ["content"],
        "summary": "Homepage as Markdown",
        "description": "Markdown representation of https://motelvujeva.com/.",
        "operationId": "getHomeMarkdown",
        "responses": {
          "200": {
            "description": "Homepage Markdown",
            "content": {
              "text/markdown": {
                "schema": { "type": "string" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    },
    "/developers.md": {
      "get": {
        "tags": ["content"],
        "summary": "Motel Vujeva developer resources as Markdown",
        "description": "Markdown representation of /developers/ covering the API, OpenAPI, MCP, and CLI.",
        "operationId": "getDevelopersMarkdown",
        "responses": {
          "200": {
            "description": "Developers Markdown",
            "content": {
              "text/markdown": {
                "schema": { "type": "string" }
              }
            }
          },
          "404": { "$ref": "#/components/responses/NotFound" }
        }
      }
    }
  },
  "components": {
    "headers": {
      "ApiVersion": {
        "description": "Current Motel Vujeva API major version",
        "schema": { "type": "string", "example": "1" }
      },
      "RateLimit": {
        "description": "IETF RateLimit header",
        "schema": { "type": "string" }
      },
      "RateLimitPolicy": {
        "description": "IETF RateLimit-Policy header",
        "schema": { "type": "string" }
      },
      "XRateLimitLimit": {
        "description": "Requests allowed in the current window",
        "schema": { "type": "string" }
      },
      "XRateLimitRemaining": {
        "description": "Requests remaining in the current window",
        "schema": { "type": "string" }
      },
      "XRateLimitReset": {
        "description": "Seconds until the window resets",
        "schema": { "type": "string" }
      }
    },
    "schemas": {
      "Money": {
        "type": "object",
        "additionalProperties": false,
        "required": ["amount", "currency"],
        "properties": {
          "amount": { "type": "number" },
          "currency": { "type": "string", "enum": ["BAM", "EUR"] }
        }
      },
      "Room": {
        "type": "object",
        "additionalProperties": false,
        "required": ["id", "name", "nameEn", "capacity", "sizeSqm", "priceFrom", "notes"],
        "properties": {
          "id": {
            "type": "string",
            "enum": ["view", "single", "double-single", "triple"]
          },
          "name": { "type": "string" },
          "nameEn": { "type": "string" },
          "capacity": { "type": "integer" },
          "sizeSqm": { "type": "integer" },
          "priceFrom": { "$ref": "#/components/schemas/Money" },
          "notes": { "type": "string" }
        }
      },
      "Property": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "id",
          "name",
          "legalName",
          "companyId",
          "description",
          "url",
          "bookingUrl",
          "address",
          "geo",
          "roomCount",
          "guestCapacity",
          "priceFrom"
        ],
        "properties": {
          "id": { "type": "string" },
          "name": { "type": "string" },
          "legalName": { "type": "string" },
          "companyId": { "type": "string" },
          "description": { "type": "string" },
          "url": { "type": "string", "format": "uri" },
          "bookingUrl": { "type": "string", "format": "uri" },
          "aboutUrl": { "type": "string", "format": "uri" },
          "contactUrl": { "type": "string", "format": "uri" },
          "developersUrl": { "type": "string", "format": "uri" },
          "locale": { "type": "string" },
          "address": {
            "type": "object",
            "additionalProperties": false,
            "required": ["locality", "country"],
            "properties": {
              "locality": { "type": "string" },
              "region": { "type": "string" },
              "country": { "type": "string" },
              "countryName": { "type": "string" }
            }
          },
          "geo": {
            "type": "object",
            "additionalProperties": false,
            "required": ["latitude", "longitude"],
            "properties": {
              "latitude": { "type": "number" },
              "longitude": { "type": "number" }
            }
          },
          "checkIn": { "type": "string" },
          "checkOut": { "type": "string" },
          "roomCount": { "type": "integer" },
          "guestCapacity": { "type": "integer" },
          "priceFrom": { "$ref": "#/components/schemas/Money" },
          "currenciesAccepted": {
            "type": "array",
            "items": { "type": "string" }
          },
          "amenities": {
            "type": "array",
            "items": { "type": "string" }
          }
        }
      },
      "Contact": {
        "type": "object",
        "additionalProperties": false,
        "required": ["name", "phone", "email"],
        "properties": {
          "name": { "type": "string" },
          "phone": { "type": "string" },
          "email": { "type": "string", "format": "email" },
          "instagram": { "type": "string", "format": "uri" },
          "facebook": { "type": "string", "format": "uri" },
          "bookingUrl": { "type": "string", "format": "uri" },
          "contactUrl": { "type": "string", "format": "uri" },
          "hours": { "type": "string" }
        }
      },
      "Health": {
        "type": "object",
        "additionalProperties": false,
        "required": ["ok", "service", "version"],
        "properties": {
          "ok": { "type": "boolean" },
          "service": { "type": "string" },
          "version": { "type": "string" }
        }
      },
      "PropertyResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": ["property", "rooms"],
        "properties": {
          "property": { "$ref": "#/components/schemas/Property" },
          "rooms": {
            "type": "array",
            "items": { "$ref": "#/components/schemas/Room" }
          }
        }
      },
      "RoomListResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": ["rooms"],
        "properties": {
          "rooms": {
            "type": "array",
            "items": { "$ref": "#/components/schemas/Room" }
          }
        }
      },
      "RoomResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": ["room"],
        "properties": {
          "room": { "$ref": "#/components/schemas/Room" }
        }
      },
      "ContactResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": ["contact"],
        "properties": {
          "contact": { "$ref": "#/components/schemas/Contact" }
        }
      },
      "VersionResponse": {
        "type": "object",
        "additionalProperties": false,
        "required": ["name", "version", "policy"],
        "properties": {
          "name": { "type": "string" },
          "version": { "type": "string" },
          "spec": { "type": "string" },
          "sunset": { "type": ["string", "null"] },
          "deprecation": { "type": ["string", "null"] },
          "policy": { "type": "string" },
          "resources": {
            "type": "array",
            "items": { "type": "string" }
          }
        }
      },
      "OpenApiDocument": {
        "type": "object",
        "required": ["openapi", "info"],
        "properties": {
          "openapi": { "type": "string" },
          "info": {
            "type": "object",
            "required": ["title", "version"],
            "properties": {
              "title": { "type": "string" },
              "version": { "type": "string" },
              "description": { "type": "string" }
            }
          }
        }
      },
      "Problem": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "title", "status", "code", "detail", "instance", "hint"],
        "properties": {
          "type": { "type": "string", "format": "uri" },
          "title": { "type": "string" },
          "status": { "type": "integer" },
          "code": {
            "type": "string",
            "enum": [
              "not_found",
              "method_not_allowed",
              "bad_request",
              "rate_limited",
              "unsupported_media_type",
              "server_error"
            ]
          },
          "detail": { "type": "string" },
          "instance": { "type": "string" },
          "hint": { "type": "string" }
        }
      }
    },
    "responses": {
      "NotFound": {
        "description": "Unknown Motel Vujeva API path or room id",
        "content": {
          "application/problem+json": {
            "schema": { "$ref": "#/components/schemas/Problem" }
          }
        }
      },
      "TooManyRequests": {
        "description": "Client exceeded 60 requests per minute",
        "headers": {
          "Retry-After": {
            "schema": { "type": "string" }
          },
          "RateLimit": {
            "schema": { "type": "string" }
          }
        },
        "content": {
          "application/problem+json": {
            "schema": { "$ref": "#/components/schemas/Problem" }
          }
        }
      },
      "ServerError": {
        "description": "Unexpected Motel Vujeva API failure",
        "content": {
          "application/problem+json": {
            "schema": { "$ref": "#/components/schemas/Problem" }
          }
        }
      }
    }
  }
}
