{"id":28551526,"url":"https://github.com/typisttech/swagger_ui_standalone","last_synced_at":"2025-10-17T16:23:38.033Z","repository":{"id":293939461,"uuid":"985555475","full_name":"typisttech/swagger_ui_standalone","owner":"typisttech","description":"Generate standalone static Swagger UI sites from OpenAPI specifications.","archived":false,"fork":false,"pushed_at":"2025-10-08T21:57:37.000Z","size":6596,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-09T22:58:08.788Z","etag":null,"topics":["openapi","static-site-generator","swagger-ui"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/typisttech.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["tangrufus"],"custom":["https://typist.tech/donation/"]}},"created_at":"2025-05-18T02:48:12.000Z","updated_at":"2025-10-08T21:57:40.000Z","dependencies_parsed_at":"2025-08-20T15:23:47.634Z","dependency_job_id":"fb4b8c5c-d267-4df3-8bc8-acff9445be0c","html_url":"https://github.com/typisttech/swagger_ui_standalone","commit_stats":null,"previous_names":["typisttech/swagger_ui_standalone"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/typisttech/swagger_ui_standalone","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typisttech%2Fswagger_ui_standalone","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typisttech%2Fswagger_ui_standalone/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typisttech%2Fswagger_ui_standalone/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typisttech%2Fswagger_ui_standalone/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/typisttech","download_url":"https://codeload.github.com/typisttech/swagger_ui_standalone/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typisttech%2Fswagger_ui_standalone/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279182756,"owners_count":26121248,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-16T02:00:06.019Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["openapi","static-site-generator","swagger-ui"],"created_at":"2025-06-10T03:39:11.888Z","updated_at":"2025-10-17T16:23:38.028Z","avatar_url":"https://github.com/typisttech.png","language":"Ruby","funding_links":["https://github.com/sponsors/tangrufus","https://typist.tech/donation/"],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n# Swagger UI Standalone\n\n[![Gem Version](https://img.shields.io/gem/v/swagger_ui_standalone)](https://badge.fury.io/rb/swagger_ui_standalone)\n[![Ruby](https://github.com/typisttech/swagger_ui_standalone/actions/workflows/main.yml/badge.svg)](https://github.com/typisttech/swagger_ui_standalone/actions/workflows/main.yml)\n[![License](https://img.shields.io/github/license/typisttech/swagger_ui_standalone.svg)](https://github.com/typisttech/swagger_ui_standalone/blob/master/LICENSE.txt)\n[![Follow @TangRufus on X](https://img.shields.io/badge/Follow-TangRufus-15202B?logo=x\u0026logoColor=white)](https://x.com/tangrufus)\n[![Follow @TangRufus.com on Bluesky](https://img.shields.io/badge/Bluesky-TangRufus.com-blue?logo=bluesky)](https://bsky.app/profile/tangrufus.com)\n[![Sponsor @TangRufus via GitHub](https://img.shields.io/badge/Sponsor-TangRufus-EA4AAA?logo=githubsponsors)](https://github.com/sponsors/tangrufus)\n[![Hire Typist Tech](https://img.shields.io/badge/Hire-Typist%20Tech-778899)](https://typist.tech/contact/)\n\n\u003cp\u003e\n  \u003cstrong\u003eGenerate standalone static Swagger UI sites from OpenAPI specifications.\u003c/strong\u003e\n  \u003cbr\u003e\n  \u003cbr\u003e\n  Built with ♥ by \u003ca href=\"https://typist.tech/\"\u003eTypist Tech\u003c/a\u003e\n\u003c/p\u003e\n\n\u003c/div\u003e\n\n---\n\n## Quick Start\n\n```bash\n# Install the gem\ngem install swagger_ui_standalone\n\n# Prepare some custom files\nmkdir custom\n\n## Download some OpenAPI specifications\nwget https://raw.githubusercontent.com/github/rest-api-description/refs/heads/main/descriptions/api.github.com/api.github.com.yaml -O custom/github.yaml\nwget https://validator.swagger.io/validator/openapi.json -O custom/validator.yaml\n\n## Make a disallow all robots.txt file\ncat \u003e custom/robots.txt \u003c\u003cEOF\nUser-agent: *\nDisallow: /\nEOF\n\n## Create custom swagger-initializer.js to override the default file\ncat \u003e custom/swagger-initializer.js \u003c\u003cEOF\nwindow.onload = function() {\n  window.ui = SwaggerUIBundle({\n    urls: [\n      {name: \"GitHub\", url: \"github.yaml\"},\n      {name: \"Validator\", url: \"validator.yaml\"},\n      {name: \"Petstore (External)\", url: \"https://petstore.swagger.io/v2/swagger.json\"},\n    ],\n    dom_id: '#swagger-ui',\n    deepLinking: true,\n    presets: [\n      SwaggerUIBundle.presets.apis,\n      SwaggerUIStandalonePreset\n    ],\n    plugins: [\n      SwaggerUIBundle.plugins.DownloadUrl\n    ],\n    layout: \"StandaloneLayout\"\n  });\n};\nEOF\n\n# Generate a standalone static Swagger UI site into the output directory\nswagger_ui_standalone generate --custom custom --output output\n```\n\nThe `generate` command downloads the latest release of Swagger UI from GitHub and copy the `dist` directory to the `output` directory. \nThen, the `custom` directory is copied as is, so you can add or overwrite files in the `output` directory.\n\n```console\n$ tree custom output\ncustom\n├── github.yaml\n├── robots.txt\n├── swagger-initializer.js\n└── validator.yaml\noutput\n├── favicon-16x16.png\n├── favicon-32x32.png\n├── github.yaml\n├── index.css\n├── index.html\n├── oauth2-redirect.html\n├── robots.txt\n├── swagger-initializer.js\n├── swagger-ui-bundle.js\n├── swagger-ui-bundle.js.map\n├── swagger-ui-es-bundle-core.js\n├── swagger-ui-es-bundle-core.js.map\n├── swagger-ui-es-bundle.js\n├── swagger-ui-es-bundle.js.map\n├── swagger-ui-standalone-preset.js\n├── swagger-ui-standalone-preset.js.map\n├── swagger-ui.css\n├── swagger-ui.css.map\n├── swagger-ui.js\n├── swagger-ui.js.map\n└── validator.yaml\n\n# Start a local web server to serve the static site with webrick\n# See https://gist.github.com/willurd/5720255 for alternatives\n$ gem install webrick\n$ ruby -run -ehttpd output -p8000\n```\n\n## Usage\n\n### `generate`\n\n```console\n$ swagger_ui_standalone help generate\nUsage:\n  swagger_ui_standalone generate [options] --custom=DIRECTORY --output=DIRECTORY\n\nOptions:\n  --custom=DIRECTORY      # Path to the directory containing custom files, which will be copied to the output directory\n  --output=DIRECTORY      # Where to write the generated files\n  [--repo=OWNER/REPO]     # GitHub repository to download in the format \u003cowner/repo\u003e\n                          # Default: swagger-api/swagger-ui\n  [--ref=TAG|BRANCH|SHA]  # Git reference to download (can be a tag, branch or commit SHA). Omit to use the latest release\n  [--force]               # Overwrite files that already exist\n\nGenerate standalone static Swagger UI\n```\n\n### `download`\n\n```console\n$ swagger_ui_standalone help download\nUsage:\n  swagger_ui_standalone download [options] --output=DIRECTORY\n\nOptions:\n  --output=DIRECTORY      # Where to write the generated files\n  [--repo=OWNER/REPO]     # GitHub repository to download in the format \u003cowner/repo\u003e\n                          # Default: swagger-api/swagger-ui\n  [--ref=TAG|BRANCH|SHA]  # Git reference to download (can be a tag, branch or commit SHA). Omit to use the latest release\n  [--force]               # Overwrite files that already exist\n\nDownload standalone static Swagger UI source code\n```\n\n## Installation\n\nInstall the gem and add to the application's Gemfile by executing:\n\n```bash\nbundle add swagger_ui_standalone\n```\n\nIf bundler is not being used to manage dependencies, install the gem by executing:\n\n```bash\ngem install swagger_ui_standalone\n```\n\n## Credits\n\n[`Swagger UI Standalone`](https://github.com/typisttech/swagger_ui_standalone) is a [Typist Tech](https://typist.tech) project and\nmaintained by [Tang Rufus](https://x.com/TangRufus), freelance developer [for hire](https://typist.tech/contact/).\n\nFull list of contributors can be found [on GitHub](https://github.com/typisttech/swagger_ui_standalone/graphs/contributors).\n\n## Copyright and License\n\nThis project is a [free software](https://www.gnu.org/philosophy/free-sw.en.html) distributed under the terms of\nthe MIT license. For the full license, see [LICENSE](./LICENSE.txt).\n\n## Contribute\n\nFeedbacks / bug reports / pull requests are welcome.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftypisttech%2Fswagger_ui_standalone","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftypisttech%2Fswagger_ui_standalone","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftypisttech%2Fswagger_ui_standalone/lists"}