{"id":13880042,"url":"https://github.com/jejacks0n/apitome","last_synced_at":"2025-05-15T12:07:08.711Z","repository":{"id":44892305,"uuid":"12651124","full_name":"jejacks0n/apitome","owner":"jejacks0n","description":"Apitome: /iˈpitəmē/ An API documentation presentation layer for RSpec API Documentation output.","archived":false,"fork":false,"pushed_at":"2024-07-24T17:55:38.000Z","size":366,"stargazers_count":250,"open_issues_count":10,"forks_count":126,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-04-11T21:48:56.660Z","etag":null,"topics":["documentation","rad","rails","rspec"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jejacks0n.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"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}},"created_at":"2013-09-06T18:15:49.000Z","updated_at":"2024-12-13T11:57:50.000Z","dependencies_parsed_at":"2024-06-18T15:23:55.141Z","dependency_job_id":"b0c956c8-739b-4a36-a970-f63c8a50ff67","html_url":"https://github.com/jejacks0n/apitome","commit_stats":{"total_commits":147,"total_committers":43,"mean_commits":"3.4186046511627906","dds":0.5442176870748299,"last_synced_commit":"62b0a54aa292a38f186c605af8e69760270ed037"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jejacks0n%2Fapitome","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jejacks0n%2Fapitome/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jejacks0n%2Fapitome/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jejacks0n%2Fapitome/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jejacks0n","download_url":"https://codeload.github.com/jejacks0n/apitome/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254337612,"owners_count":22054254,"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","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":["documentation","rad","rails","rspec"],"created_at":"2024-08-06T08:02:44.777Z","updated_at":"2025-05-15T12:07:03.701Z","avatar_url":"https://github.com/jejacks0n.png","language":"Ruby","funding_links":[],"categories":["Ruby"],"sub_categories":[],"readme":"Apitome\n=======\n\n[![Gem Version](https://img.shields.io/gem/v/apitome.svg)](https://rubygems.org/gems/apitome)\n[![Build Status](https://img.shields.io/travis/jejacks0n/apitome.svg)](https://travis-ci.org/jejacks0n/apitome)\n[![Maintainability](https://api.codeclimate.com/v1/badges/eb8dd1c22f1da11b6c02/maintainability)](https://codeclimate.com/github/jejacks0n/apitome/maintainability)\n[![Test Coverage](https://api.codeclimate.com/v1/badges/eb8dd1c22f1da11b6c02/test_coverage)](https://codeclimate.com/github/jejacks0n/apitome/test_coverage)\n[![License](https://img.shields.io/badge/license-MIT-brightgreen.svg)](https://opensource.org/licenses/MIT)\n\nApitome is a API documentation tool for Rails built on top of the great RSpec DSL included in\n[rspec_api_documentation](https://github.com/zipmark/rspec_api_documentation) (RAD). It's designed to display the\ndocumentation generated by RAD in either a single page, or on individual pages, and uses Bootstrap for most of the basic\nstyling and [highlight.js](https://github.com/isagalaev/highlight.js) for code highlighting.\n\nYou can provide a markdown file that will be displayed as the README page, and by taking advantage of its modular view\nstructure you can override any number of views and partials to customize the output. You can also specify custom css and\njavascript if you want to do fancier things or change how it looks.\n\n## Installation\nAdd it to your Gemfile.\n\n```ruby\ngem \"apitome\"\n```\n\nOptionally run the install generator to get the initializer and an initial readme file (doc/api.md).\n\n```\nrails generate apitome:install\n```\n\nYou can get the assets installed using the generator by providing a `--assets` flag.\n\nUpdate your `spec_helper.rb` to adjust how RAD outputs its results -- Apitome reads these JSON files to generate the\ndocumentation.\n\n```ruby\nRspecApiDocumentation.configure do |config|\n  config.format = :json\nend\n```\n\n## Usage\nYou can view your documentation at the default `api/docs` route.\n\n## Configuration\nAfter installation, your app will have an apitome initializer (app/config/initializers/apitome.rb). You will find the\nfollowing parameters that can be used to customize apitome. Note: Restart rails after changing any of these parameters.\n\n\u003cdl\u003e\n\u003cdt\u003e mount_at \u003c/dt\u003e\u003cdd\u003e\n  This determines where the Apitome routes will be mounted. Changing this to \"/api/documentation\" for instance would\n  allow you to browse to http://localhost:3000/api/documentation to see your api documentation. Set to nil and mount\n  it yourself if you need to.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"/api/docs\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e root \u003c/dt\u003e\u003cdd\u003e\n  This defaults to Rails.root if left nil. If you're providing documentation for an engine using a dummy application\n  it can be useful to set this to your engines root. (E.g. \u003ccode\u003eApplication::Engine.root\u003c/code\u003e)\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003enil\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e doc_path \u003c/dt\u003e\u003cdd\u003e\n  This is where rspec_api_documentation outputs the JSON files. This is configurable within RAD, and so is\n  configurable here.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"doc/api\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e parent_controller \u003c/dt\u003e\u003cdd\u003e\n  Set the parent controller that Apitome::DocsController will inherit from. Useful if you want to use a custom\n  \u003ccode\u003ebefore_action\u003c/code\u003e for instance.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"ActionController::Base\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e title \u003c/dt\u003e\u003cdd\u003e\n  The title of the documentation -- If your project has a name, you'll want to put it here.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"Apitome Documentation\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e layout \u003c/dt\u003e\u003cdd\u003e\n  The main layout view for all documentation pages. By default this is pretty basic, but you may want to use your own\n  application layout.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"apitome/application\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e code_theme \u003c/dt\u003e\u003cdd\u003e\n  We're using [highlight.js](https://github.com/isagalaev/highlight.js) for code highlighting, and it comes with some\n  great themes. You can check [here for themes](http://softwaremaniacs.org/media/soft/highlight/test.html), and enter\n  the theme as lowercase/underscore.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"default\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e css_override \u003c/dt\u003e\u003cdd\u003e\n  This allows you to override the css manually. You typically want to require \u003ccode\u003eapitome/application\u003c/code\u003e within the\n  override, but if you want to override it entirely you can do so.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003enil\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e js_override \u003c/dt\u003e\u003cdd\u003e\n  This allows you to override the javascript manually. You typically want to require \u003ccode\u003eapitome/application\u003c/code\u003e within the\n  override, but if you want to override it entirely you can do so.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003enil\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e readme \u003c/dt\u003e\u003cdd\u003e\n  You can provide a \"README\" style markdown file for the documentation, which is a useful place to include general\n  information. This path is relative to your doc_path configuration.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e\"../api.md\"\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e single_page \u003c/dt\u003e\u003cdd\u003e\n  Apitome can render the documentation into a single page that uses scrollspy, or it can render the documentation on\n  individual pages on demand. This allows you to specify which one you want, as a single page may impact performance.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003etrue\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e url_formatter \u003c/dt\u003e\u003cdd\u003e\n  You can specify how urls are formatted using a Proc or other callable object.  Your proc will be called with a\n  resource name or link, giving you the opportunity to modify it as necessary for in the documentation url.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003e-\u003e (str) { str.gsub(/\\.json$/, '').underscore.gsub(/[^0-9a-z]+/i, '-') }\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e remote_url \u003c/dt\u003e\u003cdd\u003e\n  You can setup the docs to be loaded from a remote URL if they are not available in the application environment. This\n  URL is used as the base location and should be set to where the readme is located. If left nil, local is assumed.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003enil\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e http_basic_authentication \u003c/dt\u003e\u003cdd\u003e\n  If using remote urls you can fetch the remote docs using HTTP Basic Authentication by configuring this to be an\n  array of the user and password. (E.g. \u003ccode\u003e['user', 'password']\u003c/code\u003e)\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003enil\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e precompile_assets \u003c/dt\u003e\u003cdd\u003e\n  By default all assets that ship with this library are precompiled by the asset pipeline. If you would prefer to\n  control this yourself, you can disable it by changing this to false.\n  \u003cbr/\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003etrue\u003c/code\u003e\n\u003c/dd\u003e\n\n\u003cdt\u003e simulated_response \u003c/dt\u003e\u003cdd\u003e\n  If \u003ccode\u003esimulated_response\u003c/code\u003e is disabled you can hide the \"Simulated Response\" links.\n  \u003cbr\u003e\n  \u003cb\u003edefault:\u003c/b\u003e \u003ccode\u003etrue\u003c/code\u003e\n\u003c/dd\u003e\n\nWhen you install Apitime an initializer file (app/config/initializers/apitome.rb) is generated that contains good\ndocumentation for each configuration directive. Otherwise you can get a refresher by checking the\n[Apitome Configuration](https://github.com/modeset/apitome/wiki/Apitome-Configuration) article.\n\n## Customization\nYou can put custom views and partials in your own `views/apitome/docs` -- check\n[here for examples](https://github.com/jejacks0n/apitome/tree/master/app/views/apitome/docs). You can put any\npartial in your own path and they will be overridden.\n\nAdditional customization can come in the form of providing custom css and javascript. You can do this by creating the\nfiles you want (that often times require the default assets in the gem), and then configure Apitome to use those instead\nof the defaults.\n\n## License\nLicensed under the [MIT License](http://creativecommons.org/licenses/MIT/)\n\nCopyright 2016 [jejacks0n](https://github.com/jejacks0n)\n\n## Make Code Not War\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjejacks0n%2Fapitome","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjejacks0n%2Fapitome","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjejacks0n%2Fapitome/lists"}