{
  "openapi": "3.1.1",
  "info": {
    "title": "Focus Room Big Sign API",
    "version": "1.0.0",
    "summary": "Make text as big as the screen allows: a sign as SVG, PNG and printable PDF.",
    "description": "Every endpoint performs the same calculation as the human page and returns inputs, result, units, assumptions, sources, warnings and computedAt. MCP endpoint: /mcp."
  },
  "servers": [
    {
      "url": "https://focusroombigsign.usefulweb.app"
    }
  ],
  "paths": {
    "/api/v1/calculate": {
      "post": {
        "operationId": "calculate",
        "summary": "Make text as big as the screen allows: a sign as SVG, PNG and printable PDF.",
        "description": "Fits your text — a word, a sentence or a few lines — into a full-screen sign: the largest font size at which it still fits with a margin, measured with the real Noto font metrics (Latin, Cyrillic, Greek, Arabic, Devanagari and common Chinese, Japanese and Korean characters). You get an SVG with the letters as outlines, a PNG for a TV, tablet or video call, an A4 landscape PDF to print and a link that opens the sign full screen in Focus Room, where it can also scroll as a marquee.\n\nMethodology:\n- The text is shaped with the Noto fonts (Lumina’s OpenType shaper: Arabic joining, Devanagari reordering, kerning) and measured exactly. A binary search finds the largest font size at which the greedy word wrap fits inside the picture minus a 6 % margin, with a line height of 1.18 em and at most 8 lines; your own line breaks are kept.\n- The SVG contains the glyph outlines as paths (quadratic TrueType curves), so it looks the same on any device. The PNG is drawn by Printshop’s scanline rasteriser (non-zero winding, four sub-scanlines) and the PDF is a vector file with the font embedded as a subset — both from the same display list.\n- Each colour pair has a contrast ratio of at least 7:1.",
        "tags": [
          "apps"
        ],
        "x-mcp-tool": "focusroom_big_sign",
        "x-owner-app": "focusroom",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FocusroomBigSignInput"
              },
              "examples": {
                "example1": {
                  "summary": "“Back in 10 minutes” on signal yellow",
                  "value": {
                    "text": "Back in 10 minutes",
                    "theme": "signal",
                    "size": "1280x720"
                  }
                },
                "example2": {
                  "summary": "An Arabic sign for a phone held upright",
                  "value": {
                    "text": "الاجتماع يبدأ\nبعد خمس دقائق",
                    "theme": "night",
                    "size": "1080x1920"
                  }
                },
                "example3": {
                  "summary": "A scrolling welcome for the shop window",
                  "value": {
                    "text": "Welcome · Open until 6 pm · Coffee to go",
                    "theme": "ocean",
                    "size": "1280x720",
                    "marquee": true
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Calculation result envelope.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FocusroomBigSignResult"
                }
              }
            }
          },
          "400": {
            "description": "Malformed JSON body.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "422": {
            "description": "Invalid input (see errors[]).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded (see Retry-After).",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/tool": {
      "get": {
        "operationId": "getToolDefinition",
        "summary": "Inputs, output schema and examples for this tool",
        "responses": {
          "200": {
            "description": "Tool definition.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Problem": {
        "type": "object",
        "description": "RFC 9457 problem details. 422 responses include per-field `errors`.",
        "required": [
          "type",
          "title",
          "status",
          "detail"
        ],
        "properties": {
          "type": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "integer"
          },
          "detail": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "field",
                "message"
              ],
              "properties": {
                "field": {
                  "type": "string"
                },
                "message": {
                  "type": "string"
                }
              }
            }
          }
        }
      },
      "FocusroomBigSignInput": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "text": {
            "title": "Text",
            "description": "Line breaks are kept; long lines are wrapped at spaces. At most 280 characters.",
            "type": "string",
            "maxLength": 280,
            "default": "Back in 10 minutes"
          },
          "theme": {
            "title": "Colours",
            "type": "string",
            "enum": [
              "night",
              "paper",
              "signal",
              "alert",
              "go",
              "ocean",
              "violet"
            ],
            "default": "night"
          },
          "size": {
            "title": "Picture size",
            "type": "string",
            "enum": [
              "1920x1080",
              "1280x720",
              "1080x1920",
              "1080x1080"
            ],
            "default": "1280x720"
          },
          "marquee": {
            "title": "Scroll as a marquee in the app",
            "description": "Only the app link scrolls; the files show the fitted sign.",
            "type": "boolean",
            "default": false
          }
        },
        "required": []
      },
      "FocusroomBigSignResult": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "schemaVersion",
          "tool",
          "computedAt",
          "inputs",
          "summary",
          "result",
          "units",
          "assumptions",
          "sources",
          "warnings",
          "presentation",
          "links"
        ],
        "properties": {
          "schemaVersion": {
            "type": "string",
            "const": "1.0"
          },
          "tool": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name",
              "version"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            }
          },
          "computedAt": {
            "type": "string",
            "format": "date-time"
          },
          "inputs": {
            "type": "object",
            "description": "Normalised inputs actually used, including applied defaults."
          },
          "summary": {
            "type": "string"
          },
          "result": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "lines",
              "fontSize",
              "width",
              "height",
              "theme",
              "missingGlyphs",
              "link",
              "svgFile",
              "pngFile",
              "pdfFile"
            ],
            "properties": {
              "lines": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "fontSize": {
                "type": "number",
                "description": "Font size (em) in pixels of the picture."
              },
              "width": {
                "type": "integer"
              },
              "height": {
                "type": "integer"
              },
              "theme": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "id",
                  "background",
                  "text"
                ],
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "background": {
                    "type": "string"
                  },
                  "text": {
                    "type": "string"
                  }
                }
              },
              "missingGlyphs": {
                "type": "boolean"
              },
              "link": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "svgFile": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "artifactId",
                  "filename",
                  "mime",
                  "bytes",
                  "sha256",
                  "path"
                ],
                "properties": {
                  "artifactId": {
                    "type": "string"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "mime": {
                    "type": "string"
                  },
                  "bytes": {
                    "type": "integer"
                  },
                  "sha256": {
                    "type": "string"
                  },
                  "path": {
                    "type": "string",
                    "description": "Download path on the same site (valid for about 2 hours)."
                  }
                }
              },
              "pngFile": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "artifactId",
                  "filename",
                  "mime",
                  "bytes",
                  "sha256",
                  "path"
                ],
                "properties": {
                  "artifactId": {
                    "type": "string"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "mime": {
                    "type": "string"
                  },
                  "bytes": {
                    "type": "integer"
                  },
                  "sha256": {
                    "type": "string"
                  },
                  "path": {
                    "type": "string",
                    "description": "Download path on the same site (valid for about 2 hours)."
                  }
                }
              },
              "pdfFile": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "artifactId",
                  "filename",
                  "mime",
                  "bytes",
                  "sha256",
                  "path"
                ],
                "properties": {
                  "artifactId": {
                    "type": "string"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "mime": {
                    "type": "string"
                  },
                  "bytes": {
                    "type": "integer"
                  },
                  "sha256": {
                    "type": "string"
                  },
                  "path": {
                    "type": "string",
                    "description": "Download path on the same site (valid for about 2 hours)."
                  }
                }
              }
            }
          },
          "units": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "assumptions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "sources": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "title"
              ],
              "properties": {
                "title": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                },
                "publisher": {
                  "type": "string"
                },
                "retrievedAt": {
                  "type": "string"
                },
                "note": {
                  "type": "string"
                }
              }
            }
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "presentation": {
            "type": "array",
            "items": {
              "type": "object"
            },
            "description": "Display blocks used by the human page (same data)."
          },
          "links": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "human",
              "api",
              "openapi",
              "methodology"
            ],
            "properties": {
              "human": {
                "type": "string",
                "format": "uri"
              },
              "api": {
                "type": "string",
                "format": "uri"
              },
              "openapi": {
                "type": "string",
                "format": "uri"
              },
              "methodology": {
                "type": "string",
                "format": "uri"
              }
            }
          }
        }
      }
    }
  }
}