diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..c2cdfb8a --- /dev/null +++ b/.editorconfig @@ -0,0 +1,21 @@ +# EditorConfig helps developers define and maintain consistent +# coding styles between different editors and IDEs +# editorconfig.org + +root = true + + +[*] + +# Change these settings to your own preference +indent_style = space +indent_size = 2 + +# We recommend you to keep these unchanged +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[*.md] +trim_trailing_whitespace = false diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 00000000..c6757a49 --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,24 @@ +module.exports = { + extends: [ + 'eslint:recommended', + ], + plugins: [ + 'prettier', + ], + env: { + es6: true, + browser: false, + node: true, + commonjs: true, + }, + parserOptions: { + ecmaVersion: 7, + }, + rules: { + 'prettier/prettier': ['error', {trailingComma: 'es5', singleQuote: true}], + 'no-console': 'off', + 'prefer-const': 'error', + 'eqeqeq': 'error', + 'no-useless-return': 'error', + } +}; diff --git a/.gitignore b/.gitignore index a72b52eb..309da4d9 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,7 @@ results npm-debug.log node_modules + +.idea +.DS_Store +.vscode diff --git a/.nvmrc b/.nvmrc new file mode 100644 index 00000000..f6cdf409 --- /dev/null +++ b/.nvmrc @@ -0,0 +1 @@ +4.7.0 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 0a53055d..00000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,12 +0,0 @@ -# Contributing to raml2html - -raml2html is an open source project and your contribution is very much appreciated. - -1. Check for open issues or open a fresh issue to start a discussion around a feature idea or a bug. -2. Fork the repository on Github and make your changes on the **develop** branch (or branch off of it). - Please retain the code style that is used in the project. -3. Add an example of the new feature to example.raml (if applicable) -4. Send a pull request (with the **develop** branch as the target). - -A big thank you goes out to everyone who helped with the project, the [contributors](https://github.com/kevinrenskers/raml2html/graphs/contributors) -and everyone who took the time to report issues and give feedback. diff --git a/README.md b/README.md index 92100349..f4c13c2c 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,13 @@ -# RAML to HTML +# raml2html -A simple RAML to HTML documentation generator, written for Node.js. +[![Downloads](https://img.shields.io/npm/dm/raml2html.svg)](https://www.npmjs.com/package/raml2html) +[![NPM version](https://img.shields.io/npm/v/raml2html.svg)](https://www.npmjs.org/package/raml2html) +[![Prettier](https://img.shields.io/badge/code%20style-prettier-blue.svg?style=flat)](https://github.com/prettier/prettier) + +A simple RAML to HTML documentation generator, written for Node.js, with theme support. + +### RAML version support +raml2html 4 and higher only support RAML 1.0 files. Please stick with raml2html 3.x for RAML 0.8 support. ## Install @@ -9,36 +16,78 @@ npm i -g raml2html ``` -## Usage -As a command line script: +## Themes +raml2html ships with a default theme, but you can install more from NPM. For example, to render +RAML to Markdown, you can install the raml2html-markdown-theme theme: ``` -raml2html example.raml > example.html -raml2html -i example.raml -o example.html +npm i -g raml2html-markdown-theme ``` -As a library: +Search NPM for the "raml2html-theme" keyword (or use [this link](https://www.npmjs.com/browse/keyword/raml2html-theme)) +to find more themes. +## Usage + +### As a command line script +``` +raml2html --help +raml2html example.raml > example.html +raml2html --theme raml2html-markdown-theme example.raml > example.html +raml2html --template my-custom-template.nunjucks -i example.raml -o example.html ``` -var raml2html = require('raml2html'); -// Using the default templates: -// source can either be a filename, file contents (string) or parsed RAML object -raml2html.parse(source, onSuccess, onError); +### As a library + +#### Using the default theme, different themes, or your own Nunjucks templates +```javascript +const raml2html = require('raml2html'); +const configWithDefaultTheme = raml2html.getConfigForTheme(); +const configForDifferentTheme = raml2html.getConfigForTheme('raml2html-markdown-theme'); +const configWithCustomTemplate = raml2html.getConfigForTemplate('~/path/to/my-custom-template.nunjucks'); + +// source can either be a filename, url, or parsed RAML object +raml2html.render(source, configWithDefaultTheme).then(function(result) { + // Save the result to a file or do something else with the result +}, function(error) { + // Output error +}); +``` -// Using your own templates: -// - config should be an object with at least an `template` property -// - config can also include `helpers` and `partials` -// - the config object will be accessible from your handlebars templates -raml2html.parseWithConfig(source, config, onSuccess, onError); +#### Using your own processing function, for full control over the whole rendering process +```javascript +/** + * config should be an object with at least an `processRamlObj` property which is a function that receives the raw RAML + * object and must return a promise with the result. You can do whatever you want in this function. + * + * You can also supply a postProcessHtml function that can for example minify the generated HTML. + * + * You can also supply a writeOutput function that takes over writing the output (to disk for example). + * + * You can also supply a setupNunjucks function that takes the env as its only parameter. + */ +raml2html.render(source, config).then(function(result) { + // Save the result to a file or do something else with the result +}, function(error) { + // Output error +}); ``` +See also `example/script.js` for multiple examples of using raml2html as a library. + ### Gulp -There's a Gulp plugin at https://www.npmjs.org/package/gulp-raml2html. +You can use the [raml2html directly from Gulp](https://gist.github.com/iki/784ddd5ab33c1e1b726b). ## Example output -![Example output](https://raw.github.com/kevinrenskers/raml2html/master/examples/example.png) +Please see the following links for live examples: +- https://rawgit.com/raml2html/default-theme/master/examples/helloworld.html +- https://rawgit.com/raml2html/default-theme/master/examples/world-music-api.html + + +## Before you report a bug +If you get parsing errors, please do not report them to raml2html: it doesn't do the actual RAML parsing. +Review the error and fix your RAML file, or open a new issue at [raml-js-parser-2](https://github.com/raml-org/raml-js-parser-2). ## Contributing @@ -46,20 +95,30 @@ raml2html is an open source project and your contribution is very much appreciat 1. Check for open issues or open a fresh issue to start a discussion around a feature idea or a bug. 2. Fork the repository on Github and make your changes on the **develop** branch (or branch off of it). - Please retain the code style that is used in the project. + Run `npm run lint` before committing to check for common problems and auto format all code. 3. Add an example of the new feature to example.raml (if applicable) 4. Send a pull request (with the **develop** branch as the target). -A big thank you goes out to everyone who helped with the project, the [contributors](https://github.com/kevinrenskers/raml2html/graphs/contributors) +If your pull request is merged feel free to ask for push access. We want to get more maintainers! If you do +have push access, please still work on feature branches and create pull requests, which then get reviewed. +You can also review other people's pull requests and be involved in that way. + +A big thank you goes out to everyone who helped with the project, the [contributors](https://github.com/raml2html/raml2html/graphs/contributors) and everyone who took the time to report issues and give feedback. +### Local setup +To get the best environment to work on raml2html and the default theme, follow these steps. + +1. Checkout raml2html-default-theme's develop branch; `npm link`. +2. Checkout raml2html's develop branch; first `npm link raml2html-default-theme` and then `npm link`. +3. In raml2html-default-theme run `npm link raml2html`. + +Now both projects are installed globally, but using the local development versions of both. +From the theme repo's examples folder you can run the `render-all-examples` script without problem. -## To do -This project is still a work in progress, but the output is very usable already (and is in fact used by multiple -companies including Google). Still left to do, in no particular order: -* Template options (for example to turn off side bar navigation) -* Finish HTML output, currently there's still some stuff missing (like securedBy) +## Changelog +See [changelog.md](https://github.com/raml2html/raml2html/blob/master/changelog.md) ## License diff --git a/bin/raml2html b/bin/raml2html new file mode 100755 index 00000000..5bcc41d4 --- /dev/null +++ b/bin/raml2html @@ -0,0 +1,154 @@ +#!/usr/bin/env node + +'use strict'; + +const chalk = require('chalk'); +const fs = require('fs'); +const path = require('path'); +const yargs = require('yargs'); +const raml2html = require('..'); +const pjson = require('../package.json'); + +const argv = yargs + .usage('Usage: raml2html [options] [RAML input file]') + .version(pjson.version) + + .help('h') + .alias('h', 'help') + + .string('i') + .alias('i', 'input') + .describe('i', 'Input file') + + .string('o') + .alias('o', 'output') + .describe('o', 'Output file') + + .string('t') + .alias('t', 'template') + .describe('t', 'Template path') + + .boolean('p') + .alias('p', 'pretty') + .describe('p', 'Pretty output (non-minified)') + + .boolean('v') + .alias('v', 'validate') + .describe('v', 'Validate RAML (off by default)') + + .array('e') + .alias('e', 'extensionsAndOverlays') + .describe('e', 'Extensions and overlays paths') + + .string('theme') + .describe('theme', 'Theme name') + + .example('raml2html example.raml > example.html') + .example('raml2html --template my-template.nunjucks -i example.raml -o example.html') + .example('raml2html --theme raml2html-markdown-theme example.raml > example.html') + .example('raml2html -v example.raml > example.html') + .example('raml2html -e extension.raml overlay.raml -i example.raml -o example.html') + .argv; + +let input = argv.input; + +if (!input) { + if (argv._.length !== 1) { + console.error('Error: You need to specify the RAML input file\n'); + yargs.showHelp(); + process.exit(1); + } + + input = argv._[0]; +} + +let config; +if (argv.template) { + config = raml2html.getConfigForTemplate(argv.template); +} else { + config = raml2html.getConfigForTheme(argv.theme, argv); +} + +function writeOutput(result, config, argv) { + return new Promise((resolve, reject) => { + if (argv.output) { + fs.writeFile(argv.output, result, err => { + if (err) { + reject(err); + } else { + resolve(); + } + }); + } else { + // Simply output to console + process.stdout.write(result, resolve); + } + }); +} + +function errorPath(error) { + const dir = path.dirname(input); + + return [ + path.join(dir, error.path), + error.range.start.line, + error.range.start.column, + ].join(':'); +} + +function errorMessage(error) { + return `${error.code}: ${error.message}`; +} + +function errorStackTrace(error, nocolor) { + let message = `${errorMessage(error)} (${errorPath(error)})`; + + if (!nocolor) { + if (error.isWarning) { + message = chalk.yellow(message); + } else { + message = chalk.red(message); + } + } + + if (error.trace) { + message += '\n ' + errorStackTrace(error.trace[0], true); + } + + return message; +} + +function writeParserErrors(parserErrors) { + parserErrors.forEach(error => { + console.error(errorStackTrace(error)); + }); +} + +// Start the rendering process +raml2html + .render(input, config, argv) + .then(result => { + return (config.writeOutput || writeOutput)(result, config, argv); + }) + .then(() => process.exit(0)) + .catch(error => { + if (error.message) { + console.error(chalk.bgRed(error.message) + '\n'); + } + + if (error.parserErrors) { + let parserErrors = error.parserErrors; + + if (argv.suppressWarnings) { + parserErrors = parserErrors.filter(error => !error.isWarning); + } + + if (argv.rawErrors) { + console.error(JSON.stringify(parserErrors, null, 2)); + } else { + writeParserErrors(parserErrors); + } + } + + process.exit(1); + }); diff --git a/changelog.md b/changelog.md index 2169e620..6ec7419b 100644 --- a/changelog.md +++ b/changelog.md @@ -1,3 +1,341 @@ +7.7.0 - Jan 25, 2021 +- Updated dependencies + +7.6.0 - Jul 16, 2020 +- Updated dependencies + +7.5.0 - Oct 30, 2019 +- Updated dependencies + +7.4.0 - May 29, 2019 +- Add support for RAML parser resolvers options + +7.3.0 - March 24, 2019 +- Updated 3rd party dependencies like marked and nunjucks + +7.2.2 - February 23, 2019 +- Removed unused CLI options and examples + +7.2.1 - November 27, 2018 +- Refix #259 + +7.2.0 - September 11, 2018 +- You can now give paths to extensions and overlays using the `-e` option +- Pretty printed parse errors by default when using the `--validate` option (turn off with `--raw-errors`) + +7.1.0 - April 6, 2018 +- Themes can now supply their own `writeOutput` function to control how they handle the output + +7.0.0 - February 18, 2018 +- Using raml2obj 6.0.0 and the new default theme 2.7.0 + +6.7.0 - February 13, 2018 +- Added the `pretty` library as a dependency, for use with the `--pretty` option + +6.6.0 - January 20, 2018 +- CLI options are now added to ramlObj, so they can be used in templates + +6.5.0 - January 9, 2018 +- Switched marked dependency back to marked +- Updated other dependencies like yargs, eslint, and prettier + +6.4.2 - November 10, 2017 +- Switched marked dependency to 8fold-marked + +6.4.1 - August 4, 2017 +- Fixed a bug where if no options were given at all to the render function you'd get an error + +6.4.0 - July 16, 2017 +- Added a new --pretty command line option to turn off html minification + +6.3.0 - April 25, 2017 +- Added a new --validate command line option to turn on validation, which is now off by default (#345) + +6.2.0 - April 21, 2017 +- Fixed template path handling (#343) + +6.1.1 - April 14, 2017 +- Updated third party dependencies + +6.1.0 - March 24, 2017 +- Updated raml2obj dependency, also made it less strict + +6.0.0 - March 17, 2017 +- Updated from raml2obj 4.1.0 to 5.1.0, which has backwards incompatible changes to securedBy + (among other bug fixes) +- Updated to raml2html-default-theme 2.0.0 to deal with these securedBy changes + +5.1.0 - March 9, 2017 +- All program arguments can now be passed on to themes, so themes can support their + own config options +- Switched from using ESLint for code formatting to Prettier. We still use ESLint, + Prettier is run as a plugin through it. ESLint still checks for bugs. + +5.0.0 - February 14, 2017 +- Added support for themes: + - the command line interface now takes an optional `--theme` parameter + - we ship two officially supported themes: raml2html-default-theme and raml2html-markdown-theme + - themes can overwrite the entire rendering process, allowing themes to use different templating engines + or output formats (Markdown, PDF, etc) + - the `getDefaultConfig` function has been split into `getConfigForTemplate` and `getConfigForTheme`, + use `getConfigForTheme` without any parameters to get the old behaviour of `getDefaultConfig` + +4.1.1 - February 6, 2017 +- Improved error reporting (#316) + +4.1.0 - January 28, 2017 +- Render more information about examples (name, description) (#313) +- Render more security scheme data (#310) +- Updated raml2obj, which + - Updated raml-js-parser-2 dependancy + - Fixed types' parent overriding behaviour + +4.0.6 - January 23, 2017 +- Fixed template render error (#305) + +4.0.5 - January 9, 2017 +- Fix array examples (#302) + +4.0.4 - December 27, 2016 +- Put properties before example for item (#299) +- Fix template variable reference that prevented type properties from rendering (#300) + +4.0.3 - December 12, 2016 +- Render item examples (#293) + +4.0.2 - December 8, 2016 +- Improve error output (#289) + +4.0.1 - December 8, 2016 +- Documentation fixes + +4.0.0 - December 1, 2016 +- We're releasing 4.0.0 with RAML 1 support. Please keep in mind that we no longer support RAML 0.8 files. For other changes please check the beta's below. + +4.0.0-beta18 - November 30, 2016 +- Updated raml2obj + +4.0.0-beta17 - November 23, 2016 +- Improved rendering of nested properties (#274) + +4.0.0-beta16 - November 22, 2016 +- Improved rendering of inherited array properties (#277) + +4.0.0-beta15 - November 21, 2016 +- Updated raml2obj +- Fixed rendering of type array of primitives (like string[]) + +4.0.0-beta14 - November 3, 2016 +- Fixed template render error (#272) + +4.0.0-beta13 - November 2, 2016 +- Updated raml2obj to 4.0.0-beta13, fixing type expansion in uriParameters (#271) + +4.0.0-beta12 - November 1, 2016 +- Improved array type support (#265) + +4.0.0-beta11 - November 1, 2016 +- Updated raml2obj to 4.0.0-beta11, solving problems with JSON datatypes + +4.0.0-beta10 - October 31, 2016 +- Updated raml2obj to 4.0.0-beta10 + +4.0.0-beta9 - October 19, 2016 +- Deal with object datatypes + +4.0.0-beta8 - October 14, 2016 +- Updated raml2obj to 4.0.0-beta9, which deals with type inheritance + +4.0.0-beta7 - October 5, 2016 +- Rendering types + +4.0.0-beta6 - October 4, 2016 +- Using raml2obj 4.0.0-beta7 + +4.0.0-beta5 - September 30, 2016 +- Fixed files list in package.json + +4.0.0-beta4 - September 29, 2016 +- Using raml2obj 4.0.0-beta6 which expands types and always gives consistent examples arrays +- Rendering baseUriParameters +- Rendering `properties` instead of `formParameters` +- Rendering multiple `examples` +- Improved rendering of single item enums +- Very basic initial rendering of annotations on methods +- Removed rendering of `types` for now + +4.0.0-beta3 - September 27, 2016 +- Allow Nunjucks config via a `config.setupNunjucks` function (#261) +- Fixed securedBy usage in the templates +- Added a full featured RAML 1.0 example file (world-music-api.raml) +- Fixed examples/script.js + +4.0.0-beta2 - September 26, 2016 +- Using raml2obj 4.0.0-beta3 +- Fixed templates to use the changed output from raml2obj +- Added a new basic example RAML file +- Removed a bunch of old examples + +3.0.1 - September 16, 2016 +- Fixed a problem where the output would be truncated after 65536 characters (#259) + +4.0.0-beta1 - August 10, 2016 +- Using raml2obj 4.0.0-beta1, which adds support for RAML 1.0 + (even though raml2html's template doesn't support that yet) + +3.0.0 - August 10, 2016 +- Released without further changes + +3.0.0-beta2 - August 8, 2016 +- Updated to raml2obj 3.0.0-beta2 +- Fixed rendering of the github.raml example file (#249) + +3.0.0-beta1 - August 7, 2016 +- Updated code to use ES6 syntax +- Updated all dependencies +- Breaking change: Node 4 or higher is now required +- Breaking change: nunjucks-markdown 2.0.0 is a bit fuzzy with whitespace, please check + https://github.com/raml2html/raml2html/pull/231 for help with updating your custom templates. + +2.5.0 - August 4, 2016 +- Updated highlight.js to 9.3.0 +- Added support for securedBy scopes +- Added syntax highlighting within modals +- Improved item display of values false and 0 +- Improved multiple security schemes handling +- Horizontally scroll overflowing code snippets + +2.4.0 - March 12, 2016 +- Downgraded Nunjucks back to 1.3.0 due to peer conflicts with nunjucks-markdown + (which can't be upgraded because the newest version is broken) + +2.3.0 - February 23, 2016 +- Updated all 3rd party dependancies +- Fix default tab selection +- Improved security schema rendering +- Expand $ref properties by using raml-json-expander + +2.2.0 - January 20, 2016 +- Now writing parse errors to STDERR + +2.1.2 - November 13, 2015 +- Better fix for #152 (#157) + +2.1.1 - November 5, 2015 +- Fix JS error in Chrome when opening the html file from the local file system and then closing a modal (#152) + +2.1.0 - August 25, 2015 +- Update third party dependencies and ESLint rules +- Nunjucks 1.3.0 makes working with relative template includes a lot easier, use like this: + {% include "./resource.nunjucks" %} +- Fixed bug where multiple instances of raml2html would share the Nunjucks config, + even if one of them needed to use a different templatePath +- Removed the templatePath option from the CLI since relative templates now work as expected +- Render description for securityScheme +- Fixed table formatting + +2.0.2 - June 23, 2015 +- Fixed rendering of XML/HTML examples and schemes by properly escaping these variables (#140) + +2.0.1 - May 27, 2015 +- Fixed rendering of header + +2.0.0 - May 22, 2015 +- Using a promise based API, please see README for updated usage example +- Using Nunjucks by default, instead of Handlebars +- Made it a lot easier to completely customize the entire rendering process, allowing you for example to use not only + custom templates but even a different template engine +- Got rid of the -s / https option, all external sources are simply always loaded via https +- Got rid of the -r and -m template options, as the resource- and item templates are now simply loaded from within + the main template + +1.6.0 - March 24, 2015 +- Use hash tags for opening modals (#131) + +1.5.0 - March 11, 2015 +- Made the side menu a fixed height (#110) +- Added a background color for PATCH (#117) +- Response tab is set to active when request tab isn't shown (#120) +- Added additional information in query parameter (#121) + +1.4.0 - January 30, 2015 +- If an example's type is explicitly set to 'string' then don't syntax highlight it + +1.3.1 - January 28, 2015 +- Fixed the id's of the tabs (#108) + +1.3.0 - January 21, 2015 +- Now rendering default values for parameters (#100) and securedBy (#10) + +1.2.0 - January 20, 2015 +- Greatly simplified the loading of (custom) templates and the default behaviour of `getDefaultConfig`. + Sadly loading remote template files is no longer possible from the command line, but you can always create a simple + wrapper script if you need this functionality. Please let me know if this is a feature you absolutely need. + +1.1.1 - January 20, 2015 +- Fixed default behaviour of calling `getDefaultConfig` with no arguments, + which should always use the default templates + +1.1.0 - January 14, 2015 +- Now using raml-parser's FileReader which makes it a lot easier to load custom templates + in other folders or even as remote urls (#96) + +1.0.6 - January 14, 2015 +- Bugfix: use passed in template parameter when checking paths (#98) + +1.0.5 - December 3, 2014 +- Configured the html minifier to keep the quotes around html attributes (#93) + +1.0.4 - September 25, 2014 +- Updated readme and raml2obj version + +1.0.3 - September 12, 2014 +- Fixed method :hover effect, which was broken after #63 + +1.0.2 - September 12, 2014 +- Improved detection of empty resources + +1.0.1 - September 10, 2014 +- Solved problem with indentation of code examples (#66) +- Added `--version` command line option (#75) + +1.0.0 - September 10, 2014 +- **Finalized API, replaced `parse`/`parseWithConfig` with a single `render` method** +- Added a way for users to specify their own output processing via a `processOutput` function in the config object + +0.32.0 - September 9, 2014 +- Support for custom templates via command line parameters (#72) + +0.31.2 - September 6, 2014 +- Support enums for headers and URI parameters (#59) +- Rendering URI parameter examples (#57) +- Greatly simplified `resource.handlebars` by moving all the common code into a separate partial + +0.31.1 - August 21, 2014 +- Fixed HTML validity (#61) +- Fixed rendering of links within Markdown content (#63) + +0.31.0 - August 21, 2014 +- Improved rendering of tables within Markdown content + +0.30.0 - July 16, 2014 +- Adding `-s` command line parameter to use https links in the generated html file (it uses http by default) +- Deprecated the `parse` function, use `parseWithConfig` instead (in combination with the `getDefaultConfig` function) +- Bugfix: fixed html escaping for XML/HTML content (#53) + +0.29.0 - July 16, 2014 +- Moved code highlighting to the client to generate smaller HTML output +- Use a HTML minifier to generate MUCH smaller output +- Don't html-escape string in `
` blocks
+- The GitHub example used to be 3.2 MB, after these changes it's down to 1.2 MB
+
+0.28.0 - July 14, 2014
+- Render descriptions for nested resources
+- Made the method badges clickable directly from the collapsed panel
+
+0.27.0 - July 10, 2014
+- Added a new public function `getDefaultConfig`
+
 0.26.0 - July 10, 2014
 - Render required and description of URI Parameters
 - Made the output of URI params, form params, request body and response body consistent with each other
@@ -25,7 +363,7 @@
 - Added headers to request and response information
 
 0.21.0 - June 12, 2014
-- Split all the raml parsing logic into its own raml2obj project
+- Split all the raml parsing logic into its own [raml2obj project](https://github.com/kevinrenskers/raml2obj)
 
 0.20.0 - June 4, 2014
 - Fixed html output
@@ -53,7 +391,7 @@
 
 0.15.0 - May 12, 2014
 - Show padlock for secured methods (#14)
-- Bugfix: Handle resource urls with periods (#15)
+- Bugfix: handle resource urls with periods (#15)
 
 0.14.0 - May 6, 2014
 - Better schema handling (#12)
@@ -68,16 +406,16 @@
 - Render the description of query params with Markdown
 
 0.10.0 - April 8, 2014
-- New parseWithConfig method allowing you to override the templates (#5)
+- New `parseWithConfig` method allowing you to override the templates (#5)
 
 0.9.0 - April 8, 2014
-- Allow raml2html to be used pragmatically from another module
+- Allow raml2html to be used from another module
 
 0.8.2 - April 7, 2014
 - Showing all uri parameters, also those from parents
 
 0.8.1 - April 7, 2014
-- Code cleanup, added allUriParameters property to every resource
+- Code cleanup, added `allUriParameters` property to every resource
 
 0.8.0 - April 5, 2014
 - Improved rendering of query params: show required, enum and example
diff --git a/examples/custom-template-test/another/subtemplate.nunjucks b/examples/custom-template-test/another/subtemplate.nunjucks
new file mode 100644
index 00000000..223b7836
--- /dev/null
+++ b/examples/custom-template-test/another/subtemplate.nunjucks
@@ -0,0 +1 @@
+B
diff --git a/examples/custom-template-test/template.nunjucks b/examples/custom-template-test/template.nunjucks
new file mode 100644
index 00000000..87160e5a
--- /dev/null
+++ b/examples/custom-template-test/template.nunjucks
@@ -0,0 +1 @@
+A{% include "./another/subtemplate.nunjucks" %}
diff --git a/examples/example.html b/examples/example.html
deleted file mode 100644
index 1e2ddac3..00000000
--- a/examples/example.html
+++ /dev/null
@@ -1,2954 +0,0 @@
-
-
-
-    Codestin Search App
-    
-    
-    
-
-    
-
-    
-
-
-
-    
-
-
- - - -
-
-

ACCOUNTS

-
- -
- -
-

This is the top level description for /account.

-
    -
  • One
  • -
  • Two
  • -
  • Three
  • -
- -
- - -
-
- - - - -
- -
- -
- - -
- - - - - - -
- - - - -
- - - - - - - - - - -
- - - - -
- - - - -
- -
- -
- - - - -
- - - - -
- -
- -
- - - - -
- - - - - - - - -
- - - - - -
-
-
- -
-
-

/conversations

-
- -
- -
-

This is the top level description for /conversations.

- -
- - -
-
- - - - - - -
- -
- -
- - -
- - - - - - - - -
- - -
- - - - - - -
- -
- -
- - -
- - - - - - - - -
- - - - - - - - - -
-
-
- -
-
-

/users

-
- -
- - -
-
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - - - - -
-
-
- -
-
-

/groups

-
- -
- - -
-
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - -
- - - - -
- -
- -
- - -
- - - - - - -
- - - - - - - - - -
-
-
- -
- -
- -
-
-
- - diff --git a/examples/example.png b/examples/example.png deleted file mode 100644 index 687e136f..00000000 Binary files a/examples/example.png and /dev/null differ diff --git a/examples/example.raml b/examples/example.raml deleted file mode 100644 index 14776261..00000000 --- a/examples/example.raml +++ /dev/null @@ -1,269 +0,0 @@ -#%RAML 0.8 -title: Example -version: 1 -baseUri: http://example.com/{version} -documentation: - - title: Welcome - content: | - Welcome to the Example Documentation. The Example API allows you - to do stuff. See also [example.com](https://www.example.com). - - ```javascript - var raml2html = require('raml2html'); - - // Using the default templates: - // source can either be a filename, file contents (string) or parsed RAML object - raml2html.parse(source, onSuccess, onError); - - // Using your own templates: - // - config should be an object with at least an `template` property - // - config can also include `helpers` and `partials` - // - the config object will be accessible from your handlebars templates - raml2html.parseWithConfig(source, config, onSuccess, onError); - ``` - - title: Chapter two - content: More content here. Including **bold** text! - -securitySchemes: - - oauth_1_0: - description: OAuth 1.0 continues to be supported for all API requests, but OAuth 2.0 is now preferred. - type: OAuth 1.0 - settings: - requestTokenUri: https://api.dropbox.com/1/oauth/request_token - authorizationUri: https://www.dropbox.com/1/oauth/authorize - tokenCredentialsUri: https://api.dropbox.com/1/oauth/access_token - -traits: - - paged: - queryParameters: - page_size: - description: The number of items per page - type: number - page: - description: The page to return - type: number - -/account: - displayName: ACCOUNTS - - description: | - This is the top level description for /account. - * One - * Two - * Three - - post: - description: | - Creates a new account. Some **bold** text here. More text. Need to fill the line, so make it longer still. Hooray! - Line two - - Paragraph two - body: - application/json: - example: | - { - "email": "john@example.com", - "password": "super_secret", - "name": "John Doe" - } - responses: - 200: - description: Account was created and user is now logged in - - /find: - get: - description: find an account - queryParameters: - name: - description: name on account - required: true - example: Naruto Uzumaki - gender: - enum: ["male", "female"] - number: - type: integer - /{id}: - uriParameters: - id: - type: string - description: account identifier - get: - headers: - Authorization: - type: string - description: Basic authentication header - example: | - Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ== - - put: - description: Update the account - body: - application/x-www-form-urlencoded: - formParameters: - name: - description: name on account - type: string - example: Naruto Uzumaki - gender: - enum: ["male", "female"] - - delete: - description: Delete the account - - /login: - post: - description: Login with email and password - body: - application/json: - example: | - { - "email": "john@example.com", - "password": "super_secret" - } - responses: - 200: - description: Login was correct - 400: - description: Login was incorrect, please try again - 401: - description: Not authorized - headers: - WWW-Authenticate: - type: string - description: user was not authorized - example: | - WWW-Authenticate: Basic realm="raml2html" - - /forgot: - post: - description: Sends an email to the user with a link to set a new password - body: - application/json: - example: | - { - "email": "john@example.com" - } - - /session: - get: - description: Gets the sessions - - delete: - description: Deletes the session, logging out the user - - -/conversations: - description: This is the top level description for /conversations. - securedBy: [oauth_1_0] - - get: - description: Get a list of conversation for the current user - - post: - description: Create a new conversions. The currently logged in user doesn't need to be supplied in the members list, it's implied. - body: - application/json: - example: | - { - "content": "My message!", - "members": [1, 2, 3] - } - responses: - 200: - description: A conversation with these members already existed, the message was added to that one - 201: - description: The conversation was created and the message added to it - - /{convId}: - get: - description: Get a single conversation including its messages - - put: - description: Update a conversation (change members) - - /messages: - get: - is: [ paged ] - description: Get the messages for the conversation - - post: - description: Add a new message to a conversation - - /{messageId}: - put: - description: Update the message - - delete: - description: Delete the message - - -/users: - get: - is: [ paged ] - description: Get a list of all users - - post: - description: Creates a new user - body: - application/json: - example: | - { - "email": "john@example.com", - "name": "John Doe", - } - - /{userId}: - get: - description: Get the details of a user including a list of groups he belongs to - - put: - description: Update a user - - delete: - description: Deletes a user - - -/groups: - get: - description: Get a list of all the groups - - post: - description: Create a new group - body: - application/json: - example: | - { - "name": "Cool people", - "members": [1, 2, 3] - } - - /{groupId}: - get: - description: Get the details of a group, including the member list - - put: - description: Update the group, **optionally** supplying the new list of members (overwrites current list) - body: - application/json: - example: | - { - "name": "Cool people", - "members": [1, 2, 3] - } - - delete: - description: Removes the group - - /users: - post: - description: Adds a user to a group - body: - application/json: - example: | - { - "user_id": 4, - } - - /{userId}: - delete: - description: Removes a user from a group diff --git a/examples/github.html b/examples/github.html deleted file mode 100644 index 55bdf15a..00000000 --- a/examples/github.html +++ /dev/null @@ -1,49915 +0,0 @@ - - - - Codestin Search App - - - - - - - - - - -
-
-
- - - -
-
- -
- -
- - -
-
- - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - - -
-
-
- -
-
-

