openapi: 3.0.0 info: description: Webcomic of romance, sarcasm, math, and language. title: XKCD version: 1.0.0 externalDocs: url: https://xkcd.com/json.html paths: /info.0.json: get: description: | Fetch current comic and metadata. responses: "200": description: OK content: "*/*": schema: $ref: "#/components/schemas/comic" "/{comicId}/info.0.json": get: description: | Fetch comics and metadata by comic id. parameters: - in: path name: comicId required: true schema: type: number responses: "200": description: OK content: "*/*": schema: $ref: "#/components/schemas/comic" servers: - url: http://xkcd.com/ components: schemas: comic: properties: alt: type: string day: type: string img: type: string link: type: string month: type: string news: type: string num: type: number safe_title: type: string title: type: string transcript: type: string year: type: string type: object