/events

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/feeds

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/meta

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/rate_limit

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/issues

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/notifications

-
- -
- - -
-
- - - - - - - - -
- - -
- - - - - - - - -
- - -
- - - - - - - - - - -
- - - - - - - -
-
-
- -
-
-

/gists

-
- -
- - -
-
- - - - - - -
- -
- -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - - - - - -
- - -
- - - - - - - - - - -
- - - - -
- - - - -
- -
- -
- - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - - - - - - - - -
-
-
- -
-
-

/orgs/{orgId}

-
- -
- - -
-
- - - - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - - - -
- - - - - - -
- -
- -
- - - - - -
-
-
- -
-
-

/teams/{teamsId}

-
- -
- - -
-
- - - - - - - - - - -
- - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - - -
-
-
- -
-
-

/repositories

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
-
-

/repos/{ownerId}/{repoId}

-
- -
- - -
-
- - - - - - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- -
-
-
- -
-
-
- - -
- - -
- - - - -
- -
- -
- - -
- - - - - - -
- - - - - - -
- - - - -
- -
- -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - - - -
- - - - -
- -
- -
- - -
- - - - - - -
- - - - - - -
- - - - -
- -
- -
- - -
- - - - - - -
- - - - - - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - - - -
- - -
- - - - - - -
- -
- -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- -
- - - - - -
- - -
- - - - - - -
- - - - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - - - -
- - - - - - - - -
- - - - -
- - - - - - - - - - -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - -
- - - - - - -
- - - - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - - - -
- - - - -
- -
-
-
- - - get -
-

List comments on a pull request.

- -
-
-
- - - post -
-

Create a comment.

-

TODO Alternative input ( http://developer.github.com/v3/pulls/comments/ )

-

description: | - Alternative Input. - Instead of passing commit_id, path, and position you can reply to an - existing Pull Request Comment like this:

-
    body
-       Required string
-    in_reply_to
-       Required number - Comment id to reply to.
-
-
-
- - -
-
-
- - - - -
- -
- -
- - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- - -
- - - - - - -
- - -
- - - - - - -
- -
- -
- - - - - - - - -
- - - - - - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - -
- - - - -
- -
- -
- - - - - - - - -
- - - - -
- -
- -
- - - - -
- - - - - - -
- -
- -
- - - - -
- -
-
-
- -
-
-
- - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - - - - -
-
-
- -
-
-

/user

-
- -
- - -
-
- - - - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - -
- - - - - - -
- - - - - - -
- - - - - - -
- - - - -
- - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - - - -
- - - - - - -
- -
- - - -
- - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- -
- -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- - -
- - - - - - - - - - -
- - - - - - -
- - - - - - -
- - - - -
- - - - - - -
- -
- -
- - - - - -
-
-
- -
-
-

/users

-
- -
- - -
-
- - - - - - -
- - -
- - - - - - -
- - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - -
- - - - - - -
- - - - - - - -
-
-
- -
-
-

/gitignore/templates

-
- -
- - -
-
- - - - - - -
- - -
- - - - - - -
- - - - - -
-
-
- -
-
-

/markdown

-
- -
- - -
-
- -
-
- -
-
- - -
- -
- -
- - -
- -
-
- -
-
- - -
- -
- -
- - - - - -
-
-
- -
-
-

/networks/{ownerId}/{repoId}/events

-
- -
- - -
-
- - - - - - -
- - - -
-
-
- -
- - -
-
- - diff --git a/examples/github.raml b/examples/github.raml deleted file mode 100644 index e762cc41..00000000 --- a/examples/github.raml +++ /dev/null @@ -1,21650 +0,0 @@ -#%RAML 0.8 ---- -title: GitHub API -version: v3 -baseUri: https://api.github.com/ -securitySchemes: - - oauth_2_0: - description: | - OAuth2 is a protocol that lets external apps request authorization to private - details in a user's GitHub account without getting their password. This is - preferred over Basic Authentication because tokens can be limited to specific - types of data, and can be revoked by users at any time. - type: OAuth 2.0 - describedBy: - headers: - Authorization: - description: | - Used to send a valid OAuth 2 access token. Do not use together with - the "access_token" query string parameter. - type: string - queryParameters: - access_token: - description: | - Used to send a valid OAuth 2 access token. Do not use together with - the "Authorization" header - type: string - responses: - 404: - description: Unauthorized - settings: - authorizationUri: https://github.com/login/oauth/authorize - accessTokenUri: https://github.com/login/oauth/access_token - authorizationGrants: [ code ] - scopes: - - "user" - - "user:email" - - "user:follow" - - "public_repo" - - "repo" - - "repo:status" - - "delete_repo" - - "notifications" - - "gist" -securedBy: [ oauth_2_0 ] -mediaType: application/json -resourceTypes: - - base: - get?: &common - headers: - X-GitHub-Media-Type: - description: | - You can check the current version of media type in responses. - type: string - Accept: - description: Is used to set specified media type. - type: string - X-RateLimit-Limit: - type: integer - X-RateLimit-Remaining: - type: integer - X-RateLimit-Reset: - type: integer - X-GitHub-Request-Id: - type: integer - responses: - 403: - description: | - API rate limit exceeded. See http://developer.github.com/v3/#rate-limiting - for details. - post?: *common - patch?: *common - put?: *common - delete?: *common - - item: - type: base - get?: - post?: - patch?: - put?: - delete?: - responses: - 204: - description: Item removed. - - collection: - type: base - get?: - post?: -traits: - - historical: - queryParameters: - since: - description: | - Timestamp in ISO 8601 format YYYY-MM-DDTHH:MM:SSZ. - Only gists updated at or after this time are returned. - type: string - - filterable: - queryParameters: - filter: - description: | - Issues assigned to you / created by you / mentioning you / you're - subscribed to updates for / All issues the authenticated user can see - enum: - - assigned - - created - - mentioned - - subscribed - - all - default: all - required: true - state: - enum: - - open - - closed - default: open - required: true - labels: - description: String list of comma separated Label names. Example - bug,ui,@high. - type: string - required: true - sort: - enum: - - created - - updated - - comments - default: created - required: true - direction: - enum: - - asc - - desc - default: desc - required: true - since: - description: | - Optional string of a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. - Only issues updated at or after this time are returned. - type: string -# Search -/search: - /repositories: - type: collection - get: - description: Search repositories. - queryParameters: - q: - description: | - The search terms. This can be any combination of the supported repository - search parameters: - 'Search In' Qualifies which fields are searched. With this qualifier you - can restrict the search to just the repository name, description, readme, - or any combination of these. - 'Size' Finds repositories that match a certain size (in kilobytes). - 'Forks' Filters repositories based on the number of forks, and/or whether - forked repositories should be included in the results at all. - 'Created' and 'Last Updated' Filters repositories based on times of - creation, or when they were last updated. - 'Users or Repositories' Limits searches to a specific user or repository. - 'Languages' Searches repositories based on the language they're written in. - 'Stars' Searches repositories based on the number of stars. - type: string - required: true - sort: - description: If not provided, results are sorted by best match. - enum: - - stars - - forks - - updated - order: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "total_count": { - "type": "integer" - }, - "items": [ - { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "received_events_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "private": { - "type": "boolean" - }, - "html_url": { - "type": "string" - }, - "description": { - "type": "string" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "homepage": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "language": { - "type": "string" - }, - "forks_count": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "forks": { - "type": "integer" - }, - "open_issues": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "default_branch": { - "type": "string" - }, - "score": { - "type": "number" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "total_count": 40, - "items": [ - { - "id": 3081286, - "name": "Tetris", - "full_name": "dtrupenn/Tetris", - "owner": { - "login": "dtrupenn", - "id": 872147, - "avatar_url": "https://secure.gravatar.com/avatar/e7956084e75f239de85d3a31bc172ace?d=https://a248.e.akamai.net/assets.github.com/images/gravatars/gravatar-user-420.png", - "gravatar_id": "e7956084e75f239de85d3a31bc172ace", - "url": "https://api.github.com/users/dtrupenn", - "received_events_url": "https://api.github.com/users/dtrupenn/received_events", - "type": "User" - }, - "private": false, - "html_url": "https://github.com/dtrupenn/Tetris", - "description": "A C implementation of Tetris using Pennsim through LC4", - "fork": false, - "url": "https://api.github.com/repos/dtrupenn/Tetris", - "created_at": "2012-01-01T00:31:50Z", - "updated_at": "2013-01-05T17:58:47Z", - "pushed_at": "2012-01-01T00:37:02Z", - "homepage": "", - "size": 524, - "watchers_count": 1, - "language": "Assembly", - "forks_count": 0, - "open_issues_count": 0, - "forks": 0, - "open_issues": 0, - "watchers": 1, - "master_branch": "master", - "default_branch": "master", - "score": 10.309712 - } - ] - } - /code: - type: collection - get: - description: Search code. - queryParameters: - q: - description: | - The search terms. This can be any combination of the supported code - search parameters: - 'Search In' Qualifies which fields are searched. With this qualifier - you can restrict the search to just the file contents, the file path, - or both. - 'Languages' Searches code based on the language it's written in. - 'Forks' Filters repositories based on the number of forks, and/or - whether code from forked repositories should be included in the results - at all. - 'Size' Finds files that match a certain size (in bytes). - 'Path' Specifies the path that the resulting file must be at. - 'Extension' Matches files with a certain extension. - 'Users' or 'Repositories' Limits searches to a specific user or repository. - type: string - required: true - sort: - description: | - Can only be 'indexed', which indicates how recently a file has been indexed - by the GitHub search infrastructure. If not provided, results are sorted - by best match. - enum: - - indexed - order: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "total_count": { - "type": "integer" - }, - "items": [ - { - "properties": { - "name": { - "type": "string" - }, - "path": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "repository": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "followers_url": { - "type": "string" - }, - "following_url": { - "type": "string" - }, - "gists_url": { - "type": "string" - }, - "starred_url": { - "type": "string" - }, - "subscriptions_url": { - "type": "string" - }, - "organizations_url": { - "type": "string" - }, - "repos_url": { - "type": "string" - }, - "events_url": { - "type": "string" - }, - "received_events_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "private": { - "type": "boolean" - }, - "html_url": { - "type": "string" - }, - "description": { - "type": "string" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "forks_url": { - "type": "string" - }, - "keys_url": { - "type": "string" - }, - "collaborators_url": { - "type": "string" - }, - "teams_url": { - "type": "string" - }, - "hooks_url": { - "type": "string" - }, - "issue_events_url": { - "type": "string" - }, - "events_url": { - "type": "string" - }, - "assignees_url": { - "type": "string" - }, - "branches_url": { - "type": "string" - }, - "tags_url": { - "type": "string" - }, - "blobs_url": { - "type": "string" - }, - "git_tags_url": { - "type": "string" - }, - "git_refs_url": { - "type": "string" - }, - "trees_url": { - "type": "string" - }, - "statuses_url": { - "type": "string" - }, - "languages_url": { - "type": "string" - }, - "stargazers_url": { - "type": "string" - }, - "contributors_url": { - "type": "string" - }, - "subscribers_url": { - "type": "string" - }, - "subscription_url": { - "type": "string" - }, - "commits_url": { - "type": "string" - }, - "git_commits_url": { - "type": "string" - }, - "comments_url": { - "type": "string" - }, - "issue_comment_url": { - "type": "string" - }, - "contents_url": { - "type": "string" - }, - "compare_url": { - "type": "string" - }, - "merges_url": { - "type": "string" - }, - "archive_url": { - "type": "string" - }, - "downloads_url": { - "type": "string" - }, - "issues_url": { - "type": "string" - }, - "pulls_url": { - "type": "string" - }, - "milestones_url": { - "type": "string" - }, - "notifications_url": { - "type": "string" - }, - "labels_url": { - "type": "string" - } - }, - "type": "object" - }, - "score": { - "type": "number" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "total_count": 104, - "items": [ - { - "name": "github-issue-importer.gemspec", - "path": "github-issue-importer.gemspec", - "sha": "394508202991504d8a0771ae027454facaaa045a", - "url": "https://api.github.com/repositories/1586630/contents/github-issue-importer.gemspec?ref=aa22a4be513163c73531e96bd99f4b49d6ded8a6", - "git_url": "https://api.github.com/repositories/1586630/git/blobs/394508202991504d8a0771ae027454facaaa045a", - "html_url": "https://github.com/johnf/github-issue-importer/blob/aa22a4be513163c73531e96bd99f4b49d6ded8a6/github-issue-importer.gemspec", - "repository": { - "id": 1586630, - "name": "github-issue-importer", - "full_name": "johnf/github-issue-importer", - "owner": { - "login": "johnf", - "id": 42590, - "avatar_url": "https://secure.gravatar.com/avatar/ab4d879ba3233a270aa14f447c795505?d=https://a248.e.akamai.net/assets.github.com/images/gravatars/gravatar-user-420.png", - "gravatar_id": "ab4d879ba3233a270aa14f447c795505", - "url": "https://api.github.com/users/johnf", - "html_url": "https://github.com/johnf", - "followers_url": "https://api.github.com/users/johnf/followers", - "following_url": "https://api.github.com/users/johnf/following{/other_user}", - "gists_url": "https://api.github.com/users/johnf/gists{/gist_id}", - "starred_url": "https://api.github.com/users/johnf/starred{/owner}{/repo}", - "subscriptions_url": "https://api.github.com/users/johnf/subscriptions", - "organizations_url": "https://api.github.com/users/johnf/orgs", - "repos_url": "https://api.github.com/users/johnf/repos", - "events_url": "https://api.github.com/users/johnf/events{/privacy}", - "received_events_url": "https://api.github.com/users/johnf/received_events", - "type": "User" - }, - "private": false, - "html_url": "https://github.com/johnf/github-issue-importer", - "description": "Import Issues from Launchpad (for now) into github", - "fork": false, - "url": "https://api.github.com/repos/johnf/github-issue-importer", - "forks_url": "https://api.github.com/repos/johnf/github-issue-importer/forks", - "keys_url": "https://api.github.com/repos/johnf/github-issue-importer/keys{/key_id}", - "collaborators_url": "https://api.github.com/repos/johnf/github-issue-importer/collaborators{/collaborator}", - "teams_url": "https://api.github.com/repos/johnf/github-issue-importer/teams", - "hooks_url": "https://api.github.com/repos/johnf/github-issue-importer/hooks", - "issue_events_url": "https://api.github.com/repos/johnf/github-issue-importer/issues/events{/number}", - "events_url": "https://api.github.com/repos/johnf/github-issue-importer/events", - "assignees_url": "https://api.github.com/repos/johnf/github-issue-importer/assignees{/user}", - "branches_url": "https://api.github.com/repos/johnf/github-issue-importer/branches{/branch}", - "tags_url": "https://api.github.com/repos/johnf/github-issue-importer/tags", - "blobs_url": "https://api.github.com/repos/johnf/github-issue-importer/git/blobs{/sha}", - "git_tags_url": "https://api.github.com/repos/johnf/github-issue-importer/git/tags{/sha}", - "git_refs_url": "https://api.github.com/repos/johnf/github-issue-importer/git/refs{/sha}", - "trees_url": "https://api.github.com/repos/johnf/github-issue-importer/git/trees{/sha}", - "statuses_url": "https://api.github.com/repos/johnf/github-issue-importer/statuses/{sha}", - "languages_url": "https://api.github.com/repos/johnf/github-issue-importer/languages", - "stargazers_url": "https://api.github.com/repos/johnf/github-issue-importer/stargazers", - "contributors_url": "https://api.github.com/repos/johnf/github-issue-importer/contributors", - "subscribers_url": "https://api.github.com/repos/johnf/github-issue-importer/subscribers", - "subscription_url": "https://api.github.com/repos/johnf/github-issue-importer/subscription", - "commits_url": "https://api.github.com/repos/johnf/github-issue-importer/commits{/sha}", - "git_commits_url": "https://api.github.com/repos/johnf/github-issue-importer/git/commits{/sha}", - "comments_url": "https://api.github.com/repos/johnf/github-issue-importer/comments{/number}", - "issue_comment_url": "https://api.github.com/repos/johnf/github-issue-importer/issues/comments/{number}", - "contents_url": "https://api.github.com/repos/johnf/github-issue-importer/contents/{ path}", - "compare_url": "https://api.github.com/repos/johnf/github-issue-importer/compare/{base}...{head}", - "merges_url": "https://api.github.com/repos/johnf/github-issue-importer/merges", - "archive_url": "https://api.github.com/repos/johnf/github-issue-importer/{archive_format}{/ref}", - "downloads_url": "https://api.github.com/repos/johnf/github-issue-importer/downloads", - "issues_url": "https://api.github.com/repos/johnf/github-issue-importer/issues{/number}", - "pulls_url": "https://api.github.com/repos/johnf/github-issue-importer/pulls{/number}", - "milestones_url": "https://api.github.com/repos/johnf/github-issue-importer/milestones{/number}", - "notifications_url": "https://api.github.com/repos/johnf/github-issue-importer/notifications{?since,all,participating}", - "labels_url": "https://api.github.com/repos/johnf/github-issue-importer/labels{/name}" - }, - "score": 0.96691436 - } - ] - } - /users: - type: collection - get: - description: Search users. - queryParameters: - q: - description: | - The search terms. This can be any combination of the supported user - search parameters: - 'Search In' Qualifies which fields are searched. With this qualifier you - can restrict the search to just the username, public email, full name, - location, or any combination of these. - 'Repository count' Filters users based on the number of repositories they - have. - 'Location' Filter users by the location indicated in their profile. - 'Language' Search for users that have repositories that match a certain - language. - 'Created' Filter users based on when they joined. - 'Followers' Filter users based on the number of followers they have. - type: string - required: true - sort: - description: If not provided, results are sorted by best match. - enum: - - followers - - repositories - - joined - order: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "total_count": { - "type": "integer" - }, - "items": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "followers_url": { - "type": "string" - }, - "subscriptions_url": { - "type": "string" - }, - "organizations_url": { - "type": "string" - }, - "repos_url": { - "type": "string" - }, - "received_events_url": { - "type": "string" - }, - "type": { - "type": "string" - }, - "score": { - "type": "number" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "total_count": 12, - "items": [ - { - "login": "mojombo", - "id": 1, - "avatar_url": "https://secure.gravatar.com/avatar/25c7c18223fb42a4c6ae1c8db6f50f9b?d=https://a248.e.akamai.net/assets.github.com/images/gravatars/gravatar-user-420.png", - "gravatar_id": "25c7c18223fb42a4c6ae1c8db6f50f9b", - "url": "https://api.github.com/users/mojombo", - "html_url": "https://github.com/mojombo", - "followers_url": "https://api.github.com/users/mojombo/followers", - "subscriptions_url": "https://api.github.com/users/mojombo/subscriptions", - "organizations_url": "https://api.github.com/users/mojombo/orgs", - "repos_url": "https://api.github.com/users/mojombo/repos", - "received_events_url": "https://api.github.com/users/mojombo/received_events", - "type": "User", - "score": 105.47857 - } - ] - } -# Events -/events: - type: collection - get: - description: List public events. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] -# Feeds -/feeds: - type: collection - get: - description: | - List Feeds. - GitHub provides several timeline resources in Atom format. The Feeds API - lists all the feeds available to the authenticating user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "timeline_url": { - "type": "string" - }, - "user_url": { - "type": "string" - }, - "current_user_public": { - "type": "string" - }, - "current_user_url": { - "type": "string" - }, - "current_user_actor_url": { - "type": "string" - }, - "current_user_organization_url": { - "type": "string" - }, - "_links": { - "properties": { - "timeline": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "user": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "current_user_public": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "current_user": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "current_user_actor": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "current_user_organization": { - "properties": { - "href": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - } - } - } - } - } - example: | - { - "timeline_url": "https://github.com/timeline", - "user_url": "https://github.com/{user}", - "current_user_public": "https://github.com/defunkt", - "current_user_url": "https://github.com/defunkt.private?token=abc123", - "current_user_actor_url": "https://github.com/defunkt.private.actor?token=abc123", - "current_user_organization_url": "https://github.com/organizations/{org}/defunkt.private.atom?token=abc123", - "_links": { - "timeline": { - "href": "https://github.com/timeline", - "type": "application/atom xml" - }, - "user": { - "href": "https://github.com/{user}", - "type": "application/atom xml" - }, - "current_user_public": { - "href": "https://github.com/defunkt", - "type": "application/atom xml" - }, - "current_user": { - "href": "https://github.com/defunkt.private?token=abc123", - "type": "application/atom xml" - }, - "current_user_actor": { - "href": "https://github.com/defunkt.private.actor?token=abc123", - "type": "application/atom xml" - }, - "current_user_organization": { - "href": "https://github.com/organizations/{org}/defunkt.private.atom?token=abc123", - "type": "application/atom xml" - } - } - } -# Meta -/meta: - type: collection - get: - description: This gives some information about GitHub.com, the service. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "hooks": [ - { - "description": "An Array of IP addresses in CIDR format specifying the addresses that incoming service hooks will originate from.", - "type": "string" - } - ], - "type": "array", - "git": [ - { - "description": "An Array of IP addresses in CIDR format specifying the Git servers at GitHub.", - "type": "string" - } - ] - } - } - example: | - { - "hooks": [ - "127.0.0.1/32" - ], - "git": [ - "127.0.0.1/32" - ] - } -# Rate limit -/rate_limit: - type: collection - get: - description: | - Get your current rate limit status - Note: Accessing this endpoint does not count against your rate limit. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "rate": { - "properties": { - "limit": { - "type": "integer" - }, - "remaining": { - "type": "integer" - }, - "reset": { - "type": "integer" - } - } - } - } - } - example: | - { - "rate": { - "limit": 5000, - "remaining": 4999, - "reset": 1372700873 - } - } -# Issues -/issues: - type: item - get: - is: [ filterable ] - description: | - List issues. - List all issues across all the authenticated user's visible repositories. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "issues": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - ] -# Other -/notifications: - type: collection - get: - description: | - List your notifications. - List all notifications for the current user, grouped by repository. - queryParameters: - all: - description: True to show notifications marked as read. - type: string - participating: - description: | - True to show only notifications in which the user is directly participating - or mentioned. - type: string - since: - description: | - Time filters out any notifications updated before the given time. The - time should be passed in as UTC in the ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. - Example: "2012-10-09T23:39:01Z". - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "id": { - "type": "integer" - }, - "repository": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - } - }, - "type": "object" - }, - "subject": { - "properties": { - "title": { - "type": "string" - }, - "url": { - "type": "string" - }, - "latest_comment_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "reason": { - "type": "string" - }, - "unread": { - "type": "boolean" - }, - "updated_at": { - "type": "string" - }, - "last_read_at": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "repository": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World" - }, - "subject": { - "title": "Greetings", - "url": "https://api.github.com/repos/pengwynn/octokit/issues/123", - "latest_comment_url": "https://api.github.com/repos/pengwynn/octokit/issues/comments/123", - "type": "Issue" - }, - "reason": "subscribed", - "unread": true, - "updated_at": "2012-09-25T07:54:41-07:00", - "last_read_at": "2012-09-25T07:54:41-07:00", - "url": "https://api.github.com/notifications/threads/1" - } - ] - put: - description: | - Mark as read. - Marking a notification as "read" removes it from the default view on GitHub.com. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "last_read_at": { - "description": "Describes the last point that notifications were checked. Anything updated since this time will not be updated. Default: Now.", - "type": "string" - } - } - } - responses: - 205: - description: Marked as read. - /threads/{id}: - uriParameters: - id: - description: Id of a thread. - type: integer - type: item - get: - description: View a single thread. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "id": { - "type": "integer" - }, - "repository": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - } - }, - "type": "object" - }, - "subject": { - "properties": { - "title": { - "type": "string" - }, - "url": { - "type": "string" - }, - "latest_comment_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "reason": { - "type": "string" - }, - "unread": { - "type": "boolean" - }, - "updated_at": { - "type": "string" - }, - "last_read_at": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "repository": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World" - }, - "subject": { - "title": "Greetings", - "url": "https://api.github.com/repos/pengwynn/octokit/issues/123", - "latest_comment_url": "https://api.github.com/repos/pengwynn/octokit/issues/comments/123", - "type": "Issue" - }, - "reason": "subscribed", - "unread": true, - "updated_at": "2012-09-25T07:54:41-07:00", - "last_read_at": "2012-09-25T07:54:41-07:00", - "url": "https://api.github.com/notifications/threads/1" - } - ] - patch: - responses: - 205: - description: Thread marked as read. - /subscription: - type: item - get: - description: Get a Thread Subscription. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed":{ - "type": "boolean" - }, - "ignored": { - "type": "boolean" - }, - "reason": { - "type": "boolean" - }, - "created_at": { - "type": "string" - }, - "url": { - "type": "string" - }, - "thread_url": { - "type": "string" - } - } - } - example: | - { - "subscribed": true, - "ignored": false, - "reason": null, - "created_at": "2012-10-06T21:34:12Z", - "url": "https://api.github.com/notifications/threads/1/subscription", - "thread_url": "https://api.github.com/notifications/threads/1" - } - put: - description: | - Set a Thread Subscription. - This lets you subscribe to a thread, or ignore it. Subscribing to a thread - is unnecessary if the user is already subscribed to the repository. Ignoring - a thread will mute all future notifications (until you comment or get @mentioned). - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed": { - "description": "Determines if notifications should be received from this thread.", - "type": "boolean" - }, - "ignored": { - "description": "Determines if all notifications should be blocked from this thread.", - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed":{ - "type": "boolean" - }, - "ignored": { - "type": "boolean" - }, - "reason": { - "type": "boolean" - }, - "created_at": { - "type": "string" - }, - "url": { - "type": "string" - }, - "thread_url": { - "type": "string" - } - } - } - example: | - { - "subscribed": true, - "ignored": false, - "reason": null, - "created_at": "2012-10-06T21:34:12Z", - "url": "https://api.github.com/notifications/threads/1/subscription", - "thread_url": "https://api.github.com/notifications/threads/1" - } - delete: - description: Delete a Thread Subscription. -/gists: - securedBy: [ null, oauth_2_0 ] - type: collection - get: - is: [ historical ] - description: | - List the authenticated user's gists or if called anonymously, this will - return all public gists. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "gists": [ - { - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "type": "string" - } - } - } - ] - } - example: | - [ - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z" - } - ] - post: - description: Create a gist. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "files": { - "description": "Files that make up this gist. The key of which should be a required string filename and the value another required hash with parameter 'content'.", - "type": "string" - }, - "content": { - "description": "File contents.", - "type": "string" - } - }, - "required": [ "public", "files", "content" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "forks": [ - { - "properties": { - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "history": [ - { - "properties": { - "url": { - "type": "string" - }, - "version": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "change_status": { - "properties": { - "deletions": { - "type": "integer" - }, - "additions": { - "type": "integer" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - }, - "committed_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "type": "object" - } - } - ] - } - } - example: | - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z", - "forks": [ - { - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "url": "https://api.github.com/gists/d39d0d37fb24f12e2045", - "created_at": "2011-04-14T16:00:49Z" - } - ], - "history": [ - { - "url": "https://api.github.com/gists/3a8bdc16d2e39d809469", - "version": "57a7f021a713b1c5a6a199b54cc514735d2d462f", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "change_status": { - "deletions": 0, - "additions": 180, - "total": 180 - }, - "committed_at": "2010-04-14T02:15:15Z" - } - ] - } - # Public - /public: - securedBy: [ null, oauth_2_0 ] - type: collection - get: - is: [ historical ] - description: List all public gists. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "gists": [ - { - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "type": "string" - } - } - } - ] - } - example: | - [ - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z" - } - ] - # Starred - /starred: - securedBy: [ null, oauth_2_0 ] - type: collection - get: - is: [ historical ] - description: List the authenticated user's starred gists. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "gists": [ - { - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "type": "string" - } - } - } - ] - } - example: | - [ - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z" - } - ] - # ID - /{id}: - uriParameters: - id: - description: Id of a thread. - type: integer - type: item - get: - description: Get a single gist. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "forks": [ - { - "properties": { - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "history": [ - { - "properties": { - "url": { - "type": "string" - }, - "version": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "change_status": { - "properties": { - "deletions": { - "type": "integer" - }, - "additions": { - "type": "integer" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - }, - "committed_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "type": "object" - } - } - ] - } - } - example: | - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z", - "forks": [ - { - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "url": "https://api.github.com/gists/d39d0d37fb24f12e2045", - "created_at": "2011-04-14T16:00:49Z" - } - ], - "history": [ - { - "url": "https://api.github.com/gists/3a8bdc16d2e39d809469", - "version": "57a7f021a713b1c5a6a199b54cc514735d2d462f", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "change_status": { - "deletions": 0, - "additions": 180, - "total": 180 - }, - "committed_at": "2010-04-14T02:15:15Z" - } - ] - } - patch: - description: Edit a gist. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "description": { - "type": "string" - }, - "files": { - "properties": { - "file1.txt": { - "properties": { - "content": { - "type": "string" - } - }, - "type": "object" - }, - "old_name.txt": { - "properties": { - "filename": { - "type": "string" - }, - "content": { - "type": "string" - } - }, - "type": "object" - }, - "new_file.txt": { - "properties": { - "content": { - "type": "string" - } - }, - "type": "object" - }, - "delete_this_file.txt": { - "type": "string" - } - } - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "forks": [ - { - "properties": { - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "url": { - "type": "string" - }, - "created_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "history": [ - { - "properties": { - "url": { - "type": "string" - }, - "version": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "change_status": { - "properties": { - "deletions": { - "type": "integer" - }, - "additions": { - "type": "integer" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - }, - "committed_at": { - "description": "Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.", - "type": "string" - }, - "type": "object" - } - } - ] - } - } - example: | - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z", - "forks": [ - { - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "url": "https://api.github.com/gists/d39d0d37fb24f12e2045", - "created_at": "2011-04-14T16:00:49Z" - } - ], - "history": [ - { - "url": "https://api.github.com/gists/3a8bdc16d2e39d809469", - "version": "57a7f021a713b1c5a6a199b54cc514735d2d462f", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "change_status": { - "deletions": 0, - "additions": 180, - "total": 180 - }, - "committed_at": "2010-04-14T02:15:15Z" - } - ] - } - delete: - description: Delete a gist. - # Star - /star: - type: base - put: - description: Star a gist. - responses: - 204: - description: Starred. - delete: - description: Unstar a gist. - responses: - 204: - description: Item removed. - get: - description: Check if a gist is starred. - responses: - 204: - description: Exists. - 404: - description: Not exists. - # Forks - /forks: - type: base - post: - description: Fork a gist. - responses: - 204: - description: Exists. - 404: - description: Not exists. - /comments: - type: collection - get: - description: List comments on a gist. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "comments": [ - { - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601.", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "url": "https://api.github.com/gists/ae709e9cf889e485e65f/comments/1", - "body": "Just commenting for the sake of commenting", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-18T23:23:56Z" - } - ] - post: - description: Create a comment - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - } - }, - "required": [ "body" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601.", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/gists/83ba86d111d39709da8c/comments/1", - "body": "Just commenting for the sake of commenting", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-18T23:23:56Z" - } - /{commentId}: - type: item - uriParameters: - commentId: - description: Id of the comment. - type: integer - get: - description: Get a single comment. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601.", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/gists/83ba86d111d39709da8c/comments/1", - "body": "Just commenting for the sake of commenting", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-18T23:23:56Z" - } - patch: - description: Edit a comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601.", - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601.", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/gists/83ba86d111d39709da8c/comments/1", - "body": "Just commenting for the sake of commenting", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-18T23:23:56Z" - } - delete: - description: Delete a comment. -/orgs/{orgId}: - uriParameters: - orgId: - description: Id of organisation. - type: integer - type: item - get: - description: Get an Organization. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "avatar_url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "company": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "location": { - "type": "string" - }, - "email": { - "type": "string" - }, - "public_repos": { - "type": "integer" - }, - "public_gists": { - "type": "integer" - }, - "followers": { - "type": "integer" - }, - "following": { - "type": "integer" - }, - "html_url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "type": { - "type": "string" - } - } - } - example: | - { - "login": "github", - "id": 1, - "url": "https://api.github.com/orgs/github", - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "name": "github", - "company": "GitHub", - "blog": "https://github.com/blog", - "location": "San Francisco", - "email": "octocat@github.com", - "public_repos": 2, - "public_gists": 1, - "followers": 20, - "following": 0, - "html_url": "https://github.com/octocat", - "created_at": "2008-01-14T04:33:35Z", - "type": "Organization" - } - patch: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "billing_email": { - "description": "Billing email address. This address is not publicized.", - "type": "string" - }, - "company": { - "type": "string" - }, - "email": { - "description": "Publicly visible email address.", - "type": "string" - }, - "location": { - "type": "string" - }, - "name": { - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "avatar_url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "company": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "location": { - "type": "string" - }, - "email": { - "type": "string" - }, - "public_repos": { - "type": "integer" - }, - "public_gists": { - "type": "integer" - }, - "followers": { - "type": "integer" - }, - "following": { - "type": "integer" - }, - "html_url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "type": { - "type": "string" - } - } - } - example: | - { - "login": "github", - "id": 1, - "url": "https://api.github.com/orgs/github", - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "name": "github", - "company": "GitHub", - "blog": "https://github.com/blog", - "location": "San Francisco", - "email": "octocat@github.com", - "public_repos": 2, - "public_gists": 1, - "followers": 20, - "following": 0, - "html_url": "https://github.com/octocat", - "created_at": "2008-01-14T04:33:35Z", - "type": "Organization" - } - description: Edit an Organization. - # Events - /events: - type: collection - get: - description: List public events for an organization. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - # Issues - /issues: - type: collection - get: - is: [ filterable ] - description: | - List issues. - List all issues for a given organization for the authenticated user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "issues": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - ] - /members: - type: collection - get: - description: | - Members list. - List all users who are members of an organization. A member is a user that - belongs to at least 1 team in the organization. If the authenticated user - is also an owner of this organization then both concealed and public members - will be returned. If the requester is not an owner of the organization the - query will be redirected to the public members list. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - 302: - description: Response if requester is not an organization member. - /{userId}: - type: item - uriParameters: - userId: - description: Id of the user. - type: integer - delete: - description: | - Remove a member. - Removing a user from this list will remove them from all teams and they - will no longer have any access to the organization's repositories. - /public_members: - type: collection - get: - description: | - Public members list. - Members of an organization can choose to have their membership publicized - or not. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{userId}: - uriParameters: - userId: - description: Id of the user. - type: integer - type: base - get: - description: Check public membership. - responses: - 204: - description: User is a public member. - 404: - description: User is not a public member. - put: - description: Publicize a user's membership. - responses: - 204: - description: Publicized. - delete: - description: Conceal a user's membership. - responses: - 204: - description: Concealed. - /teams: - type: collection - get: - description: List teams. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/teams/1", - "name": "Owners", - "id": 1 - } - ] - post: - description: | - Create team. - In order to create a team, the authenticated user must be an owner of orgId. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "repo_names": [ - { - "type": "string" - } - ], - "type": "array", - "permission": { - "enum": [ - "pull", - "push", - "admin" - ] - } - }, - "required": [ - "name" - ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "permission": { - "type": "string" - }, - "members_count": { - "type": "integer" - }, - "repos_count": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/teams/1", - "name": "Owners", - "id": 1 - } - ] - /repos: - type: collection - get: - description: List repositories for the specified org. - queryParameters: - type: - enum: - - all - - public - - private - - forks - - sources - - member - default: all - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - post: - description: | - Create a new repository for the authenticated user. OAuth users must supply - repo scope. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "private": { - "description": "True to create a private repository, false to create a public one. Creating private repositories requires a paid GitHub account.", - "type": "boolean" - }, - "has_issues": { - "description": "True to enable issues for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "has_wiki": { - "description": "True to enable the wiki for this repository, false to disable it. Default is true.", - "type": "boolean" - }, - "has_downloads": { - "description": "True to enable downloads for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "team_id": { - "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repo in an organization.", - "type": "integer" - }, - "auto_init": { - "description": "True to create an initial commit with empty README. Default is false.", - "type": "boolean" - }, - "gitignore_template": { - "description": "Desired language or platform .gitignore template to apply. Use the name of the template without the extension. For example, \"Haskell\" Ignored if auto_init parameter is not provided. ", - "type": "string" - } - }, - "required": [ "name" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] -/teams/{teamsId}: - uriParameters: - teamsId: - description: Id of a team. - type: integer - type: item - get: - description: Get team. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "permission": { - "type": "string" - }, - "members_count": { - "type": "integer" - }, - "repos_count": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/teams/1", - "name": "Owners", - "id": 1 - } - ] - patch: - description: | - Edit team. - In order to edit a team, the authenticated user must be an owner of the org - that the team is associated with. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "permission": { - "values": [ - "pull", - "push", - "admin" - ] - } - }, - "required": [ "name" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "permission": { - "type": "string" - }, - "members_count": { - "type": "integer" - }, - "repos_count": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/teams/1", - "name": "Owners", - "id": 1 - } - ] - delete: - description: | - Delete team. - In order to delete a team, the authenticated user must be an owner of the - org that the team is associated with. - /members: - type: collection - get: - description: | - List team members. - In order to list members in a team, the authenticated user must be a member - of the team. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{userId}: - uriParameters: - userId: - description: Id of a member. - type: integer - type: base - get: - description: | - Get team member. - In order to get if a user is a member of a team, the authenticated user must - be a member of the team. - responses: - 204: - description: User is a member. - 404: - description: User is not a member. - put: - description: | - Add team member. - In order to add a user to a team, the authenticated user must have 'admin' - permissions to the team or be an owner of the org that the team is associated - with. - responses: - 204: - description: Team member added. - 422: - description: If you attempt to add an organization to a team, you will get this. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "message": { - "type": "string" - }, - "errors": [ - { - "properties": { - "code": { - "type": "string" - }, - "field": { - "type": "string" - }, - "resource": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "object" - } - } - example: | - { - "message": "Validation Failed", - "errors": [ - { - "code": "org", - "field": "user", - "resource": "TeamMember" - } - ] - } - delete: - description: | - Remove team member. - In order to remove a user from a team, the authenticated user must have 'admin' - permissions to the team or be an owner of the org that the team is associated - with. - NOTE This does not delete the user, it just remove them from the team. - responses: - 204: - description: Team member removed. -/repositories: - type: collection - get: - securedBy: [ null, oauth_2_0 ] - description: | - List all public repositories. - This provides a dump of every public repository, in the order that they - were created. - Note: Pagination is powered exclusively by the since parameter. is the - Link header to get the URL for the next page of repositories. - queryParameters: - since: - description: | - The integer ID of the last Repository that you've seen. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World" - } - ] -/repos/{ownerId}/{repoId}: - uriParameters: - ownerId: - description: Id of the owner. - type: integer - repoId: - description: Id of repository. - type: integer - type: item - get: - description: Get repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "organization": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "parent": { - "description": "Is present when the repo is a fork. Parent is the repo this repo was forked from.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "source": { - "description": "Is present when the repo is a fork. Source is the ultimate source for the network.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "has_issues": { - "type": "boolean" - }, - "has_wiki": { - "type": "boolean" - }, - "has_downloads": { - "type": "boolean" - } - } - } - example: | - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z", - "organization": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "type": "Organization" - }, - "parent": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "source": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "has_issues": true, - "has_wiki": true, - "has_downloads": true - } - patch: - description: Edit repository. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "private": { - "description": "True makes the repository private, and false makes it public.", - "type": "boolean" - }, - "has_issues": { - "description": "True to enable issues for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "has_wiki": { - "description": "True to enable the wiki for this repository, false to disable it. Default is true.", - "type": "boolean" - }, - "has_downloads": { - "description": "True to enable downloads for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "default_branch": { - "description": "Update the default branch for this repository.", - "type": "string" - } - }, - "required": [ "name" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "organization": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "parent": { - "description": "Is present when the repo is a fork. Parent is the repo this repo was forked from.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "source": { - "description": "Is present when the repo is a fork. Source is the ultimate source for the network.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "has_issues": { - "type": "boolean" - }, - "has_wiki": { - "type": "boolean" - }, - "has_downloads": { - "type": "boolean" - } - } - } - example: | - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z", - "organization": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "type": "Organization" - }, - "parent": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "source": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "has_issues": true, - "has_wiki": true, - "has_downloads": true - } - delete: - description: | - Delete a Repository. - Deleting a repository requires admin access. If OAuth is used, the delete_repo - scope is required. - # Events - /events: - type: collection - get: - description: Get list of repository events. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - # Languages - /languages: - type: collection - get: - description: | - List languages. - List languages for the specified repository. The value on the right of a - language is the number of bytes of code written in that language. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "language": { - "type": "string" - }, - "count": { - "type": "string" - } - } - } - example: | - { - "C": 78769, - "Python": 7769 - } - # GIT - /git: - /blobs: - type: collection - post: - description: Create a Blob. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "content": { - "type": "string" - }, - "encoding": { - "enum": [ - "utf-8", - "base64" - ] - }, - "sha": { - "type": "string" - }, - "size": { - "type": "integer" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - } - } - } - example: | - { - "sha": "3a0f86fb8db8eea7ccbb9a95f325ddbedfb25e15" - } - /{shaCode}: - uriParameters: - shaCode: - description: SHA-1 code. - type: string - type: item - get: - description: | - Get a Blob. - Since blobs can be any arbitrary binary data, the input and responses for - the blob API takes an encoding parameter that can be either utf-8 or - base64. If your data cannot be losslessly sent as a UTF-8 string, you can - base64 encode it. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "content": { - "type": "string" - }, - "encoding": { - "enum": [ - "utf-8", - "base64" - ] - }, - "sha": { - "type": "string" - }, - "size": { - "type": "integer" - } - } - } - example: | - { - "content": "Content of the blob", - "encoding": "utf-8", - "sha": "3a0f86fb8db8eea7ccbb9a95f325ddbedfb25e15", - "size": 100 - } - /commits: - type: item - post: - description: Create a Commit. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "message": { - "description": "String of the commit message", - "type": "string" - }, - "tree": { - "description": "String of the SHA of the tree object this commit points to.", - "type": "string" - }, - "parents": [ - { - "description": "Array of the SHAs of the commits that were the parents of this commit. If omitted or empty, the commit will be written as a root commit. For a single parent, an array of one SHA should be provided, for a merge commit, an array of more than one should be provided.", - "type": "string" - } - ], - "type": "array", - "author": { - "properties": { - "name": { - "description": "String of the name of the author of the commit.", - "type": "string" - }, - "email": { - "description": "String of the email of the author of the commit.", - "type": "string" - }, - "date": { - "description": "Timestamp of when this commit was authored.", - "type": "timestamp" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "description": "String of the name of the committer of the commit.", - "type": "string" - }, - "email": { - "description": "String of the email of the committer of the commit.", - "type": "string" - }, - "date": { - "description": "Timestamp of when this commit was committed.", - "type": "timestamp" - } - }, - "type": "object" - } - }, - "required": [ - "message", - "tree", - "parents" - ] - } - responses: - 201: - body: - schema: | - { - "": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "message": { - "type": "string" - }, - "author": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "type": "string" - } - ], - "tree": { - "type": "string" - } - } - } - example: | - { - "message": "my commit message", - "author": { - "name": "Scott Chacon", - "email": "schacon@gmail.com", - "date": "2008-07-09T16:13:30 12:00" - }, - "parents": [ - "7d1b31e74ee336d15cbd21741bc88a537ed063a0" - ], - "tree": "827efc6d56897b048c772eb4087f854f46256132" - } - /{shaCode}: - uriParameters: - shaCode: - description: SHA-1 code. - type: string - type: item - get: - description: Get a Commit. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "author": { - "properties": { - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "sha": "7638417db6d59f3c431d3e1f261cc637155684cd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/7638417db6d59f3c431d3e1f261cc637155684cd", - "author": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "committer": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "message": "added readme, because im a good github citizen\n", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/trees/691272480426f78a0138979dd3ce63b77f706feb", - "sha": "691272480426f78a0138979dd3ce63b77f706feb" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/1acc419d4d6a9ce985db7be48c6349a0475975b5", - "sha": "1acc419d4d6a9ce985db7be48c6349a0475975b5" - } - ] - } - /refs: - type: collection - get: - description: Get all References - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "references": [ - { - "properties": { - "ref": { - "type": "string" - }, - "url": { - "type": "string" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "ref": "refs/heads/master", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/heads/master", - "object": { - "type": "commit", - "sha": "aa218f56b14c9653891f9e74264a383fa43fefbd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/aa218f56b14c9653891f9e74264a383fa43fefbd" - } - }, - { - "ref": "refs/heads/gh-pages", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/heads/gh-pages", - "object": { - "type": "commit", - "sha": "612077ae6dffb4d2fbd8ce0cccaa58893b07b5ac", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/612077ae6dffb4d2fbd8ce0cccaa58893b07b5ac" - } - }, - { - "ref": "refs/tags/v0.0.1", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/tags/v0.0.1", - "object": { - "type": "tag", - "sha": "940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "url": "https://api.github.com/repos/octocat/Hello-World/git/tags/940bd336248efae0f9ee5bc7b2d5c985887b16ac" - } - } - ] - post: - description: Create a Reference - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "ref": { - "description": "String of the name of the fully qualified reference (ie: refs/heads/master). If it doesn't start with ?refs' and have at least two slashes, it will be rejected.", - "type": "string" - }, - "sha": { - "description": "String of the SHA1 value to set this reference to.", - "type": "string" - } - }, - "required": [ - "ref", - "sha" - ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "ref": { - "type": "string" - }, - "url": { - "type": "string" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "ref": "refs/heads/sc/featureA", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/heads/sc/featureA", - "object": { - "type": "commit", - "sha": "aa218f56b14c9653891f9e74264a383fa43fefbd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/aa218f56b14c9653891f9e74264a383fa43fefbd" - } - } - /{heads}: - uriParameters: - heads: - description: Subfolder of path to the branch. - type: string - type: collection - get: - description: Get list of subdirectories. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "name": { - "type": "string" - }, - "commit": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "zipball_url": { - "type": "string" - }, - "tarball_url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "name": "v0.1", - "commit": { - "sha": "c5b97d5ae6c19d5c5df71a34c7fbeeda2479ccbc", - "url": "https://api.github.com/octocat/Hello-World/commits/c5b97d5ae6c19d5c5df71a34c7fbeeda2479ccbc" - }, - "zipball_url": "https://github.com/octocat/Hello-World/zipball/v0.1", - "tarball_url": "https://github.com/octocat/Hello-World/tarball/v0.1" - } - ] - /{branch}: - type: item - uriParameters: - branch: - description: Path to the branch. - type: string - get: - description: Get a Reference. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "ref": { - "type": "string" - }, - "url": { - "type": "string" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "ref": "refs/heads/sc/featureA", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/heads/sc/featureA", - "object": { - "type": "commit", - "sha": "aa218f56b14c9653891f9e74264a383fa43fefbd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/aa218f56b14c9653891f9e74264a383fa43fefbd" - } - } - patch: - description: Update a Reference - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "description": "String of the SHA1 value to set this reference to.", - "type": "string" - }, - "force": { - "description": "Boolean indicating whether to force the update or to make sure the update is a fast-forward update. The default is false, so leaving this out or setting it to false will make sure you're not overwriting work.", - "type": "boolean" - } - }, - "required": [ - "sha", - "force" - ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "ref": { - "type": "string" - }, - "url": { - "type": "string" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "ref": "refs/heads/sc/featureA", - "url": "https://api.github.com/repos/octocat/Hello-World/git/refs/heads/sc/featureA", - "object": { - "type": "commit", - "sha": "aa218f56b14c9653891f9e74264a383fa43fefbd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/aa218f56b14c9653891f9e74264a383fa43fefbd" - } - } - delete: - description: Delete a Reference. - /tags: - type: collection - post: - description: | - Create a Tag Object. - Note that creating a tag object does not create the reference that makes a - tag in Git. If you want to create an annotated tag in Git, you have to do - this call to create the tag object, and then create the refs/tags/[tag] - reference. If you want to create a lightweight tag, you only have to create - the tag reference - this call would be unnecessary. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "tag": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "message": { - "type": "string" - }, - "tagger": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "tag": { - "type": "string" - }, - "message": { - "description": "String of the tag message.", - "type": "string" - }, - "object": { - "description": "String of the SHA of the git object this is tagging.", - "type": "string" - }, - "type": { - "description": "String of the type of the object we're tagging. Normally this is a commit but it can also be a tree or a blob.", - "type": "string" - }, - "tagger": { - "properties": { - "name": { - "description": "String of the name of the author of the tag.", - "type": "string" - }, - "email": { - "description": "String of the email of the author of the tag.", - "type": "string" - }, - "date": { - "description": "Timestamp of when this object was tagged.", - "type": "timestamp" - } - }, - "type": "object" - } - }, - "required": [ - "tag", - "message", - "object", - "type", - "tagger" - ] - } - example: | - { - "tag": "v0.0.1", - "sha": "940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "url": "https://api.github.com/repos/octocat/Hello-World/git/tags/940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "message": "initial version\n", - "tagger": { - "name": "Scott Chacon", - "email": "schacon@gmail.com", - "date": "2011-06-17T14:53:35-07:00" - }, - "object": { - "type": "commit", - "sha": "c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c" - } - } - /{shaCode}: - type: item - get: - description: Get a Tag. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "tag": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "message": { - "type": "string" - }, - "tagger": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "object": { - "properties": { - "type": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "tag": "v0.0.1", - "sha": "940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "url": "https://api.github.com/repos/octocat/Hello-World/git/tags/940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "message": "initial version\n", - "tagger": { - "name": "Scott Chacon", - "email": "schacon@gmail.com", - "date": "2011-06-17T14:53:35-07:00" - }, - "object": { - "type": "commit", - "sha": "c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c" - } - } - /trees: - type: collection - post: - description: | - Create a Tree. - The tree creation API will take nested entries as well. If both a tree and - a nested path modifying that tree are specified, it will overwrite the - contents of that tree with the new path contents and write a new tree out. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "tree": [ - { - "path": { - "type": "string" - }, - "mode": { - "type": "string" - }, - "type": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - } - ], - "type": "array" - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "base_tree": { - "type": "string" - }, - "tree": [ - { - "properties": { - "path": { - "type": "string" - }, - "mode": { - "description": "One of 100644 for file (blob), 100755 for executable (blob), 040000 for subdirectory (tree), 160000 for submodule (commit) or 120000 for a blob that specifies the path of a symlink.", - "type": "string", - "enum": [ - "100644", - "100755", - "040000", - "160000", - "120000" - ] - }, - "type": { - "type": "string", - "enum": [ - "blob", - "tree", - "commit" - ] - }, - "oneOf": [ - { - "sha": { - "description": "SHA1 checksum ID of the object in the tree.", - "type": "string" - } - }, - { - "content": { - "description": "content you want this file to have - GitHub will write this blob out and use that SHA for this entry.", - "type": "string" - } - } - ] - }, - "type": "object" - } - ], - "type": "array" - }, - "required": [ - "tree" - ] - } - example: | - { - "sha": "cd8274d15fa3ae2ab983129fb037999f264ba9a7", - "url": "https://api.github.com/repo/octocat/Hello-World/trees/cd8274d15fa3ae2ab983129fb037999f264ba9a7", - "tree": [ - { - "path": "file.rb", - "mode": "100644", - "type": "blob", - "size": 132, - "sha": "7c258a9869f33c1e1e1f74fbb32f07c86cb5a75b", - "url": "https://api.github.com/octocat/Hello-World/git/blobs/7c258a9869f33c1e1e1f74fbb32f07c86cb5a75b" - } - ] - } - /{shaCode}: - uriParameters: - shaCode: - description: Id of the owner. - type: integer - type: item - get: - description: Get a Tree. - queryParameters: - recursive: - description: Get a Tree Recursively. (0 or 1) - type: integer - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "tree": [ - { - "path": { - "type": "string" - }, - "mode": { - "type": "string" - }, - "type": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - } - ], - "type": "array" - } - } - example: | - { - "sha": "9fb037999f264ba9a7fc6274d15fa3ae2ab98312", - "url": "https://api.github.com/repos/octocat/Hello-World/trees/9fb037999f264ba9a7fc6274d15fa3ae2ab98312", - "tree": [ - { - "path": "file.rb", - "mode": "100644", - "type": "blob", - "size": 30, - "sha": "44b4fc6d56897b048c772eb4087f854f46256132", - "url": "https://api.github.com/repos/octocat/Hello-World/git/blobs/44b4fc6d56897b048c772eb4087f854f46256132" - }, - { - "path": "subdir", - "mode": "040000", - "type": "tree", - "sha": "f484d249c660418515fb01c2b9662073663c242e", - "url": "https://api.github.com/repos/octocat/Hello-World/git/blobs/f484d249c660418515fb01c2b9662073663c242e" - }, - { - "path": "exec_file", - "mode": "100755", - "type": "blob", - "size": 75, - "sha": "45b983be36b73c0788dc9cbcb76cbb80fc7bb057", - "url": "https://api.github.com/repos/octocat/Hello-World/git/blobs/45b983be36b73c0788dc9cbcb76cbb80fc7bb057" - } - ] - } - # Readme - /readme: - type: item - get: - description: | - Get the README. - This method returns the preferred README for a repository. - queryParameters: - ref: - description: The String name of the Commit/Branch/Tag. Defaults to master. - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "type": { - "type": "string" - }, - "encoding": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "path": { - "type": "string" - }, - "content": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "_links": { - "properties": { - "git": { - "type": "string" - }, - "self": { - "type": "string" - }, - "html": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "type": "file", - "encoding": "base64", - "size": 5362, - "name": "README.md", - "path": "README.md", - "content": "encoded content ...", - "sha": "3d21ec53a331a6f037a91c368710b99387d012c1", - "url": "https://api.github.com/repos/pengwynn/octokit/contents/README.md", - "git_url": "https://api.github.com/repos/pengwynn/octokit/git/blobs/3d21ec53a331a6f037a91c368710b99387d012c1", - "html_url": "https://github.com/pengwynn/octokit/blob/master/README.md", - "_links": { - "git": "https://api.github.com/repos/pengwynn/octokit/git/blobs/3d21ec53a331a6f037a91c368710b99387d012c1", - "self": "https://api.github.com/repos/pengwynn/octokit/contents/README.md", - "html": "https://github.com/pengwynn/octokit/blob/master/README.md" - } - } - # Stargazers - /stargazers: - type: collection - get: - description: List Stargazers. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - # Subscribers - /subscribers: - type: collection - get: - description: List watchers. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - # Tags - /tags: - type: collection - get: - description: Get list of tags. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "tag": { - "type": "string" - }, - "message": { - "description": "String of the tag message.", - "type": "string" - }, - "object": { - "description": "String of the SHA of the git object this is tagging.", - "type": "string" - }, - "type": { - "description": "String of the type of the object we're tagging. Normally this is a commit but it can also be a tree or a blob.", - "type": "string" - }, - "tagger": { - "properties": { - "name": { - "description": "String of the name of the author of the tag.", - "type": "string" - }, - "email": { - "description": "String of the email of the author of the tag.", - "type": "string" - }, - "date": { - "description": "Timestamp of when this object was tagged.", - "type": "timestamp" - } - }, - "type": "object" - } - }, - "required": [ - "tag", - "message", - "object", - "type", - "tagger" - ] - } - example: | - { - "tag": "v0.0.1", - "sha": "940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "url": "https://api.github.com/repos/octocat/Hello-World/git/tags/940bd336248efae0f9ee5bc7b2d5c985887b16ac", - "message": "initial version\n", - "tagger": { - "name": "Scott Chacon", - "email": "schacon@gmail.com", - "date": "2011-06-17T14:53:35-07:00" - }, - "object": { - "type": "commit", - "sha": "c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/c3d0be41ecbe669545ee3e94d31ed9a4bc91ee3c" - } - } - # Teams - /teams: - type: collection - get: - description: Get list of teams - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/teams/1", - "name": "Owners", - "id": 1 - } - ] - # Watchers - /watchers: - type: collection - get: - description: List Stargazers. New implementation. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - # Other links - /contributors: - type: collection - get: - description: Get list of contributors. - queryParameters: - anon: - description: Set to 1 or true to include anonymous contributors in results. - type: string - required: true - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "contributions": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "contributions": 32 - } - ] - /branches: - type: collection - get: - description: Get list of branches - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "name": { - "type": "string" - }, - "commit": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "name": "master", - "commit": { - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "url": "https://api.github.com/repos/octocat/Hello-World/commits/c5b97d5ae6c19d5c5df71a34c7fbeeda2479ccbc" - } - } - ] - /{branchId}: - uriParameters: - branchId: - description: Id of the branch. - type: integer - type: item - get: - description: Get Branch - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "commit": { - "properties": { - "sha": { - "type": "string" - }, - "commit": { - "author": { - "name": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "email": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "author": { - "properties": { - "gravatar_id": { - "type": "string" - }, - "avatar_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "login": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "url": { - "type": "string" - }, - "committer": { - "properties": { - "gravatar_id": { - "type": "string" - }, - "avatar_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "login": { - "type": "string" - } - }, - "type": "object" - } - }, - "_links": { - "properties": { - "html": { - "type": "string" - }, - "self": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "name": "master", - "commit": { - "sha": "7fd1a60b01f91b314f59955a4e4d4e80d8edf11d", - "commit": { - "author": { - "name": "The Octocat", - "date": "2012-03-06T15:06:50-08:00", - "email": "octocat@nowhere.com" - }, - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/7fd1a60b01f91b314f59955a4e4d4e80d8edf11d", - "message": "Merge pull request #6 from Spaceghost/patch-1\n\nNew line at end of file.", - "tree": { - "sha": "b4eecafa9be2f2006ce1b709d6857b07069b4608", - "url": "https://api.github.com/repos/octocat/Hello-World/git/trees/b4eecafa9be2f2006ce1b709d6857b07069b4608" - }, - "committer": { - "name": "The Octocat", - "date": "2012-03-06T15:06:50-08:00", - "email": "octocat@nowhere.com" - } - }, - "author": { - "gravatar_id": "7ad39074b0584bc555d0417ae3e7d974", - "avatar_url": "https://secure.gravatar.com/avatar/7ad39074b0584bc555d0417ae3e7d974?d=https://a248.e.akamai.net/assets.github.com/images/gravatars/gravatar-140.png", - "url": "https://api.github.com/users/octocat", - "id": 583231, - "login": "octocat" - }, - "parents": [ - { - "sha": "553c2077f0edc3d5dc5d17262f6aa498e69d6f8e", - "url": "https://api.github.com/repos/octocat/Hello-World/commits/553c2077f0edc3d5dc5d17262f6aa498e69d6f8e" - }, - { - "sha": "762941318ee16e59dabbacb1b4049eec22f0d303", - "url": "https://api.github.com/repos/octocat/Hello-World/commits/762941318ee16e59dabbacb1b4049eec22f0d303" - } - ], - "url": "https://api.github.com/repos/octocat/Hello-World/commits/7fd1a60b01f91b314f59955a4e4d4e80d8edf11d", - "committer": { - "gravatar_id": "7ad39074b0584bc555d0417ae3e7d974", - "avatar_url": "https://secure.gravatar.com/avatar/7ad39074b0584bc555d0417ae3e7d974?d=https://a248.e.akamai.net/assets.github.com/images/gravatars/gravatar-140.png", - "url": "https://api.github.com/users/octocat", - "id": 583231, - "login": "octocat" - } - }, - "_links": { - "html": "https://github.com/octocat/Hello-World/tree/master", - "self": "https://api.github.com/repos/octocat/Hello-World/branches/master" - } - } - /issues: - type: collection - get: - is: [ filterable ] - description: List issues for a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "issues": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - ] - post: - description: | - Create an issue. - Any user with pull access to a repository can create an issue. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "assignee": { - "description": "Login for the user that this issue should be assigned to. NOTE: Only users with push access can set the assignee for new issues. The assignee is silently dropped otherwise.", - "type": "string" - }, - "milestone": { - "description": "Milestone to associate this issue with. NOTE: Only users with push access can set the milestone for new issues. The milestone is silently dropped otherwise.", - "type": "integer" - }, - "labels": [ - { - "description": "Array of strings - Labels to associate with this issue. NOTE: Only users with push access can set labels for new issues. Labels are silently dropped otherwise.", - "type": "string" - } - ], - "type": "array" - }, - "required": [ "title" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - /events: - type: collection - get: - description: List issue events for a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - /{eventId}: - uriParameters: - eventId: - description: Id of the event. - type: integer - type: item - get: - description: Get a single event. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "type": "object" - }, - "event": { - "type": "string" - }, - "commit_id": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "issue": { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/events/1", - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "event": "closed", - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "created_at": "2011-04-14T16:00:49Z", - "issue": { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - } - /{number}: - uriParameters: - number: - description: Id of the issue. - type: integer - type: item - get: - description: Get a single issue - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - patch: - description: | - Edit an issue. - Issue owners and users with push access can edit an issue. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - # Comments - /comments: - type: collection - get: - description: List comments on an issue. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - ] - post: - description: Create a comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - } - }, - "required": [ "body" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/repos/octocat/Hello-World/issues/comments/1", - "html_url": "https://github.com/octocat/Hello-World/issues/1347#issuecomment-1", - "body": "Me too", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - # Events - /events: - type: collection - get: - description: List issue events for a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - /{eventId}: - uriParameters: - eventId: - description: Id of the event. - type: integer - type: item - get: - description: Get a single event. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "type": "object" - }, - "event": { - "type": "string" - }, - "commit_id": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "issue": { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/events/1", - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "event": "closed", - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "created_at": "2011-04-14T16:00:49Z", - "issue": { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - } - # Labels - /labels: - type: collection - get: - description: List labels on an issue. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ] - post: - description: Add labels to an issue. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "color": { - "description": "6 character hex code, without a leading #.", - "type": "string", - "minLength": 6, - "maxLength": 6 - } - }, - "required": [ "name", "color" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - put: - description: | - Replace all labels for an issue. - Sending an empty array ([]) will remove all Labels from the Issue. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "color": { - "description": "6 character hex code, without a leading #.", - "type": "string", - "minLength": 6, - "maxLength": 6 - } - }, - "required": [ "name", "color" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - delete: - description: Remove all labels from an issue. - /{name}: - uriParameters: - name: - description: Name of the label. - type: string - type: base - delete: - description: Remove a label from an issue. - responses: - 204: - description: Item removed. - /comments: - type: collection - get: - description: List comments in a repository. - queryParameters: - sort: - enum: - - created - - updated - direction: - description: Ignored without sort parameter. - enum: - - asc - - desc - since: - description: Timestamp in ISO 8601 format YYYY-MM-DDTHH:MM:SSZ. - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - ] - /{commentId}: - uriParameters: - commentId: - description: Id of the comment. - type: integer - type: item - get: - description: Get a single comment. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/repos/octocat/Hello-World/issues/comments/1", - "html_url": "https://github.com/octocat/Hello-World/issues/1347#issuecomment-1", - "body": "Me too", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - patch: - description: Edit a comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - } - }, - "required": [ "body" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "id": 1, - "url": "https://api.github.com/repos/octocat/Hello-World/issues/comments/1", - "html_url": "https://github.com/octocat/Hello-World/issues/1347#issuecomment-1", - "body": "Me too", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - delete: - description: Delete a comment. - /notifications: - type: collection - get: - description: | - List your notifications in a repository - List all notifications for the current user. - queryParameters: - all: - description: True to show notifications marked as read. - type: string - participating: - description: | - True to show only notifications in which the user is directly participating - or mentioned. - type: string - since: - description: | - Time filters out any notifications updated before the given time. The - time should be passed in as UTC in the ISO 8601 format YYYY-MM-DDTHH:MM:SSZ. - Example: "2012-10-09T23:39:01Z". - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "id": { - "type": "integer" - }, - "repository": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - } - }, - "type": "object" - }, - "subject": { - "properties": { - "title": { - "type": "string" - }, - "url": { - "type": "string" - }, - "latest_comment_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "reason": { - "type": "string" - }, - "unread": { - "type": "boolean" - }, - "updated_at": { - "type": "string" - }, - "last_read_at": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "repository": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World" - }, - "subject": { - "title": "Greetings", - "url": "https://api.github.com/repos/pengwynn/octokit/issues/123", - "latest_comment_url": "https://api.github.com/repos/pengwynn/octokit/issues/comments/123", - "type": "Issue" - }, - "reason": "subscribed", - "unread": true, - "updated_at": "2012-09-25T07:54:41-07:00", - "last_read_at": "2012-09-25T07:54:41-07:00", - "url": "https://api.github.com/notifications/threads/1" - } - ] - put: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "last_read_at": { - "description": "Describes the last point that notifications were checked. Anything updated since this time will not be updated. Default: Now.", - "type": "string" - } - } - } - description: | - Mark notifications as read in a repository. - Marking all notifications in a repository as "read" removes them from the - default view on GitHub.com. - responses: - 205: - description: Marked as read. - /subscription: - type: collection - get: - description: Get a Repository Subscription. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed": { - "type": "boolean" - }, - "ignored": { - "type": "boolean" - }, - "reason": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "url": { - "type": "string" - }, - "repository_url": { - "type": "string" - } - } - } - example: | - { - "subscribed": true, - "ignored": false, - "reason": null, - "created_at": "2012-10-06T21:34:12Z", - "url": "https://api.github.com/repos/octocat/example/subscription", - "repository_url": "https://api.github.com/repos/octocat/example" - } - put: - description: Set a Repository Subscription - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed": { - "description": "Determines if notifications should be received from this repository.", - "type": "boolean" - }, - "ignored": { - "description": "Determines if all notifications should be blocked from this repository.", - "type": "boolean" - } - }, - "required": [ "subscribed", "ignored" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "subscribed": { - "type": "boolean" - }, - "ignored": { - "type": "boolean" - }, - "reason": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "url": { - "type": "string" - }, - "repository_url": { - "type": "string" - } - } - } - example: | - { - "subscribed": true, - "ignored": false, - "reason": null, - "created_at": "2012-10-06T21:34:12Z", - "url": "https://api.github.com/repos/octocat/example/subscription", - "repository_url": "https://api.github.com/repos/octocat/example" - } - delete: - description: Delete a Repository Subscription. - /assignees: - type: collection - get: - description: | - List assignees. - This call lists all the available assignees (owner collaborators) to which - issues may be assigned. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "integer" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{assignee}: - type: base - uriParameters: - assignee: - description: Login of the assignee. - type: string - get: - description: | - Check assignee. - You may also check to see if a particular user is an assignee for a repository. - responses: - 204: - description: User is an assignee. - 404: - description: User isn't an assignee. - /labels: - type: collection - get: - description: List all labels for this repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ] - post: - description: Create a label. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "color": { - "description": "6 character hex code, without a leading #.", - "type": "string", - "minLength": 6, - "maxLength": 6 - } - }, - "required": [ "name", "color" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - /{name}: - uriParameters: - name: - description: Name of the label. - type: string - type: item - get: - description: Get a single label. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - patch: - description: Update a label. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "color": { - "description": "6 character hex code, without a leading #.", - "type": "string", - "minLength": 6, - "maxLength": 6 - } - }, - "required": [ "name", "color" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - delete: - description: Delete a label. - /milestones: - type: collection - get: - description: List milestones for a repository. - queryParameters: - state: - enum: - - open - - closed - default: open - sort: - enum: - - due_date - - completeness - default: due_date - direction: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - } - post: - description: Create a milestone. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "description": { - "type": "string" - }, - "due_on": { - "description": "ISO 8601 time.", - "type": "string" - } - }, - "required": [ "title" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - } - /{number}: - uriParameters: - number: - description: Id of the milestone. - type: integer - type: item - get: - description: Get a single milestone. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - } - patch: - description: Update a milestone. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "number": { - "type": "integer" - }, - "title": { - "type": "string" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "description": { - "type": "string" - }, - "due_on": { - "description": "ISO 8601 time.", - "type": "string" - } - }, - "required": [ "number" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - } - delete: - description: Delete a milestone. - /labels: - type: collection - get: - description: Get labels for every issue in a milestone. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string", - "maxLength": 6, - "minLength": 6 - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ] - /pulls: - type: collection - get: - description: List pull requests. - queryParameters: - state: - description: String to filter by state. - enum: - - open - - closed - default: open - head: - description: | - Filter pulls by head user and branch name in the format of 'user:ref-name'. - Example: github:new-script-format. - type: string - base: - description: Filter pulls by base branch name. Example - gh-pages. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - }, - "issue_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "merged_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "head": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "base": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "review_comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/octocat/Hello-World/pulls/1", - "html_url": "https://github.com/octocat/Hello-World/pulls/1", - "diff_url": "https://github.com/octocat/Hello-World/pulls/1.diff", - "patch_url": "https://github.com/octocat/Hello-World/pulls/1.patch", - "issue_url": "https://github.com/octocat/Hello-World/issue/1", - "number": 1, - "state": "open", - "title": "new-feature", - "body": "Please pull these awesome changes", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:01:12Z", - "closed_at": "2011-01-26T19:01:12Z", - "merged_at": "2011-01-26T19:01:12Z", - "head": { - "label": "new-topic", - "ref": "new-topic", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "base": { - "label": "master", - "ref": "master", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1" - }, - "comments": { - "href": "https://api.github.com/octocat/Hello-World/issues/1/comments" - }, - "review_comments": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1/comments" - } - }, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - } - ] - post: - description: Create a pull request. - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - }, - "issue_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "merged_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "head": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "base": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "review_comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/octocat/Hello-World/pulls/1", - "html_url": "https://github.com/octocat/Hello-World/pulls/1", - "diff_url": "https://github.com/octocat/Hello-World/pulls/1.diff", - "patch_url": "https://github.com/octocat/Hello-World/pulls/1.patch", - "issue_url": "https://github.com/octocat/Hello-World/issue/1", - "number": 1, - "state": "open", - "title": "new-feature", - "body": "Please pull these awesome changes", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:01:12Z", - "closed_at": "2011-01-26T19:01:12Z", - "merged_at": "2011-01-26T19:01:12Z", - "head": { - "label": "new-topic", - "ref": "new-topic", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "base": { - "label": "master", - "ref": "master", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1" - }, - "comments": { - "href": "https://api.github.com/octocat/Hello-World/issues/1/comments" - }, - "review_comments": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1/comments" - } - }, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - } - ] - /{number}: - uriParameters: - number: - description: Id of a pull. - type: integer - type: item - get: - description: Get a single pull request. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - }, - "issue_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "merged_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "head": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "base": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "review_comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "url": "https://api.github.com/octocat/Hello-World/pulls/1", - "html_url": "https://github.com/octocat/Hello-World/pulls/1", - "diff_url": "https://github.com/octocat/Hello-World/pulls/1.diff", - "patch_url": "https://github.com/octocat/Hello-World/pulls/1.patch", - "issue_url": "https://github.com/octocat/Hello-World/issue/1", - "number": 1, - "state": "open", - "title": "new-feature", - "body": "Please pull these awesome changes", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:01:12Z", - "closed_at": "2011-01-26T19:01:12Z", - "merged_at": "2011-01-26T19:01:12Z", - "head": { - "label": "new-topic", - "ref": "new-topic", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "base": { - "label": "master", - "ref": "master", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1" - }, - "comments": { - "href": "https://api.github.com/octocat/Hello-World/issues/1/comments" - }, - "review_comments": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1/comments" - } - }, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "merge_commit_sha": "e5bd3914e2e596debea16f433f57875b5b90bcd6", - "merged": false, - "mergeable": true, - "merged_by": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "comments": 10, - "commits": 3, - "additions": 100, - "deletions": 3, - "changed_files": 5 - } - patch: - description: Update a pull request. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "state": { - "enum": [ "open", "closed" ] - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "organization": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "parent": { - "description": "Is present when the repo is a fork. Parent is the repo this repo was forked from.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "source": { - "description": "Is present when the repo is a fork. Source is the ultimate source for the network.", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "has_issues": { - "type": "boolean" - }, - "has_wiki": { - "type": "boolean" - }, - "has_downloads": { - "type": "boolean" - } - } - } - example: | - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z", - "organization": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "type": "Organization" - }, - "parent": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "source": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - }, - "has_issues": true, - "has_wiki": true, - "has_downloads": true - } - # Files - /files: - type: item - get: - description: List pull requests files. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - }, - "issue_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "merged_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "head": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "base": { - "properties": { - "label": { - "type": "string" - }, - "ref": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "review_comments": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/octocat/Hello-World/pulls/1", - "html_url": "https://github.com/octocat/Hello-World/pulls/1", - "diff_url": "https://github.com/octocat/Hello-World/pulls/1.diff", - "patch_url": "https://github.com/octocat/Hello-World/pulls/1.patch", - "issue_url": "https://github.com/octocat/Hello-World/issue/1", - "number": 1, - "state": "open", - "title": "new-feature", - "body": "Please pull these awesome changes", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:01:12Z", - "closed_at": "2011-01-26T19:01:12Z", - "merged_at": "2011-01-26T19:01:12Z", - "head": { - "label": "new-topic", - "ref": "new-topic", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "base": { - "label": "master", - "ref": "master", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "repo": { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - }, - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1" - }, - "comments": { - "href": "https://api.github.com/octocat/Hello-World/issues/1/comments" - }, - "review_comments": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1/comments" - } - }, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - } - ] - # Commits - /commits: - type: item - get: - description: List commits on a pull request. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "commit": { - "properties": { - "url": { - "type": "string" - }, - "author": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - }, - "author": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array" - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "commit": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "author": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "committer": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "message": "Fix all the bugs", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/tree/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - }, - "author": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "committer": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - ] - } - ] - /merge: - type: base - get: - description: Get if a pull request has been merged. - responses: - 204: - description: Pull request has been merged. - 404: - description: Pull request has not been merged. - put: - description: Merge a pull request (Merge Buttonâ„¢) - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "commit_message": { - "description": "The message that will be used for the merge commit", - "type": "string" - } - } - } - responses: - 200: - description: Response if merge was successful. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "merged": { - "type": "boolean" - }, - "message": { - "type": "string" - } - } - } - example: | - { - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "merged": true, - "message": "Pull Request successfully merged" - } - 405: - description: Response if merge cannot be performed. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "merged": { - "type": "boolean" - }, - "message": { - "type": "string" - } - } - } - example: | - { - "sha": null, - "merged": false, - "message": "Failure reason" - } - /comments: - type: collection - get: - description: List comments on a pull request. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - post: - description: | - Create a comment. - #TODO Alternative input ( http://developer.github.com/v3/pulls/comments/ ) - description: | - Alternative Input. - Instead of passing commit_id, path, and position you can reply to an - existing Pull Request Comment like this: - - body - Required string - in_reply_to - Required number - Comment id to reply to. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - }, - "commit_id": { - "description": "Sha of the commit to comment on.", - "type": "string" - }, - "path": { - "description": "Relative path of the file to comment on.", - "type": "string" - }, - "position": { - "description": "Line index in the diff to comment on.", - "type": "string" - } - }, - "required": [ "body", "commit_id", "path", "position" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - /comments: - type: collection - get: - description: | - List comments in a repository. - By default, Review Comments are ordered by ascending ID. - queryParameters: - sort: - enum: - - created - - updated - direction: - description: Ignored without 'sort' parameter. - enum: - - asc - - desc - since: - description: Timestamp in ISO 8601 format YYYY-MM-DDTHH:MM:SSZ - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - ] - /{number}: - uriParameters: - number: - description: Id of the comment. - type: integer - type: item - get: - description: Get a single comment. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - patch: - description: Edit a comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - } - }, - "required": [ "body" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "_links": { - "properties": { - "self": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "html": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - }, - "pull_request": { - "properties": { - "href": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/pulls/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z", - "_links": { - "self": { - "href": "https://api.github.com/octocat/Hello-World/pulls/comments/1" - }, - "html": { - "href": "https://github.com/octocat/Hello-World/pull/1#discussion-diff-1" - }, - "pull_request": { - "href": "https://api.github.com/octocat/Hello-World/pulls/1" - } - } - } - delete: - description: Delete a comment. - /collaborators: - type: collection - get: - description: | - List. - When authenticating as an organization owner of an organization-owned - repository, all organization owners are included in the list of - collaborators. Otherwise, only users with access to the repository are - returned in the collaborators list. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{user}: - uriParameters: - user: - description: Login of the user. - type: string - type: base - get: - description: Check if user is a collaborator - responses: - 204: - description: User is a collaborator. - 404: - description: User is not a collaborator. - put: - description: Add collaborator. - responses: - 204: - description: Collaborator added. - delete: - description: Remove collaborator. - responses: - 204: - description: Collaborator removed. - /comments: - type: collection - get: - description: | - List commit comments for a repository. - Comments are ordered by ascending ID. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "html_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "line": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "html_url": "https://github.com/octocat/Hello-World/commit/6dcb09b5b57875f334f61aebed695e2e4193db5e#commitcomment-1", - "url": "https://api.github.com/repos/octocat/Hello-World/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "line": 14, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - ] - /{commentId}: - uriParameters: - commentId: - description: Id of a comment. - type: integer - type: item - get: - description: Get a single commit comment. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "html_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "line": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "html_url": "https://github.com/octocat/Hello-World/commit/6dcb09b5b57875f334f61aebed695e2e4193db5e#commitcomment-1", - "url": "https://api.github.com/repos/octocat/Hello-World/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "line": 14, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - patch: - description: Update a commit comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "body": { - "type": "string" - } - }, - "required": [ "body" ] - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "html_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "line": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "html_url": "https://github.com/octocat/Hello-World/commit/6dcb09b5b57875f334f61aebed695e2e4193db5e#commitcomment-1", - "url": "https://api.github.com/repos/octocat/Hello-World/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "line": 14, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - delete: - description: Delete a commit comment - /commits: - type: collection - get: - description: List commits on a repository. - queryParameters: - sha: - description: Sha or branch to start listing commits from. - type: string - path: - description: Only commits containing this file path will be returned. - type: string - author: - description: GitHub login, name, or email by which to filter by commit author. - type: string - since: - description: ISO 8601 Date - Only commits after this date will be returned. - type: string - until: - description: ISO 8601 Date - Only commits before this date will be returned. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "commit": { - "properties": { - "url": { - "type": "string" - }, - "author": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - }, - "author": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array" - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "commit": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "author": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "committer": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "message": "Fix all the bugs", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/tree/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - }, - "author": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "committer": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - ] - } - ] - /{shaCode}: - uriParameters: - shaCode: - description: SHA-1 code of the commit. - type: string - type: item - get: - description: Get a single commit. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "commit": { - "properties": { - "url": { - "type": "string" - }, - "author": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "date": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - }, - "author": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "commit": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "author": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "committer": { - "name": "Monalisa Octocat", - "email": "support@github.com", - "date": "2011-04-14T16:00:49Z" - }, - "message": "Fix all the bugs", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/tree/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - }, - "author": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "committer": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e", - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e" - } - ], - "stats": { - "additions": 104, - "deletions": 4, - "total": 108 - }, - "files": [ - { - "filename": "file1.txt", - "additions": 10, - "deletions": 2, - "changes": 12, - "status": "modified", - "raw_url": "https://github.com/octocat/Hello-World/raw/7ca483543807a51b6079e54ac4cc392bc29ae284/file1.txt", - "blob_url": "https://github.com/octocat/Hello-World/blob/7ca483543807a51b6079e54ac4cc392bc29ae284/file1.txt", - "patch": "@@ -29,7 29,7 @@\n....." - } - ] - } - /comments: - type: collection - get: - description: List comments for a single commitList comments for a single commit. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "html_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "line": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "html_url": "https://github.com/octocat/Hello-World/commit/6dcb09b5b57875f334f61aebed695e2e4193db5e#commitcomment-1", - "url": "https://api.github.com/repos/octocat/Hello-World/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "line": 14, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - ] - post: - description: Create a commit comment. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "description": "SHA of the commit to comment on.", - "type": "string" - }, - "body": { - "type": "string" - }, - "path": { - "description": "Relative path of the file to comment on.", - "type": "string" - }, - "position": { - "description": "Line index in the diff to comment on.", - "type": "integer" - }, - "line": { - "description": "Deprecated - Use position parameter instead.", - "type": "string" - }, - "number": { - "description": "Line number in the file to comment on. Defaults to null.", - "type": "string" - } - }, - "required": [ "sha", "body" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "html_url": { - "type": "string" - }, - "url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "body": { - "type": "string" - }, - "path": { - "type": "string" - }, - "position": { - "type": "integer" - }, - "line": { - "type": "integer" - }, - "commit_id": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "html_url": "https://github.com/octocat/Hello-World/commit/6dcb09b5b57875f334f61aebed695e2e4193db5e#commitcomment-1", - "url": "https://api.github.com/repos/octocat/Hello-World/comments/1", - "id": 1, - "body": "Great stuff", - "path": "file1.txt", - "position": 4, - "line": 14, - "commit_id": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-04-14T16:00:49Z", - "updated_at": "2011-04-14T16:00:49Z" - } - /contents/{path}: - uriParameters: - path: - type: string - type: base - get: - description: | - Get contents. - This method returns the contents of a file or directory in a repository. - Files and symlinks support a custom media type for getting the raw content. - Directories and submodules do not support custom media types. - Note: This API supports files up to 1 megabyte in size. - Here can be many outcomes. For details see "http://developer.github.com/v3/repos/contents/" - queryParameters: - path: - description: The content path. - type: string - ref: - description: The String name of the Commit/Branch/Tag. Defaults to 'master'. - type: string - responses: - 200: - body: - application/json: - #TODO many outcomes - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "type": { - "type": "string" - }, - "encoding": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "path": { - "type": "string" - }, - "content": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "_links": { - "properties": { - "git": { - "type": "string" - }, - "self": { - "type": "string" - }, - "html": { - "type": "string" - } - }, - "type": "object" - } - } - } - example: | - { - "type": "file", - "encoding": "base64", - "size": 5362, - "name": "README.md", - "path": "README.md", - "content": "encoded content ...", - "sha": "3d21ec53a331a6f037a91c368710b99387d012c1", - "url": "https://api.github.com/repos/pengwynn/octokit/contents/README.md", - "git_url": "https://api.github.com/repos/pengwynn/octokit/git/blobs/3d21ec53a331a6f037a91c368710b99387d012c1", - "html_url": "https://github.com/pengwynn/octokit/blob/master/README.md", - "_links": { - "git": "https://api.github.com/repos/pengwynn/octokit/git/blobs/3d21ec53a331a6f037a91c368710b99387d012c1", - "self": "https://api.github.com/repos/pengwynn/octokit/contents/README.md", - "html": "https://github.com/pengwynn/octokit/blob/master/README.md" - } - } - put: - description: Create a file. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "content": { - "properties": { - "name": { - "type": "string" - }, - "path": { - "type": "string" - }, - "sha": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "type": { - "type": "string" - }, - "_links": { - "properties": { - "self": { - "type": "string" - }, - "git": { - "type": "string" - }, - "html": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "commit": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "author": { - "properties": { - "date": { - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "date": { - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ] - }, - "type": "object" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "path": { - "description": "The content path.", - "type": "string" - }, - "message": { - "description": "The commit message.", - "type": "string" - }, - "content": { - "description": "The new file content, Base64 encoded.", - "type": "string" - }, - "sha": { - "description": "Is included if we want to modify existing file. The blob SHA of the file being replaced.", - "type": "string" - }, - "branch": { - "description": "The branch name. If not provided, uses the repository's default branch (usually master).", - "type": "string" - }, - "author": { - "properties": { - "name": { - "description": "The name of the author of the commit.", - "type": "string" - }, - "email": { - "description": "The email of the author of the commit", - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "description": "The name of the committer of the commit.", - "type": "string" - }, - "email": { - "description": "The email of the committer of the commit.", - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ "path", "message", "content", "branch" ] - } - example: | - { - "content": { - "name": "hello.txt", - "path": "notes/hello.txt", - "sha": "95b966ae1c166bd92f8ae7d1c313e738c731dfc3", - "size": 9, - "url": "https://api.github.com/repos/octocat/Hello-World/contents/notes/hello.txt", - "html_url": "https://github.com/octocat/Hello-World/blob/master/notes/hello.txt", - "git_url": "https://api.github.com/repos/octocat/Hello-World/git/blobs/95b966ae1c166bd92f8ae7d1c313e738c731dfc3", - "type": "file", - "_links": { - "self": "https://api.github.com/repos/octocat/Hello-World/contents/notes/hello.txt", - "git": "https://api.github.com/repos/octocat/Hello-World/git/blobs/95b966ae1c166bd92f8ae7d1c313e738c731dfc3", - "html": "https://github.com/octocat/Hello-World/blob/master/notes/hello.txt" - } - }, - "commit": { - "sha": "7638417db6d59f3c431d3e1f261cc637155684cd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/7638417db6d59f3c431d3e1f261cc637155684cd", - "html_url": "https://github.com/octocat/Hello-World/git/commit/7638417db6d59f3c431d3e1f261cc637155684cd", - "author": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "committer": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "message": "my commit message", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/trees/691272480426f78a0138979dd3ce63b77f706feb", - "sha": "691272480426f78a0138979dd3ce63b77f706feb" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/1acc419d4d6a9ce985db7be48c6349a0475975b5", - "html_url": "https://github.com/octocat/Hello-World/git/commit/1acc419d4d6a9ce985db7be48c6349a0475975b5", - "sha": "1acc419d4d6a9ce985db7be48c6349a0475975b5" - } - ] - } - } - delete: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "path": { - "description": "The content path.", - "type": "string" - }, - "message": { - "description": "The commit message.", - "type": "string" - }, - "content": { - "description": "The new file content, Base64 encoded.", - "type": "string" - }, - "sha": { - "description": "The blob SHA of the file being removed.", - "type": "string" - }, - "branch": { - "description": "The branch name. If not provided, uses the repository's default branch (usually master).", - "type": "string" - }, - "author": { - "properties": { - "name": { - "description": "The name of the author of the commit.", - "type": "string" - }, - "email": { - "description": "The email of the author of the commit", - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "description": "The name of the committer of the commit.", - "type": "string" - }, - "email": { - "description": "The email of the committer of the commit.", - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ "path", "message", "sha" ] - } - description: | - Delete a file. - This method deletes a file in a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "content": { - "type": "string" - }, - "commit": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "author": { - "properties": { - "date": { - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "date": { - "type": "string" - }, - "name": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "sha": { - "type": "string" - } - }, - "type": "object" - } - ] - }, - "type": "object" - } - } - } - example: | - { - "content": null, - "commit": { - "sha": "7638417db6d59f3c431d3e1f261cc637155684cd", - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/7638417db6d59f3c431d3e1f261cc637155684cd", - "html_url": "https://github.com/octocat/Hello-World/git/commit/7638417db6d59f3c431d3e1f261cc637155684cd", - "author": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "committer": { - "date": "2010-04-10T14:10:01-07:00", - "name": "Scott Chacon", - "email": "schacon@gmail.com" - }, - "message": "my commit message", - "tree": { - "url": "https://api.github.com/repos/octocat/Hello-World/git/trees/691272480426f78a0138979dd3ce63b77f706feb", - "sha": "691272480426f78a0138979dd3ce63b77f706feb" - }, - "parents": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/git/commits/1acc419d4d6a9ce985db7be48c6349a0475975b5", - "html_url": "https://github.com/octocat/Hello-World/git/commit/1acc419d4d6a9ce985db7be48c6349a0475975b5", - "sha": "1acc419d4d6a9ce985db7be48c6349a0475975b5" - } - ] - } - } - /{archive_format}/{path}: - type: base - uriParameters: - archive_format: - enum: - - tarball - - zipball - required: true - path: - description: Valid Git reference, defaults to 'master'. - type: string - get: - description: | - Get archive link. - This method will return a 302 to a URL to download a tarball or zipball - archive for a repository. Please make sure your HTTP framework is - configured to follow redirects or you will need to use the Location header - to make a second GET request. - Note: For private repositories, these links are temporary and expire quickly. - responses: - 302: - description: Found. - /downloads: - type: collection - get: - description: List downloads for a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "download_count": { - "type": "integer" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/downloads/1", - "html_url": "https://github.com/repos/octocat/Hello-World/downloads/new_file.jpg", - "id": 1, - "name": "new_file.jpg", - "description": "Description of your download", - "size": 1024, - "download_count": 40, - "content_type": ".jpg" - } - post: - description: | - Create a new download (Part 1: Create the resource). - For part 2 see http://developer.github.com/v3/repos/downloads/#create-a-new-download-part-2-upload-file-to-s3 - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "size": { - "description": "Size of file in bytes.", - "type": "integer" - }, - "description": { - "type": "string" - }, - "content_type": { - "type": "string" - } - }, - "required": [ "name", "size" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "download_count": { - "type": "integer" - }, - "content_type": { - "type": "string" - }, - "policy": { - "type": "string" - }, - "signature": { - "type": "string" - }, - "bucket": { - "type": "string" - }, - "accesskeyid": { - "type": "string" - }, - "path": { - "type": "string" - }, - "acl": { - "type": "string" - }, - "expirationdate": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "prefix": { - "type": "string" - }, - "mime_type": { - "type": "string" - }, - "redirect": { - "type": "boolean" - }, - "s3_url": { - "type": "string" - } - } - } - example: | - { - "url": "https://api.github.com/repos/octocat/Hello-World/downloads/1", - "html_url": "https://github.com/repos/octocat/Hello-World/downloads/new_file.jpg", - "id": 1, - "name": "new_file.jpg", - "description": "Description of your download", - "size": 1024, - "download_count": 40, - "content_type": ".jpg", - "policy": "ewogICAg...", - "signature": "mwnFDC...", - "bucket": "github", - "accesskeyid": "1ABCDEFG...", - "path": "downloads/octocat/Hello-World/new_file.jpg", - "acl": "public-read", - "expirationdate": "2011-04-14T16:00:49Z", - "prefix": "downloads/octocat/Hello-World/", - "mime_type": "image/jpeg", - "redirect": false, - "s3_url": "https://github.s3.amazonaws.com/" - } - /{downloadId}: - type: item - uriParameters: - downloadId: - description: Id of the download. - type: integer - get: - description: Get a single download. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "size": { - "type": "integer" - }, - "download_count": { - "type": "integer" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - delete: - description: Delete a download. - /forks: - type: collection - get: - description: List forks. - queryParameters: - sort: - enum: - - newest - - oldest - - watchers - default: newest - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - post: - description: | - Create a fork. - Forking a Repository happens asynchronously. Therefore, you may have to wait - a short period before accessing the git objects. If this takes longer than 5 - minutes, be sure to contact Support. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "organization": { - "description": "Organization login. The repository will be forked into this organization.", - "type": "string" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - } - } - example: | - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - /keys: - type: collection - get: - description: Get list of keys. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - ] - post: - description: Create a key. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "key": { - "type": "string" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - /{keyId}: - uriParameters: - keyId: - description: Id of a key. - type: integer - type: item - get: - description: Get a key - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - patch: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "key": { - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - description: Edit a key. - delete: - description: Delete a key. - /hooks: - type: collection - get: - description: Get list of hooks. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "type": "boolean" - }, - "config": { - "properties": { - "url": { - "type": "string" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - }, - "id": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/hooks/1", - "updated_at": "2011-09-06T20:39:23Z", - "created_at": "2011-09-06T17:26:27Z", - "name": "web", - "events": [ - "push", - "pull_request" - ], - "active": true, - "config": { - "url": "http://example.com", - "content_type": "json" - }, - "id": 1 - } - ] - post: - description: Create a hook. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "config": { - "description": "A Hash containing key/value pairs to provide settings for this hook. Modifying this will replace the entire config object. These settings vary between the services and are defined in the github-services repo. Booleans are stored internally as \"1\" for true, and \"0\" for false. Any JSON true/false values will be converted automatically.", - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "add_events": [ - { - "description": "Determines a list of events to be added to the list of events that the Hook triggers for.", - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "remove_events": [ - { - "description": "Determines a list of events to be removed from the list of events that the Hook triggers for.", - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "description": "Determines whether the hook is actually triggered on pushes.", - "type": "boolean" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "type": "boolean" - }, - "config": { - "properties": { - "url": { - "type": "string" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - }, - "id": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/hooks/1", - "updated_at": "2011-09-06T20:39:23Z", - "created_at": "2011-09-06T17:26:27Z", - "name": "web", - "events": [ - "push", - "pull_request" - ], - "active": true, - "config": { - "url": "http://example.com", - "content_type": "json" - }, - "id": 1 - } - ] - /{hookId}: - uriParameters: - hookId: - description: Id of the hook. - type: integer - type: item - get: - description: Get single hook. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "type": "boolean" - }, - "config": { - "properties": { - "url": { - "type": "string" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - }, - "id": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/hooks/1", - "updated_at": "2011-09-06T20:39:23Z", - "created_at": "2011-09-06T17:26:27Z", - "name": "web", - "events": [ - "push", - "pull_request" - ], - "active": true, - "config": { - "url": "http://example.com", - "content_type": "json" - }, - "id": 1 - } - ] - patch: - description: Edit a hook. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "config": { - "description": "A Hash containing key/value pairs to provide settings for this hook. Modifying this will replace the entire config object. These settings vary between the services and are defined in the github-services repo. Booleans are stored internally as \"1\" for true, and \"0\" for false. Any JSON true/false values will be converted automatically.", - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "add_events": [ - { - "description": "Determines a list of events to be added to the list of events that the Hook triggers for.", - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "remove_events": [ - { - "description": "Determines a list of events to be removed from the list of events that the Hook triggers for.", - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "description": "Determines whether the hook is actually triggered on pushes.", - "type": "boolean" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "name": { - "type": "string" - }, - "events": [ - { - "enum": [ - "push", - "issues", - "issue_comment", - "commit_comment", - "pull_request", - "pull_request_review_comment", - "gollum", - "watch", - "download", - "fork", - "fork_apply", - "member", - "public", - "team_add", - "status" - ] - } - ], - "type": "array", - "active": { - "type": "boolean" - }, - "config": { - "properties": { - "url": { - "type": "string" - }, - "content_type": { - "type": "string" - } - }, - "type": "object" - }, - "id": { - "type": "integer" - } - } - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/hooks/1", - "updated_at": "2011-09-06T20:39:23Z", - "created_at": "2011-09-06T17:26:27Z", - "name": "web", - "events": [ - "push", - "pull_request" - ], - "active": true, - "config": { - "url": "http://example.com", - "content_type": "json" - }, - "id": 1 - } - ] - delete: - description: Delete a hook. - /tests: - type: base - post: - description: | - Test a push hook. - This will trigger the hook with the latest push to the current repository - if the hook is subscribed to push events. If the hook is not subscribed - to push events, the server will respond with 204 but no test POST will - be generated. - Note: Previously /repos/:owner/:repo/hooks/:id/test - responses: - 204: - description: Hook is triggered. - /merges: - type: base - post: - description: Perform a merge. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "base": { - "description": "The name of the base branch that the head will be merged into.", - "type": "string" - }, - "head": { - "description": "The head to merge. This can be a branch name or a commit SHA1.", - "type": "string" - }, - "commit_message": { - "description": "Commit message to use for the merge commit. If omitted, a default message will be used.", - "type": "string" - } - }, - "required": [ "base", "head" ] - } - responses: - 201: - description: Successful Response (The resulting merge commit) - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "sha": { - "type": "string" - }, - "commit": { - "properties": { - "author": { - "properties": { - "name": { - "type": "string" - }, - "date": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "name": { - "type": "string" - }, - "date": { - "type": "string" - }, - "email": { - "type": "string" - } - }, - "type": "object" - }, - "message": { - "type": "string" - }, - "tree": { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "url": { - "type": "string" - }, - "comment_count": { - "type": "integer" - } - }, - "type": "object" - }, - "url": { - "type": "string" - }, - "comments_url": { - "type": "string" - }, - "author": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "followers_url": { - "type": "string" - }, - "following_url": { - "type": "string" - }, - "gists_url": { - "type": "string" - }, - "starred_url": { - "type": "string" - }, - "subscriptions_url": { - "type": "string" - }, - "organizations_url": { - "type": "string" - }, - "repos_url": { - "type": "string" - }, - "events_url": { - "type": "string" - }, - "received_events_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "committer": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "followers_url": { - "type": "string" - }, - "following_url": { - "type": "string" - }, - "gists_url": { - "type": "string" - }, - "starred_url": { - "type": "string" - }, - "subscriptions_url": { - "type": "string" - }, - "organizations_url": { - "type": "string" - }, - "repos_url": { - "type": "string" - }, - "events_url": { - "type": "string" - }, - "received_events_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "parents": [ - { - "properties": { - "sha": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array" - } - } - example: | - { - "sha": "6dcb09b5b57875f334f61aebed695e2e4193db5e", - "merged": true, - "message": "Pull Request successfully merged" - } - 204: - description: No-op response (base already contains the head, nothing to merge) - 409: - description: Merge conflict response. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "message": { - "description": "Error message", - "type": "string" - } - } - } - example: | - { - "message": "Merge Conflict" - } - 404: - description: Missing base response or missing head response - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "message": { - "description": "Error message", - "type": "string" - } - } - } - example: | - { - "message": "Base does not exist" - } - /statuses/{ref}: - type: collection - uriParameters: - ref: - description: | - Ref to list the statuses from. It can be a SHA, a branch name, or a tag name. - type: string - get: - description: List Statuses for a specific Ref. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "state": { - "type": "string" - }, - "target_url": { - "type": "string" - }, - "description": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "created_at": "2012-07-20T01:19:13Z", - "updated_at": "2012-07-20T01:19:13Z", - "state": "success", - "target_url": "https://ci.example.com/1000/output", - "description": "Build has completed successfully", - "id": 1, - "url": "https://api.github.com/repos/octocat/example/statuses/1", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - } - ] - post: - description: Create a Status. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "state": { - "enum": [ - "pending", "success", "error", "failure" - ] - }, - "target_url": { - "description": "Target url to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the ?source' of the Status.", - "type": "string" - }, - "description": { - "description": "Short description of the status", - "type": "string" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "state": { - "type": "string" - }, - "target_url": { - "type": "string" - }, - "description": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "created_at": "2012-07-20T01:19:13Z", - "updated_at": "2012-07-20T01:19:13Z", - "state": "success", - "target_url": "https://ci.example.com/1000/output", - "description": "Build has completed successfully", - "id": 1, - "url": "https://api.github.com/repos/octocat/example/statuses/1", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - } - ] - /stats: - /contributors: - type: collection - get: - description: Get contributors list with additions, deletions, and commit counts. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "author": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "total": { - "description": "The Total number of commits authored by the contributor.", - "type": "integer" - }, - "weeks": [ - { - "properties": { - "w": { - "description": "Start of the week.", - "type": "string" - }, - "a": { - "description": "Number of additions.", - "type": "integer" - }, - "d": { - "description": "Number of deletions.", - "type": "integer" - }, - "c": { - "description": "Number of commits.", - "type": "integer" - } - }, - "type": "object" - } - ], - "type": "array" - } - ] - } - example: | - [ - { - "author": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "total": 135, - "weeks": [ - { - "w": "1367712000", - "a": 6898, - "d": 77, - "c": 10 - } - ] - } - ] - /commit_activity: - type: collection - get: - description: | - Get the last year of commit activity data. - Returns the last year of commit activity grouped by week. The days array - is a group of commits per day, starting on Sunday. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "days": [ - { - "type": "integer" - } - ], - "type": "array", - "total": { - "type": "integer" - }, - "week": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "days": [ - 0, - 3, - 26, - 20, - 39, - 1, - 0 - ], - "total": 89, - "week": 1336280400 - } - ] - /code_frequency: - type: collection - get: - description: | - Get the number of additions and deletions per week. - Returns a weekly aggregate of the number of additions and deletions pushed - to a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "type": "integer" - } - ] - } - example: | - [ - [ - 1302998400, - 1124, - -435 - ] - ] - /participation: - type: collection - get: - description: Get the weekly commit count for the repo owner and everyone else. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "all": [ - { - "type": "integer" - } - ], - "type": "array", - "owner": [ - { - "type": "integer" - } - ], - "type": "array" - } - } - example: | - { - "all": [ - 11, - 21, - 15, - 2, - 8, - 1, - 8, - 23, - 17, - 21, - 11, - 10, - 33, - 91, - 38, - 34, - 22, - 23, - 32, - 3, - 43, - 87, - 71, - 18, - 13, - 5, - 13, - 16, - 66, - 27, - 12, - 45, - 110, - 117, - 13, - 8, - 18, - 9, - 19, - 26, - 39, - 12, - 20, - 31, - 46, - 91, - 45, - 10, - 24, - 9, - 29, - 7 - ], - "owner": [ - 3, - 2, - 3, - 0, - 2, - 0, - 5, - 14, - 7, - 9, - 1, - 5, - 0, - 48, - 19, - 2, - 0, - 1, - 10, - 2, - 23, - 40, - 35, - 8, - 8, - 2, - 10, - 6, - 30, - 0, - 2, - 9, - 53, - 104, - 3, - 3, - 10, - 4, - 7, - 11, - 21, - 4, - 4, - 22, - 26, - 63, - 11, - 2, - 14, - 1, - 10, - 3 - ] - } - /punch_card: - type: collection - get: - description: | - Get the number of commits per hour in each day. - Each array contains the day number, hour number, and number of commits - 0-6 Sunday - Saturday - 0-23 Hour of day - Number of commits - - For example, [2, 14, 25] indicates that there were 25 total commits, during - the 2.00pm hour on Tuesdays. All times are based on the time zone of - individual commits. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "": [ - { - "type": "integer" - } - ] - } - ] - } - example: | - [ - [ - 0, - 0, - 5 - ], - [ - 0, - 1, - 43 - ], - [ - 0, - 2, - 21 - ] - ] -/user: - type: item - get: - description: Get the authenticated user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "company": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "location": { - "type": "string" - }, - "email": { - "type": "string" - }, - "hireable": { - "type": "boolean" - }, - "bio": { - "type": "string" - }, - "public_repos": { - "type": "integer" - }, - "public_gists": { - "type": "integer" - }, - "followers": { - "type": "integer" - }, - "following": { - "type": "integer" - }, - "html_url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "type": { - "type": "string" - }, - "total_private_repos": { - "type": "integer" - }, - "owned_private_repos": { - "type": "integer" - }, - "private_gists": { - "type": "integer" - }, - "disk_usage": { - "type": "integer" - }, - "collaborators": { - "type": "integer" - }, - "plan": { - "properties": { - "name": { - "type": "string" - }, - "space": { - "type": "integer" - }, - "collaborators": { - "type": "integer" - }, - "private_repos": { - "type": "integer" - } - }, - "type": "object" - } - } - } - example: | - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "name": "monalisa octocat", - "company": "GitHub", - "blog": "https://github.com/blog", - "location": "San Francisco", - "email": "octocat@github.com", - "hireable": false, - "bio": "There once was...", - "public_repos": 2, - "public_gists": 1, - "followers": 20, - "following": 0, - "html_url": "https://github.com/octocat", - "created_at": "2008-01-14T04:33:35Z", - "type": "User", - "total_private_repos": 100, - "owned_private_repos": 100, - "private_gists": 81, - "disk_usage": 10000, - "collaborators": 8, - "plan": { - "name": "Medium", - "space": 400, - "collaborators": 10, - "private_repos": 20 - } - } - patch: - description: Update the authenticated user. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "email": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "company": { - "type": "string" - }, - "location": { - "type": "string" - }, - "hireable": { - "type": "boolean" - }, - "bio": { - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "company": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "location": { - "type": "string" - }, - "email": { - "type": "string" - }, - "hireable": { - "type": "boolean" - }, - "bio": { - "type": "string" - }, - "public_repos": { - "type": "integer" - }, - "public_gists": { - "type": "integer" - }, - "followers": { - "type": "integer" - }, - "following": { - "type": "integer" - }, - "html_url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "type": { - "type": "string" - }, - "total_private_repos": { - "type": "integer" - }, - "owned_private_repos": { - "type": "integer" - }, - "private_gists": { - "type": "integer" - }, - "disk_usage": { - "type": "integer" - }, - "collaborators": { - "type": "integer" - }, - "plan": { - "properties": { - "name": { - "type": "string" - }, - "space": { - "type": "integer" - }, - "collaborators": { - "type": "integer" - }, - "private_repos": { - "type": "integer" - } - }, - "type": "object" - } - } - } - example: | - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "name": "monalisa octocat", - "company": "GitHub", - "blog": "https://github.com/blog", - "location": "San Francisco", - "email": "octocat@github.com", - "hireable": false, - "bio": "There once was...", - "public_repos": 2, - "public_gists": 1, - "followers": 20, - "following": 0, - "html_url": "https://github.com/octocat", - "created_at": "2008-01-14T04:33:35Z", - "type": "User", - "total_private_repos": 100, - "owned_private_repos": 100, - "private_gists": 81, - "disk_usage": 10000, - "collaborators": 8, - "plan": { - "name": "Medium", - "space": 400, - "collaborators": 10, - "private_repos": 20 - } - } - /orgs: - type: collection - get: - description: List public and private organizations for the authenticated user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "avatar_url": { - "type": "string" - } - } - ] - } - example: | - [ - { - "login": "github", - "id": 1, - "url": "https://api.github.com/orgs/github", - "avatar_url": "https://github.com/images/error/octocat_happy.gif" - } - ] - # Other - /{userId}: - type: collection - uriParameters: - userId: - type: integer - get: - securedBy: [ oauth_2_0, null ] - description: Get a single user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "company": { - "type": "string" - }, - "blog": { - "type": "string" - }, - "location": { - "type": "string" - }, - "email": { - "description": "Note: The returned email is the user's publicly visible email address (or null if the user has not specified a public email address in their profile).", - "type": "string" - }, - "hireable": { - "type": "boolean" - }, - "bio": { - "type": "string" - }, - "public_repos": { - "type": "integer" - }, - "public_gists": { - "type": "integer" - }, - "followers": { - "type": "integer" - }, - "following": { - "type": "integer" - }, - "html_url": { - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "type": { - "type": "string" - } - } - } - example: | - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat", - "name": "monalisa octocat", - "company": "GitHub", - "blog": "https://github.com/blog", - "location": "San Francisco", - "email": "octocat@github.com", - "hireable": false, - "bio": "There once was...", - "public_repos": 2, - "public_gists": 1, - "followers": 20, - "following": 0, - "html_url": "https://github.com/octocat", - "created_at": "2008-01-14T04:33:35Z", - "type": "User" - } - # Received events - /received_events: - type: collection - get: - description: List events that a user has received. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - /public: - type: collection - get: - description: List public events that a user has received. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - # Orgs - /orgs: - type: collection - get: - description: List all public organizations for a user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "avatar_url": { - "type": "string" - } - } - ] - } - example: | - [ - { - "login": "github", - "id": 1, - "url": "https://api.github.com/orgs/github", - "avatar_url": "https://github.com/images/error/octocat_happy.gif" - } - ] - /events: - type: collection - get: - description: | - List events performed by a user. - If you are authenticated as the given user, you will see your private events. - Otherwise, you'll only see public events. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - # Public - /public: - type: collection - get: - description: List public events performed by a user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - # Orgs events - /orgs/{orgId}: - uriParameters: - orgId: - type: integer - type: collection - get: - description: List events for an organization. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] - /starred: - type: collection - get: - description: List repositories being starred. - queryParameters: - sort: - enum: - - created - - updated - default: created - direction: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - /subscriptions: - type: collection - get: - description: List repositories being watched by a user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "integer" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - /emails: - type: collection - get: - description: | - List email addresses for a user. - In the final version of the API, this method will return an array of hashes - with extended information for each email address indicating if the address - has been verified and if it's the user's primary email address for GitHub. - Until API v3 is finalized, use the application/vnd.github.v3 media type to - get other response format. - responses: - 200: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "type": "string" - } - ] - } - example: | - [ - "octocat@github.com", - "support@github.com" - ] - application/vnd.github.v3: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "properties": { - "email": { - "type": "string" - }, - "verified": { - "type": "boolean" - }, - "primary": { - "type": "boolean" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "email": "octocat@github.com", - "verified": true, - "primary": true - } - ] - post: - description: | - Add email address(es). - You can post a single email address or an array of addresses. - delete: - description: | - Delete email address(es). - You can include a single email address or an array of addresses. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "type": "string" - } - ] - } - /following: - type: collection - get: - description: List who the authenticated user is following. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{userId}: - uriParameters: - userId: - type: integer - type: base - get: - description: Check if you are following a user. - responses: - 204: - description: Response if you are following this user. - 404: - description: Response if you are not following this user. - put: - description: | - Follow a user. - Following a user requires the user to be logged in and authenticated with - basic auth or OAuth with the user:follow scope. - responses: - 204: - description: You are now following the user. - delete: - description: | - Unfollow a user. - Unfollowing a user requires the user to be logged in and authenticated with - basic auth or OAuth with the user:follow scope. - responses: - 204: - description: User unfollowed. - /keys: - type: collection - get: - description: | - List your public keys. - Lists the current user's keys. Management of public keys via the API requires - that you are authenticated through basic auth, or OAuth with the 'user' scope. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - ] - post: - description: Create a public key. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "key": { - "type": "string" - } - } - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - /{keyId}: - uriParameters: - keyId: - type: integer - type: item - get: - description: Get a single public key. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - patch: - description: Update a public key. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "title": { - "type": "string" - }, - "key": { - "type": "string" - } - } - } - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - }, - "url": { - "type": "string" - }, - "title": { - "type": "string" - } - } - } - example: | - { - "id": 1, - "key": "ssh-rsa AAA...", - "url": "https://api.github.com/user/keys/1", - "title": "octocat@octomac" - } - delete: - description: Delete a public key. - /starred: - type: collection - get: - description: List repositories being starred by the authenticated user. - queryParameters: - sort: - enum: - - created - - updated - default: created - direction: - enum: - - asc - - desc - default: desc - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - /{ownerId}/{repoId}: - type: base - get: - description: Check if you are starring a repository. - responses: - 204: - description: This repository is starred by you. - 404: - description: This repository is not starred by you. - put: - description: Star a repository. - responses: - 204: - description: Repository starred. - delete: - description: Unstar a repository - responses: - 204: - description: Unstarred. - /subscriptions: - type: collection - get: - description: List repositories being watched by the authenticated user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "integer" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": false, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - /{ownerId}/{repoId}: - type: base - uriParameters: - ownerId: - description: Id of the owner. - type: integer - repoId: - description: Id of repository. - type: integer - get: - description: Check if you are watching a repository. - responses: - 204: - description: Repository is watched by you. - 404: - description: Repository is not watched by you. - put: - description: Watch a repository. - responses: - 204: - description: Repository is watched. - delete: - description: Stop watching a repository - responses: - 204: - description: Unwatched. - /issues: - type: collection - get: - is: [ filterable ] - description: | - List issues. - List all issues across owned and member repositories for the authenticated - user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "issues": [ - { - "properties": { - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "body": { - "type": "string" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "labels": [ - { - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - }, - "color": { - "type": "string" - } - }, - "type": "object" - } - ], - "type": "array", - "assignee": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "milestone": { - "properties": { - "url": { - "type": "string" - }, - "number": { - "type": "integer" - }, - "state": { - "enum": [ - "open", - "closed" - ] - }, - "title": { - "type": "string" - }, - "description": { - "type": "string" - }, - "creator": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "open_issues": { - "type": "integer" - }, - "closed_issues": { - "type": "integer" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "due_on": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "pull_request": { - "properties": { - "html_url": { - "type": "string" - }, - "diff_url": { - "type": "string" - }, - "patch_url": { - "type": "string" - } - }, - "type": "object" - }, - "closed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/issues/1347", - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "number": 1347, - "state": "open", - "title": "Found a bug", - "body": "I'm having a problem with this.", - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "labels": [ - { - "url": "https://api.github.com/repos/octocat/Hello-World/labels/bug", - "name": "bug", - "color": "f29513" - } - ], - "assignee": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "milestone": { - "url": "https://api.github.com/repos/octocat/Hello-World/milestones/1", - "number": 1, - "state": "open", - "title": "v1.0", - "description": "", - "creator": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "open_issues": 4, - "closed_issues": 8, - "created_at": "2011-04-10T20:09:31Z", - "due_on": null - }, - "comments": 0, - "pull_request": { - "html_url": "https://github.com/octocat/Hello-World/issues/1347", - "diff_url": "https://github.com/octocat/Hello-World/issues/1347.diff", - "patch_url": "https://github.com/octocat/Hello-World/issues/1347.patch" - }, - "closed_at": null, - "created_at": "2011-04-22T13:33:48Z", - "updated_at": "2011-04-22T13:33:48Z" - } - ] - /repos: - type: collection - get: - description: | - List repositories for the authenticated user. Note that this does not include - repositories owned by organizations which the user can access. You can list - user organizations and list organization repositories separately. - queryParameters: - type: - enum: - - all - - public - - private - - forks - - sources - - member - default: all - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] - post: - description: | - Create a new repository for the authenticated user. OAuth users must supply - repo scope. - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "private": { - "description": "True to create a private repository, false to create a public one. Creating private repositories requires a paid GitHub account.", - "type": "boolean" - }, - "has_issues": { - "description": "True to enable issues for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "has_wiki": { - "description": "True to enable the wiki for this repository, false to disable it. Default is true.", - "type": "boolean" - }, - "has_downloads": { - "description": "True to enable downloads for this repository, false to disable them. Default is true.", - "type": "boolean" - }, - "team_id": { - "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repo in an organization.", - "type": "integer" - }, - "auto_init": { - "description": "True to create an initial commit with empty README. Default is false.", - "type": "boolean" - }, - "gitignore_template": { - "description": "Desired language or platform .gitignore template to apply. Use the name of the template without the extension. For example, \"Haskell\" Ignored if auto_init parameter is not provided. ", - "type": "string" - } - }, - "required": [ "name" ] - } - responses: - 201: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] -/users: - type: collection - get: - description: | - Get all users. - This provides a dump of every user, in the order that they signed up for GitHub. - Note: Pagination is powered exclusively by the since parameter. Use the Link - header to get the URL for the next page of users. - queryParameters: - since: - description: The integer ID of the last User that you've seen. - type: integer - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - /{userId}: - uriParameters: - userId: - type: integer - type: collection - get: - description: List a user's followers. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "list": [ - { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - } - ] - # Followers - /following/{targetUserId}: - uriParameters: - targetUserId: - type: integer - type: base - get: - description: Check if one user follows another. - responses: - 204: - description: Response if user follows target user. - 404: - description: Response if user does not follow target user. - # Keys - /keys: - type: collection - get: - description: | - List public keys for a user. - Lists the verified public keys for a user. This is accessible by anyone. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "id": { - "type": "integer" - }, - "key": { - "type": "string" - } - } - ] - } - example: | - [ - { - "id": 1, - "key": "ssh-rsa AAA..." - } - ] - # Gists - /gists: - type: collection - get: - securedBy: [ null, oauth_2_0 ] - description: List a user's gists. - queryParameters: - since: - description: | - Timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. - Only gists updated at or after this time are returned. - type: string - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "gists": [ - { - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "id": { - "type": "string" - }, - "description": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "user": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "files": { - "properties": { - "ring.erl": { - "properties": { - "size": { - "type": "integer" - }, - "filename": { - "type": "string" - }, - "raw_url": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "comments": { - "type": "integer" - }, - "comments_url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "git_pull_url": { - "type": "string" - }, - "git_push_url": { - "type": "string" - }, - "created_at": { - "type": "string" - } - } - } - ] - } - example: | - [ - { - "url": "https://api.github.com/gists/20c98223d9b59e1d48e5", - "id": "1", - "description": "description of gist", - "public": true, - "user": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "files": { - "ring.erl": { - "size": 932, - "filename": "ring.erl", - "raw_url": "https://gist.github.com/raw/365370/8c4d2d43d178df44f4c03a7f2ac0ff512853564e/ring.erl" - } - }, - "comments": 0, - "comments_url": "https://api.github.com/gists/19d18b30e8af75090307/comments/", - "html_url": "https://gist.github.com/1", - "git_pull_url": "git://gist.github.com/1.git", - "git_push_url": "git@gist.github.com:1.git", - "created_at": "2010-04-14T02:15:15Z" - } - ] - /orgs: - type: collection - get: - description: List all public organizations for a user. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "avatar_url": { - "type": "string" - } - } - ] - } - example: | - [ - { - "login": "github", - "id": 1, - "url": "https://api.github.com/orgs/github", - "avatar_url": "https://github.com/images/error/octocat_happy.gif" - } - ] - /repos: - type: collection - get: - description: List public repositories for the specified user. - queryParameters: - type: - enum: - - all - - public - - private - - forks - - sources - - member - default: all - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "": [ - { - "properties": { - "id": { - "type": "integer" - }, - "owner": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "full_name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "private": { - "type": "boolean" - }, - "fork": { - "type": "boolean" - }, - "url": { - "type": "string" - }, - "html_url": { - "type": "string" - }, - "clone_url": { - "type": "string" - }, - "git_url": { - "type": "string" - }, - "ssh_url": { - "type": "string" - }, - "svn_url": { - "type": "string" - }, - "mirror_url": { - "type": "string" - }, - "homepage": { - "type": "string" - }, - "language": { - "type": "string" - }, - "forks": { - "type": "integer" - }, - "forks_count": { - "type": "integer" - }, - "watchers": { - "type": "integer" - }, - "watchers_count": { - "type": "integer" - }, - "size": { - "type": "integer" - }, - "master_branch": { - "type": "string" - }, - "open_issues": { - "type": "integer" - }, - "open_issues_count": { - "type": "integer" - }, - "pushed_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "created_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - }, - "updated_at": { - "description": "ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ", - "type": "string" - } - }, - "type": "object" - } - ] - } - } - example: | - [ - { - "id": 1296269, - "owner": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "name": "Hello-World", - "full_name": "octocat/Hello-World", - "description": "This your first repo!", - "private": false, - "fork": true, - "url": "https://api.github.com/repos/octocat/Hello-World", - "html_url": "https://github.com/octocat/Hello-World", - "clone_url": "https://github.com/octocat/Hello-World.git", - "git_url": "git://github.com/octocat/Hello-World.git", - "ssh_url": "git@github.com:octocat/Hello-World.git", - "svn_url": "https://svn.github.com/octocat/Hello-World", - "mirror_url": "git://git.example.com/octocat/Hello-World", - "homepage": "https://github.com", - "language": null, - "forks": 9, - "forks_count": 9, - "watchers": 80, - "watchers_count": 80, - "size": 108, - "master_branch": "master", - "open_issues": 0, - "open_issues_count": 0, - "pushed_at": "2011-01-26T19:06:43Z", - "created_at": "2011-01-26T19:01:12Z", - "updated_at": "2011-01-26T19:14:43Z" - } - ] -/gitignore/templates: - type: collection - get: - description: | - Listing available templates. - List all templates available to pass as an option when creating a repository. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "": [ - { - "type": "string" - } - ] - } - example: | - [ - "Actionscript", - "Android", - "AppceleratorTitanium", - "Autotools", - "Bancha", - "C", - "C " - ] - /{language}: - type: item - uriParameters: - language: - type: string - get: - description: Get a single template. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "source": { - "type": "string" - } - } - } - example: | - { - "name": "C", - "source": "# Object files\n*.o\n\n# Libraries\n*.lib\n*.a\n\n# Shared objects (inc. Windows DLLs)\n*.dll\n*.so\n*.so.*\n*.dylib\n\n# Executables\n*.exe\n*.out\n*.app\n" - } -/markdown: - type: base - post: - body: - application/json: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "object", - "properties": { - "text": { - "description": "The Markdown text to render", - "type": "string" - }, - "mode": { - "enum": [ - "markdown", - "gfm" - ] - }, - "context": { - "description": "The repository context, only taken into account when rendering as gfm.", - "type": "string" - } - }, - "required": [ - "text" - ] - } - responses: - 200: - body: - text/html: - example: | -

Hello world github/linguist#1 cool, and #1!

- /raw: - type: base - post: - body: - text/plain: - example: | -

Hello world github/linguist#1 cool, and #1!

- responses: - 200: - body: - text/html: - example: | -

Hello world github/linguist#1 cool, and #1!

-/networks/{ownerId}/{repoId}/events: - type: collection - uriParameters: - ownerId: - description: Id of the owner. - type: integer - repoId: - description: Id of repository. - type: integer - get: - description: List public events for a network of repositories. - responses: - 200: - body: - schema: | - { - "$schema": "http://json-schema.org/draft-03/schema", - "type": "array", - "properties": [ - { - "properties": { - "type": { - "type": "string" - }, - "public": { - "type": "boolean" - }, - "payload": { - "properties": {}, - "type": "object" - }, - "repo": { - "properties": { - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "actor": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "org": { - "properties": { - "login": { - "type": "string" - }, - "id": { - "type": "integer" - }, - "avatar_url": { - "type": "string" - }, - "gravatar_id": { - "type": "string" - }, - "url": { - "type": "string" - } - }, - "type": "object" - }, - "created_at": { - "type": "timestamp" - }, - "id": { - "type": "integer" - } - }, - "type": "object" - } - ] - } - example: | - [ - { - "type": "Event", - "public": true, - "payload": { - - }, - "repo": { - "id": 3, - "name": "octocat/Hello-World", - "url": "https://api.github.com/repos/octocat/Hello-World" - }, - "actor": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "org": { - "login": "octocat", - "id": 1, - "avatar_url": "https://github.com/images/error/octocat_happy.gif", - "gravatar_id": "somehexcode", - "url": "https://api.github.com/users/octocat" - }, - "created_at": "2011-09-06T17:26:27Z", - "id": "12345" - } - ] \ No newline at end of file diff --git a/examples/helloworld.raml b/examples/helloworld.raml new file mode 100644 index 00000000..0abaad3a --- /dev/null +++ b/examples/helloworld.raml @@ -0,0 +1,68 @@ +#%RAML 1.0 +title: Hello world # required title +version: 1 +baseUri: http://example.com/{version} +documentation: + - title: Welcome + content: | + Welcome to the Example Documentation. The Example API allows you + to do stuff. See also [example.com](https://www.example.com). + - title: Chapter two + content: | + More content here. Including **bold** text! + +/helloworld: # optional resource + description: This is the top level description for /helloworld. + + get: # HTTP method declaration + responses: # declare a response + 200: # HTTP status code + body: # declare content of response + application/json: # media type + type: | # structural definition of a response (schema or type) + { + "title": "Hello world Response", + "type": "object", + "properties": { + "message": { + "type": "string" + } + } + } + example: # example how a response looks like + { + "message": "Hello world" + } + /test: + displayName: TEST + get: + description: a sub resource + + /{id}: + uriParameters: + id: + type: string + description: account identifier + minLength: 1 + maxLength: 10 + + get: + headers: + Authorization: + type: string + description: Basic authentication header + example: | + Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ== + + put: + body: + application/x-www-form-urlencoded: + properties: + name: + description: name on account + type: string + examples: + example1: Naruto Uzumaki + example2: Kevin Renskers + gender: + enum: ["male", "female"] diff --git a/examples/script.js b/examples/script.js new file mode 100644 index 00000000..c4d04f14 --- /dev/null +++ b/examples/script.js @@ -0,0 +1,126 @@ +#!/usr/bin/env node + +'use strict'; + +/* + Example of using raml2html as a script. + Run this as `node script.js` + */ + +const raml2html = require('..'); +const path = require('path'); +const ramlFile = path.join(__dirname, 'helloworld.raml'); + +/** + * Using the default templates. + * + * raml2html.render() needs a config object with at least a `processRamlObj` property. + * Instead of creating this config object ourselves, we can just ask for raml2html.getDefaultConfig(): + */ +const config1 = raml2html.getConfigForTheme('raml2html-default-theme'); + +raml2html.render(ramlFile, config1).then( + result => { + console.log('1: ', result.length); + }, + error => { + console.log('error! ', error); + } +); + +/** + * Using your own templates using the default processRamlObj function. + */ +const config2 = raml2html.getConfigForTemplate( + './custom-template-test/template.nunjucks' +); + +raml2html.render(ramlFile, config2).then( + result => { + console.log('2: ', result.trim().length); + }, + error => { + console.log('error! ', error); + } +); + +/** + * If you want to customize everything, just create the config object yourself from scratch. + * + * The important thing is to have a processRamlObj property: a function that takes a raw RAML object and returns + * a promise with the finished output + */ +const config3 = { + processRamlObj() { + return new Promise(resolve => { + resolve('

\n\n\nHi!

'); + }); + }, + + postProcessHtml: config1.postProcessHtml, +}; + +raml2html.render(ramlFile, config3).then( + result => { + console.log('3: ', result.length); + }, + error => { + console.log('error! ', error); + } +); + +/** + * You can also customize the postProcessHtml function. + */ +const config4 = { + processRamlObj() { + return new Promise(resolve => { + resolve('

Hi!

'); + }); + }, + + postProcessHtml() { + return new Promise(resolve => { + resolve('ABC'); + }); + }, +}; + +raml2html.render(ramlFile, config4).then( + result => { + console.log('4: ', result.length); + }, + error => { + console.log('error! ', error); + } +); + +/** + * Testing if it works with no config at all. It outputs a JSON version of the RAML file. + */ +raml2html.render(ramlFile, {}).then( + result => { + console.log('5: ', Object.keys(result).length); + }, + error => { + console.log('error! ', error); + } +); + +/** + * If you want to only customize the Nunjucks configuration, just add a setupNunjucks function to the default config. + */ +const config6 = raml2html.getConfigForTheme('raml2html-default-theme'); +config6.setupNunjucks = function(env) { + // Do stuff with env here + env.bla = 'bla'; +}; + +raml2html.render(ramlFile, config6).then( + result => { + console.log('6: ', result.length); + }, + error => { + console.log('error! ', error); + } +); diff --git a/index.js b/index.js new file mode 100644 index 00000000..c400b812 --- /dev/null +++ b/index.js @@ -0,0 +1,171 @@ +'use strict'; + +const raml2obj = require('raml2obj'); +const pjson = require('./package.json'); +const nunjucks = require('nunjucks'); +const markdown = require('nunjucks-markdown'); +const marked = require('marked'); +const Minimize = require('minimize'); +const pretty = require('pretty'); +const path = require('path'); +const fs = require('fs'); + +/** + * Render the source RAML object using the config's processOutput function + * + * The config object should contain at least the following property: + * processRamlObj: function that takes the raw RAML object and returns a promise with the rendered HTML + * + * @param {(String|Object)} source - The source RAML file. Can be a filename, url, or an already-parsed RAML object. + * @param {Object} config + * @param {Object} options + * @param {Function} config.processRamlObj + * @returns a promise + */ +function render(source, config, options) { + config = config || {}; + config.raml2HtmlVersion = pjson.version; + + // Check if option is old boolean `validation` to keep backward compatibility + if (typeof options === 'boolean') { + options = { + validate: options, + }; + } + + if (options === undefined) { + options = { + validate: false, + }; + } + + return raml2obj + .parse(source, { + validate: options.validate, + extensionsAndOverlays: options.extensionsAndOverlays, + httpResolver: options.httpResolver, + fsResolver: options.fsResolver, + }) + .then(ramlObj => { + if (config.processRamlObj) { + return config.processRamlObj(ramlObj, config, options).then(html => { + if (config.postProcessHtml) { + return config.postProcessHtml(html, config, options); + } + return html; + }); + } + + return ramlObj; + }); +} + +/** + * @param {String} [mainTemplate] - The filename of the main template, leave empty to use default templates + * @returns {{processRamlObj: Function, postProcessHtml: Function}} + */ +function getConfigForTemplate(mainTemplate) { + const templatesPath = path.dirname(fs.realpathSync(mainTemplate)); + const templateFile = path.basename(fs.realpathSync(mainTemplate)); + + return { + processRamlObj(ramlObj, config, options) { + // Extend ramlObj with config and options so the templates can use those values + ramlObj.config = config; + ramlObj.options = options; + + const renderer = new marked.Renderer(); + renderer.table = function(thead, tbody) { + // Render Bootstrap style tables + return `${thead}${tbody}
`; + }; + + // Setup the Nunjucks environment with the markdown parser + const env = nunjucks.configure(templatesPath, { autoescape: false }); + + if (config.setupNunjucks) { + config.setupNunjucks(env); + } + + markdown.register(env, md => marked(md, { renderer })); + + ramlObj.isStandardType = function(type) { + if (typeof type === 'object') { + return false; + } + return type && type.indexOf('{') === -1 && type.indexOf('<') === -1; + }; + + // Render the main template using the raml object and fix the double quotes + let html = env.render(templateFile, ramlObj); + html = html.replace(/"/g, '"'); + + // Return the promise with the html + return new Promise(resolve => { + resolve(html); + }); + }, + + postProcessHtml(html, config, options) { + if (options.pretty) { + return pretty(html, { ocd: true }); + } else { + // Minimize the generated html and return the promise with the result + const minimize = new Minimize({ quotes: true }); + + return new Promise((resolve, reject) => { + minimize.parse(html, (error, result) => { + if (error) { + reject(new Error(error)); + } else { + resolve(result); + } + }); + }); + } + }, + }; +} + +/** + * @param {String} [theme] - The name of a raml2html template, leave empty if you want to use the mainTemplate option + * @param {Object} [programArguments] - An object containing all program aruments + * @returns {{processRamlObj: Function, postProcessHtml: Function}} + */ +function getConfigForTheme(theme, programArguments) { + if (!theme) { + theme = 'raml2html-default-theme'; + } + + try { + // See if the theme supplies its own config object (or function that creates this object), and return it + const config = require(theme); + + // If it's a function then call it with the program arguments + if (typeof config === 'function') { + return config(programArguments); + } + + // Otherwise we assume it's a config object (default behavior) + return config; + } catch (err) { + // Nope, forward to getConfigForTemplate + const templatesPath = path.dirname( + require.resolve(`${theme}/package.json`) + ); + return getConfigForTemplate(path.join(templatesPath, 'index.nunjucks')); + } +} + +module.exports = { + getConfigForTemplate, + getConfigForTheme, + render, +}; + +if (require.main === module) { + console.error( + "This script is meant to be used as a library. You probably want to run bin/raml2html if you're looking for a CLI." + ); + process.exit(1); +} diff --git a/lib/raml2html.js b/lib/raml2html.js deleted file mode 100755 index 4df8161e..00000000 --- a/lib/raml2html.js +++ /dev/null @@ -1,133 +0,0 @@ -#!/usr/bin/env node - -'use strict'; - -var raml2obj = require('raml2obj'); -var handlebars = require('handlebars'); -var hljs = require('highlight.js'); -var marked = require('marked'); -var program = require('commander'); -var fs = require('fs'); -var pjson = require('../package.json'); - -function _markDownHelper(text) { - if (text && text.length) { - return new handlebars.SafeString(marked(text)); - } else { - return ''; - } -} - -function _highlightHelper(text) { - if (text && text.length) { - return new handlebars.SafeString(hljs.highlightAuto(text).value); - } else { - return ''; - } -} - -function _lockIconHelper(securedBy) { - if (securedBy && securedBy.length) { - var index = securedBy.indexOf(null); - if (index !== -1) { - securedBy.splice(index, 1); - } - - if (securedBy.length) { - return new handlebars.SafeString(' '); - } - } - - return ''; -} - -function _render(ramlObj, config, onSuccess) { - // Register handlebar helpers - for (var helperName in config.helpers) { - if (config.helpers.hasOwnProperty(helperName)) { - handlebars.registerHelper(helperName, config.helpers[helperName]); - } - } - - // Register handlebar partials - for (var partialName in config.partials) { - if (config.partials.hasOwnProperty(partialName)) { - handlebars.registerPartial(partialName, config.partials[partialName]); - } - } - - var result = config.template(ramlObj); - onSuccess(result); -} - -function parseWithConfig(source, config, onSuccess, onError) { - raml2obj.parse(source, function(ramlObj) { - ramlObj.config = config; - ramlObj.config.raml2HtmlVersion = pjson.version; - _render(ramlObj, config, onSuccess); - }, onError); -} - -function getDefaultConfig() { - var config = { - 'template': require('./template.handlebars'), - 'helpers': { - 'md': _markDownHelper, - 'highlight': _highlightHelper, - 'lock': _lockIconHelper - }, - 'partials': { - 'resource': require('./resource.handlebars') - } - }; - - marked.setOptions({ - highlight: _highlightHelper - }); - - return config; -} - -function parse(source, onSuccess, onError) { - parseWithConfig(source, getDefaultConfig(), onSuccess, onError); -} - - -if (require.main === module) { - program - .usage('[options] [RAML input file]') - .option('-i, --input [input]', 'RAML input file') - .option('-o, --output [output]', 'HTML output file') - .parse(process.argv); - - var input = program.input; - - if (!input) { - if (program.args.length !== 1) { - console.error('Error: You need to specify the RAML input file'); - program.help(); - process.exit(1); - } - - input = program.args[0]; - } - - // Start the parsing process - parse(input, function(result) { - if (program.output) { - fs.writeFileSync(program.output, result); - } else { - // Simply output to console - process.stdout.write(result); - process.exit(0); - } - }, function(error) { - console.log('Error parsing: ' + error); - process.exit(1); - }); -} - - -module.exports.parse = parse; -module.exports.parseWithConfig = parseWithConfig; -module.exports.getDefaultConfig = getDefaultConfig; diff --git a/lib/resource.handlebars b/lib/resource.handlebars deleted file mode 100644 index 3cffefc4..00000000 --- a/lib/resource.handlebars +++ /dev/null @@ -1,284 +0,0 @@ -
- -
- -
- - {{#methods}} - - {{/methods}} -
- -{{#resources}} - {{> resource}} -{{/resources}} diff --git a/lib/template.handlebars b/lib/template.handlebars deleted file mode 100644 index a490b78d..00000000 --- a/lib/template.handlebars +++ /dev/null @@ -1,160 +0,0 @@ - - - - Codestin Search App - - - - - - - - - - -
-
-
- - - {{#resources}} -
-
-

{{#if displayName}}{{displayName}}{{/if}}{{#unless displayName}}{{relativeUri}}{{/unless}}

-
- -
- {{#if description}} -
- {{md description}} -
- {{/if}} - -
- {{> resource}} -
-
-
- {{/resources}} -
- - -
-
- - diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..a7844781 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,2491 @@ +{ + "name": "raml2html", + "version": "7.7.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@babel/code-frame": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", + "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", + "dev": true, + "requires": { + "@babel/highlight": "^7.10.4" + } + }, + "@babel/helper-validator-identifier": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", + "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==", + "dev": true + }, + "@babel/highlight": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", + "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", + "dev": true, + "requires": { + "@babel/helper-validator-identifier": "^7.10.4", + "chalk": "^2.0.0", + "js-tokens": "^4.0.0" + } + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", + "dev": true + }, + "@types/commander": { + "version": "2.12.2", + "resolved": "https://registry.npmjs.org/@types/commander/-/commander-2.12.2.tgz", + "integrity": "sha512-0QEFiR8ljcHp9bAbWxecjVRuAMr16ivPiGOw6KFQBVrVd0RQIcM3xKdRisH2EDWgVWujiYtHwhSkSUoAAGzH7Q==", + "requires": { + "commander": "*" + } + }, + "@types/node": { + "version": "10.17.27", + "resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.27.tgz", + "integrity": "sha512-J0oqm9ZfAXaPdwNXMMgAhylw5fhmXkToJd06vuDUSAgEDZ/n/69/69UmyBZbc+zT34UnShuDSBqvim3SPnozJg==" + }, + "@types/semver": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/@types/semver/-/semver-5.5.0.tgz", + "integrity": "sha512-41qEJgBH/TWgo5NFSvBCJ1qkoi3Q6ONSF2avrHq1LVEZfYpdHmj0y9SuTK+u9ZhG1sYQKBL1AWXKyLWP4RaUoQ==" + }, + "a-sync-waterfall": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/a-sync-waterfall/-/a-sync-waterfall-1.0.1.tgz", + "integrity": "sha512-RYTOHHdWipFUliRFMCS4X2Yn2X8M87V/OpSqWzKKOGhzqyUxzyVmhHDH9sAvG+ZuQf/TAOFsLCpMw09I1ufUnA==" + }, + "abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" + }, + "acorn": { + "version": "7.3.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.3.1.tgz", + "integrity": "sha512-tLc0wSnatxAQHVHUapaHdz72pi9KUyHjq5KyHjGg9Y8Ifdc79pTh2XvI6I1/chZbnM7QtNKzh66ooDogPZSleA==", + "dev": true + }, + "acorn-jsx": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz", + "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==", + "dev": true + }, + "ajv": { + "version": "6.12.3", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz", + "integrity": "sha512-4K0cK3L1hsqk9xIb2z9vs/XU+PGJZ9PNpJRDS9YLzmNdX6jmVPfamLvTJr0aDAusnHyCHO6MjzlkAsgtqp9teA==", + "dev": true, + "requires": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + } + }, + "amdefine": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-0.0.8.tgz", + "integrity": "sha1-NNyMmB5qyzvhhTvvjw7JSjnVW6A=" + }, + "ansi-escapes": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.1.tgz", + "integrity": "sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA==", + "dev": true, + "requires": { + "type-fest": "^0.11.0" + }, + "dependencies": { + "type-fest": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.11.0.tgz", + "integrity": "sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ==", + "dev": true + } + } + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "requires": { + "color-convert": "^1.9.0" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "optional": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "argh": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/argh/-/argh-0.1.4.tgz", + "integrity": "sha1-PrTWEpc/xrbcbvM49W91nyrFw6Y=" + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "asap": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", + "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" + }, + "astral-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", + "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", + "dev": true + }, + "async": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/async/-/async-2.6.3.tgz", + "integrity": "sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==", + "requires": { + "lodash": "^4.17.14" + } + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "bignumber.js": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-9.0.0.tgz", + "integrity": "sha512-t/OYhhJ2SD+YGBQcjY8GzzDHEk9f3nerxjtfa6tlMXfe7frs/WozhvCNoGvpM0P3bNf3Gq5ZRMlGr5f3r4/N8A==" + }, + "binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "optional": true + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "optional": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true + }, + "camel-case": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/camel-case/-/camel-case-4.1.1.tgz", + "integrity": "sha512-7fa2WcG4fYFkclIvEmxBbTvmibwF2/agfEBc6q3lOpVu0A13ltLsA+Hr/8Hp6kp5f+G7hKi6t8lys6XxP+1K6Q==", + "requires": { + "pascal-case": "^3.1.1", + "tslib": "^1.10.0" + } + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" + }, + "capital-case": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/capital-case/-/capital-case-1.0.3.tgz", + "integrity": "sha512-OlUSJpUr7SY0uZFOxcwnDOU7/MpHlKTZx2mqnDYQFrDudXLFm0JJ9wr/l4csB+rh2Ug0OPuoSO53PqiZBqno9A==", + "requires": { + "no-case": "^3.0.3", + "tslib": "^1.10.0", + "upper-case-first": "^2.0.1" + } + }, + "chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + } + }, + "change-case": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/change-case/-/change-case-4.1.1.tgz", + "integrity": "sha512-qRlUWn/hXnX1R1LBDF/RelJLiqNjKjUqlmuBVSEIyye8kq49CXqkZWKmi8XeUAdDXWFOcGLUMZ+aHn3Q5lzUXw==", + "requires": { + "camel-case": "^4.1.1", + "capital-case": "^1.0.3", + "constant-case": "^3.0.3", + "dot-case": "^3.0.3", + "header-case": "^2.0.3", + "no-case": "^3.0.3", + "param-case": "^3.0.3", + "pascal-case": "^3.1.1", + "path-case": "^3.0.3", + "sentence-case": "^3.0.3", + "snake-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "chardet": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", + "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", + "dev": true + }, + "chokidar": { + "version": "3.5.1", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.1.tgz", + "integrity": "sha512-9+s+Od+W0VJJzawDma/gvBNQqkTiqYTWLuZoyAsivsI4AaWTCzHG06/TMjsf1cYe9Cb97UCEhjz7HvnPk2p/tw==", + "optional": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.3.1", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.5.0" + } + }, + "cli-color": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/cli-color/-/cli-color-1.4.0.tgz", + "integrity": "sha512-xu6RvQqqrWEo6MPR1eixqGPywhYBHRs653F9jfXB2Hx4jdM/3WxiNE1vppRmxtMIfl16SFYTpYlrnqH/HsK/2w==", + "requires": { + "ansi-regex": "^2.1.1", + "d": "1", + "es5-ext": "^0.10.46", + "es6-iterator": "^2.0.3", + "memoizee": "^0.4.14", + "timers-ext": "^0.1.5" + } + }, + "cli-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", + "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", + "dev": true, + "requires": { + "restore-cursor": "^3.1.0" + } + }, + "cli-width": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-3.0.0.tgz", + "integrity": "sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==", + "dev": true + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + } + } + }, + "color": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/color/-/color-3.0.0.tgz", + "integrity": "sha512-jCpd5+s0s0t7p3pHQKpnJ0TpQKKdleP71LWcA0aqiljpiuAkOSUFN/dyH8ZwF0hRmFlrIuRhufds1QyEP9EB+w==", + "requires": { + "color-convert": "^1.9.1", + "color-string": "^1.5.2" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" + }, + "color-string": { + "version": "1.5.3", + "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.5.3.tgz", + "integrity": "sha512-dC2C5qeWoYkxki5UAXapdjqO672AM4vZuPGRQfO8b5HKuKGBbKWpITyDYN7TOFKvRW7kOgAn3746clDBMDJyQw==", + "requires": { + "color-name": "^1.0.0", + "simple-swizzle": "^0.2.2" + } + }, + "colornames": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/colornames/-/colornames-1.1.1.tgz", + "integrity": "sha1-+IiQMGhcfE/54qVZ9Qd+t2qBb5Y=" + }, + "colorspace": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/colorspace/-/colorspace-1.1.2.tgz", + "integrity": "sha512-vt+OoIP2d76xLhjwbBaucYlNSpPsrJWPlBTtwCpQKIu6/CSMutyzX93O/Do0qzpH3YoHEes8YEFXyZ797rEhzQ==", + "requires": { + "color": "3.0.x", + "text-hex": "1.0.x" + } + }, + "commander": { + "version": "2.18.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.18.0.tgz", + "integrity": "sha512-6CYPa+JP2ftfRU2qkDK+UTVeQYosOg/2GbcjIcKPHfinyOLPVGXu/ovN86RP49Re5ndJK1N0kuiidFFuepc4ZQ==" + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "condense-newlines": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/condense-newlines/-/condense-newlines-0.2.1.tgz", + "integrity": "sha1-PemFVTE5R10yUCyDsC9gaE0kxV8=", + "requires": { + "extend-shallow": "^2.0.1", + "is-whitespace": "^0.3.0", + "kind-of": "^3.0.2" + } + }, + "config-chain": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/config-chain/-/config-chain-1.1.11.tgz", + "integrity": "sha1-q6CXR9++TD5w52am5BWG4YWfxvI=", + "requires": { + "ini": "^1.3.4", + "proto-list": "~1.2.1" + } + }, + "constant-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/constant-case/-/constant-case-3.0.3.tgz", + "integrity": "sha512-FXtsSnnrFYpzDmvwDGQW+l8XK3GV1coLyBN0eBz16ZUzGaZcT2ANVCJmLeuw2GQgxKHQIe9e0w2dzkSfaRlUmA==", + "requires": { + "no-case": "^3.0.3", + "tslib": "^1.10.0", + "upper-case": "^2.0.1" + } + }, + "cross-spawn": { + "version": "6.0.5", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", + "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "dev": true, + "requires": { + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" + } + }, + "d": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", + "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", + "requires": { + "es5-ext": "^0.10.50", + "type": "^1.0.1" + } + }, + "datatype-expansion": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/datatype-expansion/-/datatype-expansion-0.4.1.tgz", + "integrity": "sha512-KI80twJSPaoNJn6AsQStuL+4ipTKT4AtW+bAKEObQ5ZMqQM6Atzquh9Nu+hj488PQfKKAzuVodOrp7C7P+oItQ==", + "requires": { + "lodash": "^4.17.19" + } + }, + "date-and-time": { + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/date-and-time/-/date-and-time-0.11.1.tgz", + "integrity": "sha512-+1JkWME+UWRpCfvE1T0Vfbw629Ego0IcfHH0qtP4KhAXs7IJT2qsg1hNePqZhyD8Wby46HlW393lSL5PZSzDsA==" + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" + }, + "deep-is": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", + "dev": true + }, + "diagnostics": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/diagnostics/-/diagnostics-1.1.1.tgz", + "integrity": "sha512-8wn1PmdunLJ9Tqbx+Fx/ZEuHfJf4NKSN2ZBj7SJC/OWRWha843+WsTjqMe1B5E3p28jqBlp+mJ2fPVxPyNgYKQ==", + "requires": { + "colorspace": "1.1.x", + "enabled": "1.0.x", + "kuler": "1.0.x" + } + }, + "doctrine": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", + "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", + "dev": true, + "requires": { + "esutils": "^2.0.2" + } + }, + "dom-serializer": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.2.1.tgz", + "integrity": "sha512-sK3ujri04WyjwQXVoK4PU3y8ula1stq10GJZpqHIUgoGZdsGzAGu65BnU3d08aTVSvO7mGPZUc0wTEDL+qGE0Q==", + "requires": { + "domelementtype": "^2.0.1", + "entities": "^2.0.0" + }, + "dependencies": { + "domelementtype": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.0.1.tgz", + "integrity": "sha512-5HOHUDsYZWV8FGWN0Njbr/Rn7f/eWSQi1v7+HsUVwXgn8nWWlL64zKDkS0n8ZmQ3mlWOMuXOnR+7Nx/5tMO5AQ==" + }, + "entities": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.0.0.tgz", + "integrity": "sha512-D9f7V0JSRwIxlRI2mjMqufDrRDnx8p+eEOz7aUM9SuvF8gsBzra0/6tbjl1m8eQHrZlYj6PxqE00hZ1SAIKPLw==" + } + } + }, + "domelementtype": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz", + "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==" + }, + "domhandler": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz", + "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", + "requires": { + "domelementtype": "1" + } + }, + "domutils": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.7.0.tgz", + "integrity": "sha512-Lgd2XcJ/NjEw+7tFvfKxOzCYKZsdct5lczQ2ZaQY8Djz7pfAD3Gbp8ySJWtreII/vDlMVmxwa6pHmdxIYgttDg==", + "requires": { + "dom-serializer": "0", + "domelementtype": "1" + } + }, + "dot-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dot-case/-/dot-case-3.0.3.tgz", + "integrity": "sha512-7hwEmg6RiSQfm/GwPL4AAWXKy3YNNZA3oFv2Pdiey0mwkRCPZ9x6SZbkLcn8Ma5PYeVokzoD4Twv2n7LKp5WeA==", + "requires": { + "no-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "editorconfig": { + "version": "0.15.0", + "resolved": "https://registry.npmjs.org/editorconfig/-/editorconfig-0.15.0.tgz", + "integrity": "sha512-j7JBoj/bpNzvoTQylfRZSc85MlLNKWQiq5y6gwKhmqD2h1eZ+tH4AXbkhEJD468gjDna/XMx2YtSkCxBRX9OGg==", + "requires": { + "@types/commander": "^2.11.0", + "@types/semver": "^5.4.0", + "commander": "^2.11.0", + "lru-cache": "^4.1.1", + "semver": "^5.4.1", + "sigmund": "^1.0.1" + } + }, + "emits": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/emits/-/emits-3.0.0.tgz", + "integrity": "sha1-MnUrupXhcHshlWI4Srm7ix/WL3A=" + }, + "emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true + }, + "enabled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/enabled/-/enabled-1.0.2.tgz", + "integrity": "sha1-ll9lE9LC0cX0ZStkouM5ZGf8L5M=", + "requires": { + "env-variable": "0.0.x" + } + }, + "entities": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==" + }, + "env-variable": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/env-variable/-/env-variable-0.0.5.tgz", + "integrity": "sha512-zoB603vQReOFvTg5xMl9I1P2PnHsHQQKTEowsKKD7nseUfJq6UWzK+4YtlWUO1nhiQUxe6XMkk+JleSZD1NZFA==" + }, + "es5-ext": { + "version": "0.10.52", + "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.52.tgz", + "integrity": "sha512-bWCbE9fbpYQY4CU6hJbJ1vSz70EClMlDgJ7BmwI+zEJhxrwjesZRPglGJlsZhu0334U3hI+gaspwksH9IGD6ag==", + "requires": { + "es6-iterator": "~2.0.3", + "es6-symbol": "~3.1.2", + "next-tick": "~1.0.0" + } + }, + "es6-iterator": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/es6-iterator/-/es6-iterator-2.0.3.tgz", + "integrity": "sha1-p96IkUGgWpSwhUQDstCg+/qY87c=", + "requires": { + "d": "1", + "es5-ext": "^0.10.35", + "es6-symbol": "^3.1.1" + } + }, + "es6-symbol": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.3.tgz", + "integrity": "sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==", + "requires": { + "d": "^1.0.1", + "ext": "^1.1.2" + } + }, + "es6-weak-map": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/es6-weak-map/-/es6-weak-map-2.0.3.tgz", + "integrity": "sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA==", + "requires": { + "d": "1", + "es5-ext": "^0.10.46", + "es6-iterator": "^2.0.3", + "es6-symbol": "^3.1.1" + } + }, + "escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" + }, + "eslint": { + "version": "6.8.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-6.8.0.tgz", + "integrity": "sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.0.0", + "ajv": "^6.10.0", + "chalk": "^2.1.0", + "cross-spawn": "^6.0.5", + "debug": "^4.0.1", + "doctrine": "^3.0.0", + "eslint-scope": "^5.0.0", + "eslint-utils": "^1.4.3", + "eslint-visitor-keys": "^1.1.0", + "espree": "^6.1.2", + "esquery": "^1.0.1", + "esutils": "^2.0.2", + "file-entry-cache": "^5.0.1", + "functional-red-black-tree": "^1.0.1", + "glob-parent": "^5.0.0", + "globals": "^12.1.0", + "ignore": "^4.0.6", + "import-fresh": "^3.0.0", + "imurmurhash": "^0.1.4", + "inquirer": "^7.0.0", + "is-glob": "^4.0.0", + "js-yaml": "^3.13.1", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.3.0", + "lodash": "^4.17.14", + "minimatch": "^3.0.4", + "mkdirp": "^0.5.1", + "natural-compare": "^1.4.0", + "optionator": "^0.8.3", + "progress": "^2.0.0", + "regexpp": "^2.0.1", + "semver": "^6.1.2", + "strip-ansi": "^5.2.0", + "strip-json-comments": "^3.0.1", + "table": "^5.2.3", + "text-table": "^0.2.0", + "v8-compile-cache": "^2.0.3" + }, + "dependencies": { + "semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true + } + } + }, + "eslint-plugin-prettier": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.3.1.tgz", + "integrity": "sha512-Rq3jkcFY8RYeQLgk2cCwuc0P7SEFwDravPhsJZOQ5N4YI4DSg50NyqJ/9gdZHzQlHf8MvafSesbNJCcP/FF6pQ==", + "dev": true, + "requires": { + "prettier-linter-helpers": "^1.0.0" + } + }, + "eslint-scope": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.0.tgz", + "integrity": "sha512-iiGRvtxWqgtx5m8EyQUJihBloE4EnYeGE/bz1wSPwJE6tZuJUtHlhqDM4Xj2ukE8Dyy1+HCZ4hE0fzIVMzb58w==", + "dev": true, + "requires": { + "esrecurse": "^4.1.0", + "estraverse": "^4.1.1" + } + }, + "eslint-utils": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.4.3.tgz", + "integrity": "sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q==", + "dev": true, + "requires": { + "eslint-visitor-keys": "^1.1.0" + } + }, + "eslint-visitor-keys": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", + "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", + "dev": true + }, + "espree": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-6.2.1.tgz", + "integrity": "sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw==", + "dev": true, + "requires": { + "acorn": "^7.1.1", + "acorn-jsx": "^5.2.0", + "eslint-visitor-keys": "^1.1.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "esquery": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.3.1.tgz", + "integrity": "sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ==", + "dev": true, + "requires": { + "estraverse": "^5.1.0" + }, + "dependencies": { + "estraverse": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.1.0.tgz", + "integrity": "sha512-FyohXK+R0vE+y1nHLoBM7ZTyqRpqAlhdZHCWIWEviFLiGB8b04H6bQs8G+XTthacvT8VuwvteiP7RJSxMs8UEw==", + "dev": true + } + } + }, + "esrecurse": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", + "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==", + "dev": true, + "requires": { + "estraverse": "^4.1.0" + } + }, + "estraverse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", + "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "dev": true + }, + "esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true + }, + "event-emitter": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/event-emitter/-/event-emitter-0.3.5.tgz", + "integrity": "sha1-34xp7vFkeSPHFXuc6DhAYQsCzDk=", + "requires": { + "d": "1", + "es5-ext": "~0.10.14" + } + }, + "ext": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/ext/-/ext-1.1.2.tgz", + "integrity": "sha512-/KLjJdTNyDepCihrk4HQt57nAE1IRCEo5jUt+WgWGCr1oARhibDvmI2DMcSNWood1T9AUWwq+jaV1wvRqaXfnA==", + "requires": { + "type": "^2.0.0" + }, + "dependencies": { + "type": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/type/-/type-2.0.0.tgz", + "integrity": "sha512-KBt58xCHry4Cejnc2ISQAF7QY+ORngsWfxezO68+12hKV6lQY8P/psIkcbjeHWn7MqcgciWJyCCevFMJdIXpow==" + } + } + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "^0.1.0" + } + }, + "external-editor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", + "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", + "dev": true, + "requires": { + "chardet": "^0.7.0", + "iconv-lite": "^0.4.24", + "tmp": "^0.0.33" + } + }, + "fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "dev": true + }, + "fast-diff": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.2.0.tgz", + "integrity": "sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w==", + "dev": true + }, + "fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true + }, + "fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", + "dev": true + }, + "figures": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", + "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", + "dev": true, + "requires": { + "escape-string-regexp": "^1.0.5" + } + }, + "file-entry-cache": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz", + "integrity": "sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==", + "dev": true, + "requires": { + "flat-cache": "^2.0.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "optional": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "requires": { + "locate-path": "^3.0.0" + } + }, + "flat-cache": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz", + "integrity": "sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==", + "dev": true, + "requires": { + "flatted": "^2.0.0", + "rimraf": "2.6.3", + "write": "1.0.3" + } + }, + "flatted": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-2.0.2.tgz", + "integrity": "sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==", + "dev": true + }, + "fs-extra": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", + "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "requires": { + "graceful-fs": "^4.2.0", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" + }, + "dependencies": { + "graceful-fs": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", + "integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw==" + } + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.1.tgz", + "integrity": "sha512-YR47Eg4hChJGAB1O3yEAOkGO+rlzutoICGqGo9EZ4lKWokzZRSyIW1QmTzqjtw8MJdj9srP869CuWw/hyzSiBw==", + "optional": true + }, + "functional-red-black-tree": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", + "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "requires": { + "is-glob": "^4.0.1" + } + }, + "globals": { + "version": "12.4.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-12.4.0.tgz", + "integrity": "sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg==", + "dev": true, + "requires": { + "type-fest": "^0.8.1" + } + }, + "graceful-fs": { + "version": "4.1.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", + "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", + "optional": true + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" + }, + "header-case": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/header-case/-/header-case-2.0.3.tgz", + "integrity": "sha512-LChe/V32mnUQnTwTxd3aAlNMk8ia9tjCDb/LjYtoMrdAPApxLB+azejUk5ERZIZdIqvinwv6BAUuFXH/tQPdZA==", + "requires": { + "capital-case": "^1.0.3", + "tslib": "^1.10.0" + } + }, + "htmlparser2": { + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", + "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", + "requires": { + "domelementtype": "^1.3.1", + "domhandler": "^2.3.0", + "domutils": "^1.5.1", + "entities": "^1.1.1", + "inherits": "^2.0.1", + "readable-stream": "^3.1.1" + }, + "dependencies": { + "readable-stream": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.4.0.tgz", + "integrity": "sha512-jItXPLmrSR8jmTRmRWJXCnGJsfy85mB3Wd/uINMXA65yrnFo0cPClFIUWzo2najVNSl+mx7/4W8ttlLWJe99pQ==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + } + } + }, + "http-response-object": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/http-response-object/-/http-response-object-3.0.2.tgz", + "integrity": "sha512-bqX0XTF6fnXSQcEJ2Iuyr75yVakyjIDCqroJQ/aHfSdlM743Cwqoi2nDYMzLGWUcuTWGWy8AAvOKXTfiv6q9RA==", + "requires": { + "@types/node": "^10.0.3" + } + }, + "iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "dev": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3" + } + }, + "ignore": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", + "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", + "dev": true + }, + "import-fresh": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz", + "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==", + "dev": true, + "requires": { + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" + } + }, + "imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + }, + "ini": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", + "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==" + }, + "inquirer": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.3.2.tgz", + "integrity": "sha512-DF4osh1FM6l0RJc5YWYhSDB6TawiBRlbV9Cox8MWlidU218Tb7fm3lQTULyUJDfJ0tjbzl0W4q651mrCCEM55w==", + "dev": true, + "requires": { + "ansi-escapes": "^4.2.1", + "chalk": "^4.1.0", + "cli-cursor": "^3.1.0", + "cli-width": "^3.0.0", + "external-editor": "^3.0.3", + "figures": "^3.0.0", + "lodash": "^4.17.16", + "mute-stream": "0.0.8", + "run-async": "^2.4.0", + "rxjs": "^6.6.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0", + "through": "^2.3.6" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "dev": true, + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "dev": true, + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + } + } + }, + "invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "requires": { + "loose-envify": "^1.0.0" + } + }, + "is-arrayish": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", + "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "optional": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + }, + "is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "optional": true + }, + "is-promise": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.1.0.tgz", + "integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=" + }, + "is-whitespace": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/is-whitespace/-/is-whitespace-0.3.0.tgz", + "integrity": "sha1-Fjnssb4DauxppUy7QBz77XEUq38=" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "js-beautify": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/js-beautify/-/js-beautify-1.8.6.tgz", + "integrity": "sha512-TYDZa+lg8vEC5U0OmGQEEwiZ0XFBfvZAUeNOtqflLe+woKuIqF4JzlsBx/C1KVYW5lUewZy2ODL4Obq6sH7a4Q==", + "requires": { + "config-chain": "~1.1.5", + "editorconfig": "^0.15.0", + "mkdirp": "~0.5.0", + "nopt": "~4.0.1" + } + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" + }, + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "json-path": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/json-path/-/json-path-0.1.3.tgz", + "integrity": "sha1-3OYTV7OygbKKxkfsCnCbxYoVW/g=", + "requires": { + "json-ptr": "~0.1.1" + } + }, + "json-ptr": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/json-ptr/-/json-ptr-0.1.1.tgz", + "integrity": "sha1-urgqMeKSznr54/x/1lrNG7uSSOg=" + }, + "json-schema-compatibility": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/json-schema-compatibility/-/json-schema-compatibility-1.1.0.tgz", + "integrity": "sha1-GomBd4zaDDgYcpjZmdCJ5Rrygt8=" + }, + "json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true + }, + "json-stable-stringify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz", + "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=", + "requires": { + "jsonify": "~0.0.0" + } + }, + "json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", + "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", + "dev": true + }, + "json-to-ast": { + "version": "2.0.0-alpha1.3", + "resolved": "https://registry.npmjs.org/json-to-ast/-/json-to-ast-2.0.0-alpha1.3.tgz", + "integrity": "sha1-aQqngDXTp7ctUZPxtMCPm7DX4sg=" + }, + "jsonfile": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", + "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", + "requires": { + "graceful-fs": "^4.1.6" + } + }, + "jsonify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz", + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=" + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "^1.1.5" + } + }, + "know-your-http-well": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/know-your-http-well/-/know-your-http-well-0.5.0.tgz", + "integrity": "sha1-XQOQAxBHmanXf8KZjP1TlnWyVr4=", + "requires": { + "amdefine": "~0.0.4" + } + }, + "kuler": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/kuler/-/kuler-1.0.1.tgz", + "integrity": "sha512-J9nVUucG1p/skKul6DU3PUZrhs0LPulNaeUOox0IyXDi8S4CztTHs1gQphhuZmzXG7VOQSf6NJfKuzteQLv9gQ==", + "requires": { + "colornames": "^1.1.1" + } + }, + "levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "dev": true, + "requires": { + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "lodash": { + "version": "4.17.19", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", + "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==" + }, + "lodash.get": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/lodash.get/-/lodash.get-4.4.2.tgz", + "integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk=" + }, + "lodash.isequal": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz", + "integrity": "sha1-QVxEePK8wwEgwizhDtMib30+GOA=" + }, + "loophole": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/loophole/-/loophole-1.1.0.tgz", + "integrity": "sha1-N5Sf6kU7YlasxyXDIM4MWn9wor0=" + }, + "loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "lower-case": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/lower-case/-/lower-case-2.0.1.tgz", + "integrity": "sha512-LiWgfDLLb1dwbFQZsSglpRj+1ctGnayXz3Uv0/WO8n558JycT5fg6zkNcnW0G68Nn0aEldTFeEfmjCfmqry/rQ==", + "requires": { + "tslib": "^1.10.0" + } + }, + "lru-cache": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.3.tgz", + "integrity": "sha512-fFEhvcgzuIoJVUF8fYr5KR0YqxD238zgObTps31YdADwPPAp82a4M8TrckkWyx7ekNlf9aBcVn81cFwwXngrJA==", + "requires": { + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" + } + }, + "lru-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/lru-queue/-/lru-queue-0.1.0.tgz", + "integrity": "sha1-Jzi9nw089PhEkMVzbEhpmsYyzaM=", + "requires": { + "es5-ext": "~0.10.2" + } + }, + "lrucache": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/lrucache/-/lrucache-1.0.3.tgz", + "integrity": "sha1-Ox3tDRuoLhiLm9q6nu5khvhkpDQ=" + }, + "marked": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/marked/-/marked-1.2.7.tgz", + "integrity": "sha512-No11hFYcXr/zkBvL6qFmAp1z6BKY3zqLMHny/JN/ey+al7qwCM2+CMBL9BOgqMxZU36fz4cCWfn2poWIf7QRXA==" + }, + "media-typer": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-1.1.0.tgz", + "integrity": "sha512-aisnrDP4GNe06UcKFnV5bfMNPBUw4jsLGaWwWfnH3v02GnBuXX2MCVn5RbrWo0j3pczUilYblq7fQ7Nw2t5XKw==" + }, + "memoizee": { + "version": "0.4.14", + "resolved": "https://registry.npmjs.org/memoizee/-/memoizee-0.4.14.tgz", + "integrity": "sha512-/SWFvWegAIYAO4NQMpcX+gcra0yEZu4OntmUdrBaWrJncxOqAziGFlHxc7yjKVK2uu3lpPW27P27wkR82wA8mg==", + "requires": { + "d": "1", + "es5-ext": "^0.10.45", + "es6-weak-map": "^2.0.2", + "event-emitter": "^0.3.5", + "is-promise": "^2.1", + "lru-queue": "0.1", + "next-tick": "1", + "timers-ext": "^0.1.5" + } + }, + "mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" + }, + "minimize": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/minimize/-/minimize-2.2.0.tgz", + "integrity": "sha512-IxR2XMbw9pXCxApkdD9BTcH2U4XlXhbeySUrv71rmMS9XDA8BVXEsIuFu24LtwCfBgfbL7Fuh8/ZzkO5DaTLlQ==", + "requires": { + "argh": "^0.1.4", + "async": "^2.1.5", + "cli-color": "^1.2.0", + "diagnostics": "^1.1.0", + "emits": "^3.0.0", + "htmlparser2": "^3.9.2", + "uuid": "^3.0.0" + } + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "requires": { + "minimist": "0.0.8" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "mute-stream": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", + "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", + "dev": true + }, + "natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", + "dev": true + }, + "next-tick": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/next-tick/-/next-tick-1.0.0.tgz", + "integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw=" + }, + "nice-try": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", + "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", + "dev": true + }, + "no-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/no-case/-/no-case-3.0.3.tgz", + "integrity": "sha512-ehY/mVQCf9BL0gKfsJBvFJen+1V//U+0HQMPrWct40ixE4jnv0bfvxDbWtAHL9EcaPEOJHVVYKoQn1TlZUB8Tw==", + "requires": { + "lower-case": "^2.0.1", + "tslib": "^1.10.0" + } + }, + "nopt": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", + "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", + "requires": { + "abbrev": "1", + "osenv": "^0.1.4" + } + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "optional": true + }, + "nunjucks": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/nunjucks/-/nunjucks-3.2.2.tgz", + "integrity": "sha512-KUi85OoF2NMygwODAy28Lh9qHmq5hO3rBlbkYoC8v377h4l8Pt5qFjILl0LWpMbOrZ18CzfVVUvIHUIrtED3sA==", + "requires": { + "a-sync-waterfall": "^1.0.0", + "asap": "^2.0.3", + "chokidar": "^3.3.0", + "commander": "^5.1.0" + }, + "dependencies": { + "commander": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", + "integrity": "sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg==" + } + } + }, + "nunjucks-markdown": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/nunjucks-markdown/-/nunjucks-markdown-2.0.1.tgz", + "integrity": "sha1-1V51Qzo1hQ4sNFZR/j+THtmxVqI=" + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "onetime": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.0.tgz", + "integrity": "sha512-5NcSkPHhwTVFIQN+TUqXoS5+dlElHXdpAWu9I0HP20YOtIi+aZ0Ct82jdlILDxjLEAWwvm+qj1m6aEtsDVmm6Q==", + "dev": true, + "requires": { + "mimic-fn": "^2.1.0" + } + }, + "optionator": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", + "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "dev": true, + "requires": { + "deep-is": "~0.1.3", + "fast-levenshtein": "~2.0.6", + "levn": "~0.3.0", + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2", + "word-wrap": "~1.2.3" + } + }, + "os-homedir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=" + }, + "os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=" + }, + "osenv": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", + "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", + "requires": { + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "requires": { + "p-limit": "^2.0.0" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" + }, + "param-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/param-case/-/param-case-3.0.3.tgz", + "integrity": "sha512-VWBVyimc1+QrzappRs7waeN2YmoZFCGXWASRYX1/rGHtXqEcrGEIDm+jqIwFa2fRXNgQEwrxaYuIrX0WcAguTA==", + "requires": { + "dot-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "parent-module": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", + "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", + "dev": true, + "requires": { + "callsites": "^3.0.0" + } + }, + "pascal-case": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/pascal-case/-/pascal-case-3.1.1.tgz", + "integrity": "sha512-XIeHKqIrsquVTQL2crjq3NfJUxmdLasn3TYOU0VBM+UX2a6ztAWBlJQBePLGY7VHW8+2dRadeIPK5+KImwTxQA==", + "requires": { + "no-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "path-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/path-case/-/path-case-3.0.3.tgz", + "integrity": "sha512-UMFU6UETFpCNWbIWNczshPrnK/7JAXBP2NYw80ojElbQ2+JYxdqWDBkvvqM93u4u6oLmuJ/tPOf2tM8KtXv4eg==", + "requires": { + "dot-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-key": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", + "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", + "dev": true + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "optional": true + }, + "pluralize": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-8.0.0.tgz", + "integrity": "sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==" + }, + "prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", + "dev": true + }, + "prettier": { + "version": "1.19.1", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-1.19.1.tgz", + "integrity": "sha512-s7PoyDv/II1ObgQunCbB9PdLmUcBZcnWOcxDh7O0N/UwDEsHyqkW+Qh28jW+mVuCdx7gLB0BotYI1Y6uI9iyew==", + "dev": true + }, + "prettier-linter-helpers": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz", + "integrity": "sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==", + "dev": true, + "requires": { + "fast-diff": "^1.1.2" + } + }, + "pretty": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pretty/-/pretty-2.0.0.tgz", + "integrity": "sha1-rbx5YLe7/iiaVX3F9zdhmiINBqU=", + "requires": { + "condense-newlines": "^0.2.1", + "extend-shallow": "^2.0.1", + "js-beautify": "^1.6.12" + } + }, + "progress": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", + "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", + "dev": true + }, + "promise-polyfill": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/promise-polyfill/-/promise-polyfill-8.1.3.tgz", + "integrity": "sha512-MG5r82wBzh7pSKDRa9y+vllNHz3e3d4CNj1PQE4BQYxLme0gKYYBm9YENq+UkEikyZ0XbiGWxYlVw3Rl9O/U8g==" + }, + "proto-list": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/proto-list/-/proto-list-1.2.4.tgz", + "integrity": "sha1-IS1b/hMYMGpCD2QCuOJv85ZHqEk=" + }, + "pseudomap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", + "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=" + }, + "punycode": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", + "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", + "dev": true + }, + "q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", + "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=" + }, + "raml-1-parser": { + "version": "1.1.67", + "resolved": "https://registry.npmjs.org/raml-1-parser/-/raml-1-parser-1.1.67.tgz", + "integrity": "sha512-3dcGepRbixHoQyQZ8WvLajgK3lfcyvWynU38PdkZGM/9r6KXXSCmxNypu+zwDOBT1V5O3swREIiBN5KgD91sTA==", + "requires": { + "change-case": "^4.1.1", + "fs-extra": "8.1.0", + "http-response-object": "3.0.2", + "invariant": "2.2.4", + "json-path": "0.1.3", + "json-schema-compatibility": "1.1.0", + "json-stable-stringify": "1.0.1", + "loophole": "1.1.0", + "lrucache": "1.0.3", + "media-typer": "1.1.0", + "mkdirp": "^1.0.3", + "pluralize": "8.0.0", + "promise-polyfill": "8.1.3", + "q": "1.5.1", + "raml-definition-system": "^0.0.94", + "ts-model": "0.0.18", + "underscore": "^1.10.2", + "upper-case-first": "^2.0.1", + "urlsafe-base64": "1.0.0", + "xhr2": "0.2.0", + "xmldom-alpha": "^0.1.28", + "xmlhttprequest": "1.8.0", + "yaml-ast-parser": "0.0.43", + "z-schema": "^4.2.2" + }, + "dependencies": { + "mkdirp": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==" + } + } + }, + "raml-definition-system": { + "version": "0.0.94", + "resolved": "https://registry.npmjs.org/raml-definition-system/-/raml-definition-system-0.0.94.tgz", + "integrity": "sha512-KawJ4uEncArvhyXThSFVN8PEbQN66rQVXX88uocaLB+MBBCduvDsVtMxAfpv5mFYXfmI/Wqgvn4CPFw6qJ9T4g==", + "requires": { + "know-your-http-well": "0.5.0", + "raml-typesystem": "^0.0.96", + "ts-structure-model": "0.0.1", + "underscore": "^1.9.2" + } + }, + "raml-json-validation": { + "version": "0.0.18", + "resolved": "https://registry.npmjs.org/raml-json-validation/-/raml-json-validation-0.0.18.tgz", + "integrity": "sha512-U43jM2+2203s59jMWlNQIc1SmQ4B8rJKJXL5bQJdFHVyr2W9ImLJOmDCSpkKHKlM24f72iRbU/aVupjpWY8fBA==", + "optional": true, + "requires": { + "z-schema": "3.21.0" + }, + "dependencies": { + "z-schema": { + "version": "3.21.0", + "resolved": "https://registry.npmjs.org/z-schema/-/z-schema-3.21.0.tgz", + "integrity": "sha512-+MXJmBRZvqn+LInpJBSSETK1XLQqyhKCCNqc7MY7FqiqWCTQddAahg5i0jlfX5dli7gvIfpJvijV3ZlAJRtZ1Q==", + "optional": true, + "requires": { + "commander": "^2.7.1", + "lodash.get": "^4.0.0", + "lodash.isequal": "^4.0.0", + "validator": "^10.0.0" + } + } + } + }, + "raml-typesystem": { + "version": "0.0.96", + "resolved": "https://registry.npmjs.org/raml-typesystem/-/raml-typesystem-0.0.96.tgz", + "integrity": "sha512-hf9/XlrV73ouELMe/LbwRubsNHt16/xJd7zWUuurumq2Vv6w8nxmWH0d/RImQ9Uylv80u02pcIEGKeYahdDZiA==", + "requires": { + "bignumber.js": "9.0.0", + "date-and-time": "^0.11.1", + "escape-html": "1.0.3", + "json-schema-compatibility": "1.1.0", + "json-to-ast": "2.0.0-alpha1.3", + "lrucache": "1.0.3", + "raml-json-validation": "0.0.18", + "raml-xml-validation": "0.0.15", + "underscore": "^1.10.2", + "xml2js": "^0.4.23", + "xmldom-alpha": "^0.1.28" + } + }, + "raml-xml-validation": { + "version": "0.0.15", + "resolved": "https://registry.npmjs.org/raml-xml-validation/-/raml-xml-validation-0.0.15.tgz", + "integrity": "sha512-ixkKvCc2b/R7WkPxhFDT7Bg7HLRyzXGp/2UrGFJfkxvsAEMC5JZ2b7LEpmrx6JGzLaHFA01KJ/IBNoZdxvM2xw==", + "optional": true, + "requires": { + "xmllint-jsparser": "0.0.3" + } + }, + "raml2html-default-theme": { + "version": "2.9.3", + "resolved": "https://registry.npmjs.org/raml2html-default-theme/-/raml2html-default-theme-2.9.3.tgz", + "integrity": "sha512-NQq5qa1M9SfDhKGoWOmTdGU5WwKZnEuHSH7O/tMPiMgU9+DkLEM7IIrs0/ETwyqlnkv4PJE1R75fOq84T4tbDg==" + }, + "raml2obj": { + "version": "6.7.0", + "resolved": "https://registry.npmjs.org/raml2obj/-/raml2obj-6.7.0.tgz", + "integrity": "sha512-VPpRbhtsAK7039pEg30JgReLoMEa5Qjay2d3Awa1UsyilNqGFAoa8sgDYHY5/POihsX9GNH5+5Lt/qWv7HDdsA==", + "requires": { + "datatype-expansion": "^0.4.1", + "raml-1-parser": "^1.1.67" + } + }, + "readdirp": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.5.0.tgz", + "integrity": "sha512-cMhu7c/8rdhkHXWsY+osBhfSy0JikwpHK/5+imo+LpeasTF8ouErHrlYkwT0++njiyuDvc7OFY5T3ukvZ8qmFQ==", + "optional": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "regexpp": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz", + "integrity": "sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw==", + "dev": true + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" + }, + "resolve-from": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", + "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "dev": true + }, + "restore-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", + "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", + "dev": true, + "requires": { + "onetime": "^5.1.0", + "signal-exit": "^3.0.2" + } + }, + "rimraf": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", + "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", + "dev": true, + "requires": { + "glob": "^7.1.3" + } + }, + "run-async": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.1.tgz", + "integrity": "sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==", + "dev": true + }, + "rxjs": { + "version": "6.6.0", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.6.0.tgz", + "integrity": "sha512-3HMA8z/Oz61DUHe+SdOiQyzIf4tOx5oQHmMir7IZEu6TMqCLHT4LRcmNaUS0NwOz8VLvmmBduMsoaUvMaIiqzg==", + "dev": true, + "requires": { + "tslib": "^1.9.0" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, + "sax": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==" + }, + "semver": { + "version": "5.5.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.1.tgz", + "integrity": "sha512-PqpAxfrEhlSUWge8dwIp4tZnQ25DIOthpiaHNIthsjEFQD6EvqUKUDM7L8O2rShkFccYo1VjJR0coWfNkCubRw==" + }, + "sentence-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/sentence-case/-/sentence-case-3.0.3.tgz", + "integrity": "sha512-ZPr4dgTcNkEfcGOMFQyDdJrTU9uQO1nb1cjf+nuzb6FxgMDgKddZOM29qEsB7jvsZSMruLRcL2KfM4ypKpa0LA==", + "requires": { + "no-case": "^3.0.3", + "tslib": "^1.10.0", + "upper-case-first": "^2.0.1" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" + }, + "shebang-command": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", + "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", + "dev": true, + "requires": { + "shebang-regex": "^1.0.0" + } + }, + "shebang-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", + "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", + "dev": true + }, + "sigmund": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz", + "integrity": "sha1-P/IfGYytIXX587eBhT/ZTQ0ZtZA=" + }, + "signal-exit": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", + "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==", + "dev": true + }, + "simple-swizzle": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", + "integrity": "sha1-pNprY1/8zMoz9w0Xy5JZLeleVXo=", + "requires": { + "is-arrayish": "^0.3.1" + } + }, + "slice-ansi": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz", + "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "astral-regex": "^1.0.0", + "is-fullwidth-code-point": "^2.0.0" + }, + "dependencies": { + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + } + } + }, + "snake-case": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/snake-case/-/snake-case-3.0.3.tgz", + "integrity": "sha512-WM1sIXEO+rsAHBKjGf/6R1HBBcgbncKS08d2Aqec/mrDSpU80SiOU41hO7ny6DToHSyrlwTYzQBIK1FPSx4Y3Q==", + "requires": { + "dot-case": "^3.0.3", + "tslib": "^1.10.0" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "string-width": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz", + "integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==", + "dev": true, + "requires": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + } + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + } + } + }, + "strip-json-comments": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", + "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "dev": true + }, + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "requires": { + "has-flag": "^3.0.0" + } + }, + "table": { + "version": "5.4.6", + "resolved": "https://registry.npmjs.org/table/-/table-5.4.6.tgz", + "integrity": "sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==", + "dev": true, + "requires": { + "ajv": "^6.10.2", + "lodash": "^4.17.14", + "slice-ansi": "^2.1.0", + "string-width": "^3.0.0" + }, + "dependencies": { + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + } + } + }, + "text-hex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/text-hex/-/text-hex-1.0.0.tgz", + "integrity": "sha512-uuVGNWzgJ4yhRaNSiubPY7OjISw4sw4E5Uv0wbjp+OzcbmVU/rsT8ujgcXJhn9ypzsgr5vlzpPqP+MBBKcGvbg==" + }, + "text-table": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", + "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=", + "dev": true + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "timers-ext": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/timers-ext/-/timers-ext-0.1.7.tgz", + "integrity": "sha512-b85NUNzTSdodShTIbky6ZF02e8STtVVfD+fu4aXXShEELpozH+bCpJLYMPZbsABN2wDH7fJpqIoXxJpzbf0NqQ==", + "requires": { + "es5-ext": "~0.10.46", + "next-tick": "1" + } + }, + "tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "dev": true, + "requires": { + "os-tmpdir": "~1.0.2" + } + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "optional": true, + "requires": { + "is-number": "^7.0.0" + } + }, + "ts-model": { + "version": "0.0.18", + "resolved": "https://registry.npmjs.org/ts-model/-/ts-model-0.0.18.tgz", + "integrity": "sha512-wIBuWYxYES3m0JNT8nnPTo3GgH+Xa2NGig2GWGGTryMVPiME/Tg5DQrcydBfLjf/cWcPMn9uxgANiQWaGTyFDg==", + "requires": { + "underscore": "1.9.1" + }, + "dependencies": { + "underscore": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.9.1.tgz", + "integrity": "sha512-5/4etnCkd9c8gwgowi5/om/mYO5ajCaOgdzj/oW+0eQV9WxKBDZw5+ycmKmeaTXjInS/W0BzpGLo2xR2aBwZdg==" + } + } + }, + "ts-structure-model": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/ts-structure-model/-/ts-structure-model-0.0.1.tgz", + "integrity": "sha512-7hqYQx4kPWUkJXTVsZe++1IMd63jZAjW6O00+kHJf9/DcNaxCJxNjsQhLVcC57HZhK4SUPSxMZd+AnGrLA6Itw==" + }, + "tslib": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.10.0.tgz", + "integrity": "sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ==" + }, + "type": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/type/-/type-1.2.0.tgz", + "integrity": "sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==" + }, + "type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "dev": true, + "requires": { + "prelude-ls": "~1.1.2" + } + }, + "type-fest": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", + "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", + "dev": true + }, + "underscore": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.10.2.tgz", + "integrity": "sha512-N4P+Q/BuyuEKFJ43B9gYuOj4TQUHXX+j2FqguVOpjkssLUUrnJofCcBccJSCoeturDoZU6GorDTHSvUDlSQbTg==" + }, + "universalify": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", + "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==" + }, + "upper-case": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/upper-case/-/upper-case-2.0.1.tgz", + "integrity": "sha512-laAsbea9SY5osxrv7S99vH9xAaJKrw5Qpdh4ENRLcaxipjKsiaBwiAsxfa8X5mObKNTQPsupSq0J/VIxsSJe3A==", + "requires": { + "tslib": "^1.10.0" + } + }, + "upper-case-first": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/upper-case-first/-/upper-case-first-2.0.1.tgz", + "integrity": "sha512-105J8XqQ+9RxW3l9gHZtgve5oaiR9TIwvmZAMAIZWRHe00T21cdvewKORTlOJf/zXW6VukuTshM+HXZNWz7N5w==", + "requires": { + "tslib": "^1.10.0" + } + }, + "uri-js": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", + "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", + "dev": true, + "requires": { + "punycode": "^2.1.0" + } + }, + "urlsafe-base64": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/urlsafe-base64/-/urlsafe-base64-1.0.0.tgz", + "integrity": "sha1-I/iQaabGL0bPOh07ABac77kL4MY=" + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + }, + "uuid": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.3.tgz", + "integrity": "sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ==" + }, + "v8-compile-cache": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.1.tgz", + "integrity": "sha512-8OQ9CL+VWyt3JStj7HX7/ciTL2V3Rl1Wf5OL+SNTm0yK1KvtReVulksyeRnCANHHuUxHlQig+JJDlUhBt1NQDQ==", + "dev": true + }, + "validator": { + "version": "10.11.0", + "resolved": "https://registry.npmjs.org/validator/-/validator-10.11.0.tgz", + "integrity": "sha512-X/p3UZerAIsbBfN/IwahhYaBbY68EN/UQBWHtsbXGT5bfrH/p4NQzUCG1kF/rtKaNpnJ7jAu6NGTdSNtyNIXMw==", + "optional": true + }, + "which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" + }, + "word-wrap": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", + "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "write": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/write/-/write-1.0.3.tgz", + "integrity": "sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==", + "dev": true, + "requires": { + "mkdirp": "^0.5.1" + } + }, + "xhr2": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/xhr2/-/xhr2-0.2.0.tgz", + "integrity": "sha512-BDtiD0i2iKPK/S8OAZfpk6tyzEDnKKSjxWHcMBVmh+LuqJ8A32qXTyOx+TVOg2dKvq6zGBq2sgKPkEeRs1qTRA==" + }, + "xml2js": { + "version": "0.4.23", + "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.4.23.tgz", + "integrity": "sha512-ySPiMjM0+pLDftHgXY4By0uswI3SPKLDw/i3UXbnO8M/p28zqexCUoPmQFrYD+/1BzhGJSs2i1ERWKJAtiLrug==", + "requires": { + "sax": ">=0.6.0", + "xmlbuilder": "~11.0.0" + } + }, + "xmlbuilder": { + "version": "11.0.1", + "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-11.0.1.tgz", + "integrity": "sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==" + }, + "xmldom-alpha": { + "version": "0.1.28", + "resolved": "https://registry.npmjs.org/xmldom-alpha/-/xmldom-alpha-0.1.28.tgz", + "integrity": "sha1-ToRR2N9Ne7MDuq4L3ngwYvnT1gA=" + }, + "xmlhttprequest": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest/-/xmlhttprequest-1.8.0.tgz", + "integrity": "sha1-Z/4HXFwk/vOfnWX197f+dRcZaPw=" + }, + "xmllint-jsparser": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/xmllint-jsparser/-/xmllint-jsparser-0.0.3.tgz", + "integrity": "sha1-aLBRNDkX2pX3e3oMeg+7QAF142Y=", + "optional": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" + }, + "yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" + }, + "yaml-ast-parser": { + "version": "0.0.43", + "resolved": "https://registry.npmjs.org/yaml-ast-parser/-/yaml-ast-parser-0.0.43.tgz", + "integrity": "sha512-2PTINUwsRqSd+s8XxKaJWQlUuEMHJQyEuh2edBbW8KNJz0SJPwUSD2zRWqezFEdN7IzAgeuYHFUCF7o8zRdZ0A==" + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + }, + "dependencies": { + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + } + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "z-schema": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/z-schema/-/z-schema-4.2.3.tgz", + "integrity": "sha512-zkvK/9TC6p38IwcrbnT3ul9in1UX4cm1y/VZSs4GHKIiDCrlafc+YQBgQBUdDXLAoZHf2qvQ7gJJOo6yT1LH6A==", + "requires": { + "commander": "^2.7.1", + "lodash.get": "^4.4.2", + "lodash.isequal": "^4.5.0", + "validator": "^12.0.0" + }, + "dependencies": { + "validator": { + "version": "12.2.0", + "resolved": "https://registry.npmjs.org/validator/-/validator-12.2.0.tgz", + "integrity": "sha512-jJfE/DW6tIK1Ek8nCfNFqt8Wb3nzMoAbocBF6/Icgg1ZFSBpObdnwVY2jQj6qUqzhx5jc71fpvBWyLGO7Xl+nQ==" + } + } + } + } +} diff --git a/package.json b/package.json index ad523e00..6c12b751 100644 --- a/package.json +++ b/package.json @@ -1,33 +1,52 @@ { "name": "raml2html", "description": "RAML to HTML documentation generator", - "version": "0.26.0", + "version": "7.7.0", "author": { "name": "Kevin Renskers", - "email": "info@mixedcase.nl" + "email": "kevin@mixedcase.nl" }, "bugs": { - "url": "https://github.com/kevinrenskers/raml2html/issues" + "url": "https://github.com/raml2html/raml2html/issues" }, "dependencies": { - "commander": "^2.2.0", - "handlebars": "~2.0.0-alpha.1", - "highlight.js": "^8.0.0", - "marked": "^0.3.2", - "raml2obj": "*" + "chalk": "^2.4.2", + "marked": "^1.0.0", + "minimize": "2.2.x", + "nunjucks": "^3.2.2", + "nunjucks-markdown": "2.0.x", + "pretty": "^2.0.0", + "raml2html-default-theme": "^2.10.0", + "raml2obj": "^6.7.0", + "yargs": "^14.2.3" }, - "homepage": "https://github.com/kevinrenskers/raml2html", + "devDependencies": { + "eslint": "^6.8.0", + "eslint-plugin-prettier": "^3.3.1", + "prettier": "^1.19.1" + }, + "homepage": "https://github.com/raml2html/raml2html", "keywords": [ "RAML" ], "license": "MIT", - "main": "lib/raml2html.js", + "main": "index.js", "repository": { "type": "git", - "url": "git://github.com/kevinrenskers/raml2html.git" + "url": "git://github.com/raml2html/raml2html.git" + }, + "preferGlobal": true, + "scripts": { + "lint": "eslint . --fix" }, - "preferGlobal": "true", "bin": { - "raml2html": "lib/raml2html.js" + "raml2html": "./bin/raml2html" + }, + "files": [ + "index.js", + "bin/raml2html" + ], + "engines": { + "node": ">=6" } }