{"id":301689,"date":"2020-04-11T21:00:30","date_gmt":"2020-04-11T21:00:30","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=301689"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2020-04-11T21:00:30","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=301689","title":{"rendered":"\u041e\u0442 48k \u0434\u043e 10 \u0441\u0442\u0440\u043e\u043a \u043a\u043e\u0434\u0430 \u2014 \u0438\u0441\u0442\u043e\u0440\u0438\u044f GitHub JavaScript SDK"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/496598\/\">\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/9l\/zi\/3k\/9lzi3kc9ivgzrrzghpyddw_rdfe.png\"><\/p>\n<p>  <\/p>\n<p><code>@octokit\/rest<\/code> \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u043d\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u043e\u0439 GitHub, \u0438 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0430\u0434\u0430\u043f\u0442\u0430\u0446\u0438\u044e <a href=\"https:\/\/www.npmjs.com\/package\/github\" rel=\"nofollow\">github<\/a> \u2014 \u0441\u0430\u043c\u043e\u0433\u043e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0433\u043e \u043f\u0430\u043a\u0435\u0442\u0430 2017 \u0433\u043e\u0434\u0430 \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <a href=\"https:\/\/github.com\/bkeepers\" rel=\"nofollow\">@bkeepers<\/a>. \u0412 \u044d\u0442\u043e\u043c \u043f\u043e\u0441\u0442\u0435 \u0431\u0443\u0434\u0435\u043c \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u044c \u043f\u0440\u043e <a href=\"https:\/\/github.com\/octokit\/rest.js\/\" rel=\"nofollow\"><code>@octokit\/rest<\/code><\/a> \u2014 \u0442\u0435\u043f\u0435\u0440\u044c \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 JavaScript SDK \u0434\u043b\u044f <a href=\"https:\/\/developer.github.com\/v3\" rel=\"nofollow\">GitHub REST API<\/a>.<\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<blockquote><p>\u0413\u0440\u0435\u0433\u043e\u0440 (\u0430\u0432\u0442\u043e\u0440 \u0441\u0442\u0430\u0442\u044c\u0438) \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u043c JavaScript Octokit. \u041e\u043d \u0431\u044b\u0432\u0430\u043b\u044b\u0439 open source \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a, \u0441 \u043e\u0441\u043e\u0431\u043e\u0439 \u0442\u044f\u0433\u043e\u0439 \u043a \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447 \u0438 \u0441\u043d\u0438\u0436\u0435\u043d\u0438\u044e \u043f\u043e\u0440\u043e\u0433\u0430 \u0432\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0440\u0438\u0431\u044c\u044e\u0442\u043e\u0440\u043e\u0432 \u0432\u0441\u0435\u0445 \u0432\u0438\u0434\u043e\u0432 \u0438 \u043f\u0440\u043e\u0444\u0435\u0441\u0441\u0438\u0439. \u041f\u043e\u043c\u0438\u043c\u043e Octokit, \u0413\u0440\u0435\u0433\u043e\u0440 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430\u0434 <a href=\"https:\/\/probot.github.io\/\" rel=\"nofollow\">Probot<\/a>, <a href=\"https:\/\/github.com\/nock\/nock\/\" rel=\"nofollow\">nock<\/a> \u0438 <a href=\"https:\/\/semantic-release.gitbook.io\/semantic-release\/\" rel=\"nofollow\">semantic-release<\/a>. \u0412 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u043e\u043d \u0437\u0430\u0431\u043e\u0442\u0438\u0442\u0441\u044f \u043e \u0441\u0432\u043e\u0438\u0445 \u0442\u0440\u043e\u0439\u043d\u044f\u0448\u043a\u0430\u0445 \u041d\u0438\u043a\u043e, \u0410\u0434\u0435 \u0438 \u041a\u0438\u0430\u043d\u0435. \u0411\u043e\u043b\u044c\u0448\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 \u0413\u0440\u0435\u0433\u043e\u0440\u0430 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u043d\u0430 <a href=\"https:\/\/dev.to\/gr2m\/\" rel=\"nofollow\">DEV community<\/a> \u0438 <a href=\"https:\/\/mobile.twitter.com\/gr2m\" rel=\"nofollow\">Twitter<\/a>.<\/p><\/blockquote>\n<p>  <\/p>\n<h2 id=\"legacy\">legacy<\/h2>\n<p>  <\/p>\n<p>\u041f\u043e\u0437\u0436\u0435 \u043f\u0435\u0440\u0435\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0432 <code>@octokit\/rest<\/code>, \u043f\u0430\u043a\u0435\u0442 <code>github<\/code> \u0431\u044b\u043b \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u0441\u0442\u0430\u0440\u0435\u0439\u0448\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u0432 \u044d\u043a\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u0435 Node. <a href=\"https:\/\/github.com\/octokit\/rest.js\/commit\/6eba297d1a572af6ef35c69faea42262f6aaf5dc\" rel=\"nofollow\">\u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043e\u043c\u043c\u0438\u0442<\/a> \u0441\u0434\u0435\u043b\u0430\u043d \u0432 \u0438\u044e\u043d\u0435 2010 \u0433\u043e\u0434\u0430. \u042d\u0442\u043e \u0431\u044b\u043b\u0438 \u0432\u0440\u0435\u043c\u0435\u043d\u0430 <a href=\"https:\/\/github.com\/nodejs\/node-v0.x-archive\/releases\/tag\/v0.1.97\" rel=\"nofollow\">Node v0.1<\/a>, \u043a\u043e\u0433\u0434\u0430 <em>package.json<\/em> \u0435\u0449\u0435 \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u043b, \u0430 \u0440\u0435\u0435\u0441\u0442\u0440 npm \u0431\u044b\u043b \u0432\u0441\u0451 \u0435\u0449\u0451 \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435.<\/p>\n<p>  <\/p>\n<p>\u0412 2017 \u0433\u043e\u0434\u0443 GitHub \u043d\u0430\u043d\u044f\u043b\u0438 \u043c\u0435\u043d\u044f, \u0447\u0442\u043e\u0431\u044b \u043f\u0435\u0440\u0435\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043f\u0430\u043a\u0435\u0442 <code>github<\/code> \u0432 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 GitHub API JavaScript SDK \u0434\u043b\u044f \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u0432 \u0438 Node.js. \u0417\u0434\u0435\u0441\u044c \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 <a href=\"https:\/\/github.com\/octokit\/rest.js\/commits\/50720c8b1795e24f938bdbf44cb37922241b04dc\" rel=\"nofollow\">\u043c\u043e\u0439 \u043f\u0435\u0440\u0432\u044b\u0439 \u043a\u043e\u043c\u043c\u0438\u0442<\/a> \u0432 \u0441\u0435\u043d\u0442\u044f\u0431\u0440\u0435 2017 \u0433\u043e\u0434\u0430. \u041d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u0431\u044b\u043b\u043e \u043e\u043a\u043e\u043b\u043e 16 \u0442\u044b\u0441\u044f\u0447 \u0441\u0442\u0440\u043e\u043a \u043a\u043e\u0434\u0430, \u0440\u0430\u0437\u0431\u0438\u0442\u044b\u0445 \u043d\u0430 \u0442\u0440\u0438 JavaScript \u0444\u0430\u0439\u043b\u0430, \u043e\u0434\u0438\u043d \u043e\u0433\u0440\u043e\u043c\u043d\u044b\u0439 JSON \u0438 \u0434\u0432\u0430 \u0444\u0430\u0439\u043b\u0430 \u0434\u043b\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0439 \u0442\u0438\u043f\u043e\u0432 TypeScript\/Flow.<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">\u279c  rest.js git:(50720c8) wc -l lib\/*      120 lib\/error.js     3246 lib\/index.d.ts      905 lib\/index.js     3232 lib\/index.js.flow       17 lib\/promise.js     7995 lib\/routes.json      143 lib\/util.js    15658 total<\/code><\/pre>\n<p>  <\/p>\n<h2 id=\"razrabotka\">\u0420\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0430<\/h2>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0432\u043e\u0439 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0446\u0435\u043b\u044c\u044e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0431\u044b\u043b\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u043e\u0441\u0442\u044c \u043a\u043e\u0434\u0430. \u0422\u043e\u0433\u0434\u0430 \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u043c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u044b\u043b \u043e\u0433\u0440\u043e\u043c\u043d\u044b\u0439 \u0444\u0430\u0439\u043b <a href=\"https:\/\/github.com\/octokit\/rest.js\/blob\/586a4df56a42d5daab2d3350b8db018e9c9b95fb\/lib\/routes.json\" rel=\"nofollow\"><em>routes.json<\/em><\/a> \u043d\u0430 \u043f\u043e\u0447\u0442\u0438 8 \u0442\u044b\u0441\u044f\u0447 \u0441\u0442\u0440\u043e\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u043b \u0432\u0441\u0435 \u043a\u043e\u043d\u0435\u0447\u043d\u044b\u0435 \u0442\u043e\u0447\u043a\u0438 REST API GitHub. \u0415\u0433\u043e \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u043b\u0430\u0441\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e, \u0430 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435\/\u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0440\u043e\u0443\u0442\u043e\u0432 \u0431\u044b\u043b\u043e \u0441\u043b\u0435\u0434\u0441\u0442\u0432\u0438\u0435\u043c <a href=\"https:\/\/github.com\/octokit\/rest.js\/issues\/558\" rel=\"nofollow\">\u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0433\u043e \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b<\/a>.<\/p>\n<p>  <\/p>\n<p>\u0423\u0447\u0438\u0442\u044b\u0432\u0430\u044f \u044d\u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u044f \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u0441\u043a\u0440\u0438\u043f\u0442 (<a href=\"https:\/\/github.com\/octokit\/routes\/\" rel=\"nofollow\">octokit\/routes<\/a>) \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0430\u043d\u0430\u043b\u0438\u0437\u0430 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 REST API GitHub \u0438 \u0432\u044b\u0432\u043e\u0434\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0432 JSON. \u042d\u0442\u043e \u0440\u0435\u0448\u0438\u043b\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 <em>routes.json<\/em>. \u0415\u0441\u043b\u0438 \u0441\u043a\u0440\u0438\u043f\u0442 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0432\u0430\u043b \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f, <code>@octokit\/rest<\/code> \u043f\u043e\u043b\u0443\u0447\u0430\u043b PR \u0441 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f\u043c\u0438 \u0444\u0430\u0439\u043b\u0430 <em>routes.json<\/em>, \u0438 \u043f\u043e\u0441\u043b\u0435 \u043c\u0435\u0440\u0434\u0436\u0430 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0440\u0435\u043b\u0438\u0437. \u0411\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u0442\u0430\u043a\u043e\u0439 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438, \u0444\u0430\u0439\u043b <em>routes.json<\/em> \u0442\u0435\u043f\u0435\u0440\u044c \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e \u043f\u043e\u043a\u0440\u044b\u0432\u0430\u043b \u0432\u0441\u0435 \u043a\u043e\u043d\u0435\u0447\u043d\u044b\u0435 \u0442\u043e\u0447\u043a\u0438 REST API GitHub \u0438 \u0441\u043e\u0441\u0442\u043e\u044f\u043b \u0438\u0437 <a href=\"https:\/\/github.com\/octokit\/rest.js\/blob\/v16.0.1\/plugins\/rest-api-endpoints\/routes.json\" rel=\"nofollow\">10 275 \u0441\u0442\u0440\u043e\u043a \u043a\u043e\u0434\u0430<\/a>. \u0421\u043e\u043f\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u043e\u0432 TypeScript \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u043b\u0438\u0441\u044c \u0434\u043e \u0431\u043e\u043b\u0435\u0435 \u0447\u0435\u043c <a href=\"https:\/\/unpkg.com\/browse\/@octokit\/rest@15.18.0\/index.d.ts\" rel=\"nofollow\">26 700 \u0441\u0442\u0440\u043e\u043a \u043a\u043e\u0434\u0430<\/a>.<\/p>\n<p>  <\/p>\n<h2 id=\"arhitektura\">\u0410\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430<\/h2>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u0432\u043e\u043f\u0440\u043e\u0441 \u043f\u043e\u043b\u043d\u043e\u0442\u044b \u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u043e\u0441\u0442\u0438 API \u0431\u044b\u043b \u0440\u0435\u0448\u0435\u043d, \u044f \u0441\u043e\u0441\u0440\u0435\u0434\u043e\u0442\u043e\u0447\u0438\u043b\u0441\u044f \u043d\u0430 \u0434\u0440\u0443\u0433\u043e\u0439 \u0446\u0435\u043b\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430: <a href=\"https:\/\/github.com\/octokit\/discussions\/tree\/5e94064e6b1345d020800a24c8d4a098639b7980\/docs#decomposable\" rel=\"nofollow\">\u043c\u043e\u0434\u0443\u043b\u044c\u043d\u043e\u0441\u0442\u044c<\/a>.<\/p>\n<p>  <\/p>\n<blockquote><p>\u041f\u0440\u0438\u043c. \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430: \u0412 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0442\u0435\u0440\u043c\u0438\u043d &quot;decomposability&quot;, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u0441\u043b\u043e\u0432\u043d\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0432\u0435\u0441\u0442\u0438 \u043a\u0430\u043a &quot;\u0440\u0430\u0437\u043b\u043e\u0436\u0438\u043c\u043e\u0441\u0442\u044c&quot;, \u0447\u0442\u043e \u043d\u0435 \u0441\u043e\u0432\u0441\u0435\u043c \u0443\u0434\u0430\u0447\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0441\u043c\u044b\u0441\u043b. \u0417\u0434\u0435\u0441\u044c \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u0432\u0438\u0434\u0443 &quot;\u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043d\u0430 \u0447\u0430\u0441\u0442\u0438&quot;, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u044a\u044f\u0441\u043d\u0438\u0442\u044c \u043a\u0430\u043a &quot;\u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043d\u0430 \u043c\u043e\u0434\u0443\u043b\u0438&quot; \u0438\u043b\u0438 &quot;\u043c\u043e\u0434\u0443\u043b\u044c\u043d\u043e\u0441\u0442\u044c&quot;.<\/p><\/blockquote>\n<p>JavaScript Octokit \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0441\u0440\u0435\u0434 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f JavaScript, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438\u043c\u0435\u044e\u0442 \u0441\u0442\u0440\u043e\u0433\u0438\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0440\u0430\u0437\u043c\u0435\u0440 \u043f\u0430\u043a\u0435\u0442\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u0435\u043c \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435. \u041f\u043e\u044d\u0442\u043e\u043c\u0443, \u0432\u043c\u0435\u0441\u0442\u043e \u0435\u0434\u0438\u043d\u043e\u0439 \u043c\u043e\u043d\u043e\u043b\u0438\u0442\u043d\u043e\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043f\u043e\u043b\u043d\u044b\u0439 REST API, \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u0438 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0438 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0432\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &quot;\u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u044f&quot;), \u0432\u0430\u0436\u043d\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f\u043c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0431\u043e\u043b\u0435\u0435 \u043d\u0438\u0437\u043a\u043e\u043c\u0443 \u0443\u0440\u043e\u0432\u043d\u044e. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0431\u0443\u0434\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u0435\u043d \u043a\u043e\u043c\u043f\u0440\u043e\u043c\u0438\u0441\u0441 \u043c\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u043c \u043f\u0430\u043a\u0435\u0442\u0430 \u0438 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u043e\u043c.<\/p>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 <a href=\"https:\/\/github.com\/octokit\/rest.js\/blob\/f7c9f8699f6c1c7f281c2a22862d2b4c852479dd\/HOW_IT_WORKS.md\" rel=\"nofollow\">\u043e\u0431\u0437\u043e\u0440<\/a> \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u044b, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0430\u043b \u0432 \u044f\u043d\u0432\u0430\u0440\u0435 2018 \u0433\u043e\u0434\u0430:<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/gv\/b-\/0c\/gvb-0clno44zhg4ymrwxnfsisti.png\"><\/p>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0435\u0433\u043e \u0440\u0435\u0444\u0430\u043a\u0442\u043e\u0440\u0438\u043d\u0433\u0430 \u0434\u043e \u043d\u043e\u0432\u043e\u0439 \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u044b:<br \/>  <em>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u044d\u0442\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440 \u0431\u044b\u043b \u0443\u043f\u0440\u043e\u0449\u0435\u043d \u0434\u043b\u044f \u0443\u0434\u043e\u0431\u0441\u0442\u0432\u0430 \u0447\u0442\u0435\u043d\u0438\u044f<\/em><\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">\u279c  rest.js git:(f7c9f86) wc -l index.* lib\/**\/*.{js,json}       31 index.js     3474 index.d.ts     3441 index.js.flow       101 lib\/endpoint\/ # 4 files      162 lib\/request\/ # 3 files        83 lib\/plugins\/authentication\/ # 3 files      130 lib\/plugins\/endpoint-methods\/ # 4 files      130 lib\/plugins\/pagination\/ # 11 files        58 lib\/parse-client-options.js    10628 lib\/routes.json     18238 total<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u0448\u0435\u0441\u0442\u0438 \u043c\u0435\u0441\u044f\u0446\u0435\u0432 \u044f \u0440\u0435\u043e\u0440\u0433\u0430\u043d\u0438\u0437\u043e\u0432\u0430\u043b \u043a\u043e\u0434 \u0438 \u043d\u0430\u0447\u0430\u043b \u0438\u0437\u0432\u043b\u0435\u043a\u0430\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u043c\u043e\u0434\u0443\u043b\u0435\u0439:<\/p>\n<p>  <\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/octokit\/endpoint.js\" rel=\"nofollow\"><code>@octokit\/endpoint<\/code><\/a>: \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0439 \u0442\u043e\u0447\u043a\u0438 API REST \u0432 \u043e\u0431\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b http-\u0437\u0430\u043f\u0440\u043e\u0441\u0430<\/li>\n<li><a href=\"https:\/\/github.com\/octokit\/request.js\" rel=\"nofollow\"><code>@octokit\/request<\/code><\/a>: \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u0432 API GitHub \u0441 \u0440\u0430\u0437\u0443\u043c\u043d\u044b\u043c\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430\u0445 \u0438 Node<\/li>\n<li><a href=\"https:\/\/github.com\/gr2m\/before-after-hook\" rel=\"nofollow\"><code>before-after-hook<\/code><\/a>: API \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0435\u0435\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e\u043c\u0443 \u0446\u0438\u043a\u043b\u0443 \u0437\u0430\u043f\u0440\u043e\u0441\u0430<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0412 \u043d\u043e\u044f\u0431\u0440\u0435 2018 \u0433\u043e\u0434\u0430, \u043f\u043e\u0441\u043b\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432 \u0432\u043d\u0443\u0442\u0440\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0448\u0435\u0441\u0442\u0438 \u043c\u0435\u0441\u044f\u0446\u0435\u0432, \u0431\u044b\u043b\u0430 \u0430\u043d\u043e\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u0430 <a href=\"https:\/\/github.com\/octokit\/rest.js\/releases\/tag\/v16.0.1\" rel=\"nofollow\">v16<\/a> \u0432\u043a\u043b\u044e\u0447\u0430\u044e\u0449\u0430\u044f API \u0434\u043b\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432. \u0411\u043e\u043b\u044c\u0448\u0430\u044f \u0447\u0430\u0441\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u044b\u043b\u0430 \u043f\u0435\u0440\u0435\u0432\u0435\u0434\u0435\u043d\u0430 \u043d\u0430 \u0441\u0438\u0441\u0442\u0435\u043c\u0443 <a href=\"https:\/\/github.com\/octokit\/rest.js\/tree\/v16.0.1\/plugins\" rel=\"nofollow\">\u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0445 \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432<\/a>, \u0434\u043b\u044f \u0438\u0445 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0438\u0437\u0432\u043b\u0435\u0447\u0435\u043d\u0438\u044f.<\/p>\n<p>  <\/p>\n<p>\u041d\u043e\u0432\u0430\u044f \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0435\u0433\u043e \u043a\u043e\u0434\u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u0430 \u0442\u0430\u043a:<br \/>  <em>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u044d\u0442\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440 \u0431\u044b\u043b \u0443\u043f\u0440\u043e\u0449\u0435\u043d \u0434\u043b\u044f \u0443\u0434\u043e\u0431\u0441\u0442\u0432\u0430 \u0447\u0442\u0435\u043d\u0438\u044f<\/em><\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">\u279c  rest.js git:(01763bf) wc -l index.* plugins\/**\/*.{js,json} lib\/**\/*.js       14 index.js    26714 index.d.ts       110 lib\/ # 6 files        86 plugins\/authentication\/ # 3 files       77 plugins\/pagination\/ # 3 files       39 plugins\/register-endpoints\/ # 3 files      108 plugins\/validate\/ # 2 files    10275 plugins\/rest-api-endpoints\/routes.json    37423 total<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u043e\u0437\u0436\u0435 \u044f \u0441\u043e\u0437\u0434\u0430\u043b <a href=\"https:\/\/github.com\/octokit\/core.js\" rel=\"nofollow\"><code>@octokit\/core<\/code><\/a> \u2014 \u043d\u043e\u0432\u0443\u044e \u0431\u0430\u0437\u043e\u0432\u0443\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 Octokit JavaScript, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0431\u0443\u0434\u0443\u0442 \u043e\u0441\u043d\u043e\u0432\u044b\u0432\u0430\u0442\u044c\u0441\u044f <code>@octokit\/rest<\/code> \u0438 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0433\u0440\u0443\u043f\u043f\u044b Octokit. \u0411\u043e\u043b\u044c\u0448\u0430\u044f \u0447\u0430\u0441\u0442\u044c \u0435\u0433\u043e \u043b\u043e\u0433\u0438\u043a\u0438 \u0431\u044b\u043b\u0430 \u0438\u0437\u0432\u043b\u0435\u0447\u0435\u043d\u0430 \u0438\u0437 <code>@octokit\/rest<\/code> \u0437\u0430 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u0443\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0438\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439. \u042f \u043d\u0435 \u0441\u0442\u0430\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0441\u0440\u0430\u0437\u0443 \u0432 <code>@octokit\/rest<\/code>, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 <code>@octokit\/core<\/code> \u0431\u044b\u043b \u0441\u0432\u043e\u0431\u043e\u0434\u0435\u043d \u043e\u0442 \u043b\u044e\u0431\u043e\u0433\u043e legacy \u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c\u044e, \u044f \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u043b \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u044b \u0441 \u0440\u0430\u0437\u0431\u0438\u0432\u043a\u043e\u0439 \u0441\u0440\u0435\u0434\u0441\u0442\u0432 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u043c \u0441\u0442\u0430\u043b\u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u043a\u0435\u0442\u044b \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u0438 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u2014 \u0432\u0441\u0435 \u043e\u043d\u0438 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u044b \u0432 <a href=\"https:\/\/github.com\/octokit\/auth.js#readme\" rel=\"nofollow\"><code>README @octokit\/auth<\/code><\/a>. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u0443\u0437\u043d\u0430\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435 \u043e \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u044f\u0445 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 GitHub, \u0442\u043e \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u044e \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u044c\u0441\u044f \u0441 \u043c\u043e\u0435\u0439 <a href=\"https:\/\/dev.to\/gr2m\/github-api-authentication-introduction-39dj\" rel=\"nofollow\">\u0441\u0435\u0440\u0438\u0435\u0439 \u0441\u0442\u0430\u0442\u0435\u0439 (eng)<\/a>.<\/p>\n<p>  <\/p>\n<p><code>@octokit\/core<\/code> \u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442 \u0432\u0435\u0441\u044c \u043a\u043e\u0434 \u0438\u0437 <code>lib\/* \u0438 plugins\/authentication\/*<\/code>. \u041e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u0440\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u044f \u0438\u0437\u0432\u043b\u0435\u043a \u0432 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u043c:<\/p>\n<p>  <\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/octokit\/plugin-rest-endpoint-methods.js#readme\" rel=\"nofollow\"><code>@octokit\/plugin-rest-endpoint-methods<\/code><\/a><\/li>\n<li><a href=\"https:\/\/github.com\/octokit\/plugin-paginate-rest.js#readme\" rel=\"nofollow\"><code>@octokit\/plugin-paginate-rest<\/code><\/a><\/li>\n<li><a href=\"https:\/\/github.com\/octokit\/plugin-request-log.js#readme\" rel=\"nofollow\"><code>@octokit\/plugin-request-log<\/code><\/a><\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u041f\u043b\u0430\u0433\u0438\u043d <code>validate<\/code> \u0443\u0441\u0442\u0430\u0440\u0435\u043b \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u0442\u0438\u043f\u0438\u0437\u0430\u0446\u0438\u0438 \u043e\u0442 TypeScript \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u0438 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435 \u0431\u044b\u043b\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043d\u0430 \u043a\u043b\u0438\u0435\u043d\u0442\u0435. \u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043c\u0435\u043d\u044c\u0448\u0438\u043b\u043e \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043a\u043e\u0434\u0430 \u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u043e\u0442 \u0442\u0435\u043a\u0443\u0449\u0435\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043c\u0435\u0442\u043e\u0434\u0430 <code>octokit.checks.create()<\/code>:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">{   checks: {     create: {       headers: { accept: &quot;application\/vnd.github.antiope-preview+json&quot; },       method: &quot;POST&quot;,       params: {         actions: { type: &quot;object[]&quot; },         &quot;actions[].description&quot;: { required: true, type: &quot;string&quot; },         &quot;actions[].identifier&quot;: { required: true, type: &quot;string&quot; },         &quot;actions[].label&quot;: { required: true, type: &quot;string&quot; },         completed_at: { type: &quot;string&quot; },         conclusion: {           enum: [             &quot;success&quot;,             &quot;failure&quot;,             &quot;neutral&quot;,             &quot;cancelled&quot;,             &quot;timed_out&quot;,             &quot;action_required&quot;           ],           type: &quot;string&quot;         },         details_url: { type: &quot;string&quot; },         external_id: { type: &quot;string&quot; },         head_sha: { required: true, type: &quot;string&quot; },         name: { required: true, type: &quot;string&quot; },         output: { type: &quot;object&quot; },         &quot;output.annotations&quot;: { type: &quot;object[]&quot; },         &quot;output.annotations[].annotation_level&quot;: {           enum: [&quot;notice&quot;, &quot;warning&quot;, &quot;failure&quot;],           required: true,           type: &quot;string&quot;         },         &quot;output.annotations[].end_column&quot;: { type: &quot;integer&quot; },         &quot;output.annotations[].end_line&quot;: { required: true, type: &quot;integer&quot; },         &quot;output.annotations[].message&quot;: { required: true, type: &quot;string&quot; },         &quot;output.annotations[].path&quot;: { required: true, type: &quot;string&quot; },         &quot;output.annotations[].raw_details&quot;: { type: &quot;string&quot; },         &quot;output.annotations[].start_column&quot;: { type: &quot;integer&quot; },         &quot;output.annotations[].start_line&quot;: { required: true, type: &quot;integer&quot; },         &quot;output.annotations[].title&quot;: { type: &quot;string&quot; },         &quot;output.images&quot;: { type: &quot;object[]&quot; },         &quot;output.images[].alt&quot;: { required: true, type: &quot;string&quot; },         &quot;output.images[].caption&quot;: { type: &quot;string&quot; },         &quot;output.images[].image_url&quot;: { required: true, type: &quot;string&quot; },         &quot;output.summary&quot;: { required: true, type: &quot;string&quot; },         &quot;output.text&quot;: { type: &quot;string&quot; },         &quot;output.title&quot;: { required: true, type: &quot;string&quot; },         owner: { required: true, type: &quot;string&quot; },         repo: { required: true, type: &quot;string&quot; },         started_at: { type: &quot;string&quot; },         status: { enum: [&quot;queued&quot;, &quot;in_progress&quot;, &quot;completed&quot;], type: &quot;string&quot; }       },       url: &quot;\/repos\/:owner\/:repo\/check-runs&quot;     }   } }<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 v17, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0442\u043e\u0433\u043e \u0436\u0435 \u043c\u0435\u0442\u043e\u0434\u0430 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c :<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">{   checks: {     create: [       &quot;POST \/repos\/{owner}\/{repo}\/check-runs&quot;,       { mediaType: { previews: [&quot;antiope&quot;] } },     ];   } }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0446\u0435, \u0440\u0430\u043d\u0435\u0435 \u0438\u0437\u0432\u043b\u0435\u0447\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u0434 \u0431\u044b\u043b \u0441\u043e\u0431\u0440\u0430\u043d \u0432 \u043e\u0431\u0435\u0449\u0430\u043d\u043d\u044b\u0435 10 \u0441\u0442\u0440\u043e\u043a:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">import { Octokit as Core } from &quot;@octokit\/core&quot;; import { requestLog } from &quot;@octokit\/plugin-request-log&quot;; import { paginateRest } from &quot;@octokit\/plugin-paginate-rest&quot;; import { restEndpointMethods } from &quot;@octokit\/plugin-rest-endpoint-methods&quot;;  import { VERSION } from &quot;.\/version&quot;;  export const Octokit = Core.plugin([   requestLog,   paginateRest,   restEndpointMethods, ]).defaults({ userAgent: `octokit-rest.js\/${VERSION}` });<\/code><\/pre>\n<p>  <\/p>\n<h2 id=\"testy\">\u0422\u0435\u0441\u0442\u044b<\/h2>\n<p>  <\/p>\n<p>\u041a\u0430\u0436\u0434\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u043a\u043e\u0434\u0430 \u0431\u044b\u043b\u0430 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0430 \u043c\u0435\u0436\u0434\u0443 \u0432\u0435\u0440\u0441\u0438\u044f\u043c\u0438 v16 \u0438 v17, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0443\u0431\u0435\u0434\u0438\u0442\u044c\u0441\u044f \u0432 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u0438 \u043d\u043e\u0432\u044b\u0445 \u043e\u0448\u0438\u0431\u043e\u043a \u2014 \u043f\u0440\u043e\u0432\u0435\u0441\u0442\u0438 \u043f\u043e\u043b\u043d\u043e\u0435 \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435.<\/p>\n<p>  <\/p>\n<p>\u041d\u0430 \u043c\u043e\u043c\u0435\u043d\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043c\u043e\u0434\u0443\u043b\u044f \u0432 2017 \u0433\u043e\u0434\u0443 \u0443 \u043d\u0430\u0441 \u043d\u0435 \u0431\u044b\u043b\u043e \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u0442\u0435\u0441\u0442\u043e\u0432, \u043d\u043e \u0431\u044b\u043b\u0438 <a href=\"https:\/\/github.com\/octokit\/rest.js\/tree\/v10.1.0\/examples\" rel=\"nofollow\">\u043f\u0440\u0438\u043c\u0435\u0440\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f<\/a>. \u041f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c \u044f \u043f\u0440\u0435\u0432\u0440\u0430\u0442\u0438\u043b \u0438\u0445 \u0432 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u0442\u0435\u0441\u0442\u044b, \u0430 \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 JavaScript Octokit SDK \u0437\u0430\u0434\u0443\u043c\u044b\u0432\u0430\u043b\u0441\u044f \u043a\u0430\u043a \u043e\u0441\u043d\u043e\u0432\u0430 SDK \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u044b\u0445 \u044f\u0437\u044b\u043a\u043e\u0432, \u044f \u0441\u043e\u0437\u0434\u0430\u043b <a href=\"https:\/\/github.com\/octokit\/fixtures\" rel=\"nofollow\"><code>octokit\/fixtures<\/code><\/a> \u2014 \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u0439 \u043e\u0442 \u044f\u0437\u044b\u043a\u0430, \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u043c\u044b\u0439 \u043d\u0430\u0431\u043e\u0440 \u043c\u0430\u043a\u0435\u0442\u043e\u0432 http \u0434\u043b\u044f \u043e\u0431\u0449\u0438\u0445 \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043e\u0441\u0442\u0430\u0432\u0448\u0435\u0439\u0441\u044f \u043b\u043e\u0433\u0438\u043a\u0438, \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u0447\u043d\u043e\u0439 \u0434\u043b\u044f <code>@octokit\/rest<\/code>, \u0431\u044b\u043b\u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u044b \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u0442\u0435\u0441\u0442\u044b \u0434\u043b\u044f 100% \u043f\u043e\u043a\u0440\u044b\u0442\u0438\u044f. \u041d\u0430 \u0441\u0435\u0433\u043e\u0434\u043d\u044f\u0448\u043d\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442, \u0435\u0441\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u0443\u0441\u0442\u0438\u0442\u0441\u044f \u043d\u0438\u0436\u0435 100% \u0442\u0435\u0441\u0442\u044b \u0443\u043f\u0430\u0434\u0443\u0442.<\/p>\n<p>  <\/p>\n<blockquote><p>\u041f\u0440\u0438\u043c. \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430: <a href=\"https:\/\/www.youtube.com\/watch?v=9mvm0TlHO4s\" rel=\"nofollow\">\u0434\u0430, \u044d\u0442\u043e \u0436\u0451\u0441\u0442\u043a\u043e<\/a><\/p><\/blockquote>\n<p>\u0420\u0430\u0431\u043e\u0442\u0430\u044f \u043d\u0430\u0434 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u043d\u0430 v17 \u0441 10 \u0441\u0442\u0440\u043e\u043a\u0430\u043c\u0438 \u043a\u043e\u0434\u0430, \u044f \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u043b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0442\u0435\u0441\u0442\u044b \u0438\u0437 v16, \u0437\u0430 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u0442\u0435\u0441\u0442\u043e\u0432 \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0435\u0433\u043e API. \u0412 \u0442\u043e \u0436\u0435 \u0432\u0440\u0435\u043c\u044f, \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0442\u0435\u0441\u0442\u043e\u0432 \u043d\u0435 \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u0445\u043e\u0440\u043e\u0448\u043e, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u043e\u0441\u043b\u0435 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u0439 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 v17, \u0442\u0435\u0441\u0442\u044b \u043d\u0435 \u043e\u0442\u043d\u043e\u0441\u044f\u0449\u0438\u0435\u0441\u044f \u043a <code>@octokit\/rest<\/code> \u0431\u044b\u043b\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u044b. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u043d\u0438\u0445 \u0431\u044b\u043b\u0438 \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0435\u043d\u044b \u0432 \u043f\u043b\u0430\u0433\u0438\u043d\u044b, <code>@octokit\/core<\/code> \u0438\u043b\u0438 <code>@octokit\/request<\/code>. \u041d\u0430 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e smoke-\u0442\u0435\u0441\u0442\u043e\u0432 \u0438 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0435\u0432 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c <code>@octokit\/fixtures<\/code>.<\/p>\n<p>  <\/p>\n<h2 id=\"buduschee\">\u0411\u0443\u0434\u0443\u0449\u0435\u0435<\/h2>\n<p>  <\/p>\n<p><code>@octokit\/rest<\/code> \u043d\u0430\u0447\u0438\u043d\u0430\u043b\u0441\u044f \u043a\u0430\u043a \u043f\u0430\u043a\u0435\u0442 \u0434\u043b\u044f REST API GitHub, \u043d\u043e \u0441 17 \u0432\u0435\u0440\u0441\u0438\u0438, \u044d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 JavaScript, \u0432\u043a\u043b\u044e\u0447\u0430\u044e\u0449\u0430\u044f \u0432\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0434\u043b\u044f API <code>@octokit\/rest<\/code>, \u0441 \u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u0435\u0439, \u0442\u0440\u043e\u0442\u0442\u043b\u0438\u043d\u0433\u043e\u043c \u0438 \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u044b\u043c\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u043c\u0438. \u0422\u0430\u043a\u0436\u0435 \u0431\u0443\u0434\u0443\u0442 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u0432\u0441\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0438 \u0431\u0443\u0434\u0443\u0449\u0438\u0435 \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u0438 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0438 GraphQL, \u0442\u0430\u043a \u043a\u0430\u043a \u043e\u043d \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0447\u0430\u0441\u0442\u044c\u044e <code>@octokit\/core<\/code>.<\/p>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0446\u0435, \u044f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u0441\u043f\u0430\u0441\u0438\u0431\u043e <a href=\"https:\/\/twitter.com\/fjakobs\" rel=\"nofollow\">\u0424\u0430\u0431\u0438\u0430\u043d\u0443 \u0414\u0436\u0435\u0439\u043a\u043e\u0431\u0441\u0443<\/a>, <a href=\"https:\/\/mikedeboer.nl\/\" rel=\"nofollow\">\u041c\u0430\u0439\u043a\u0443 \u0434\u0435 \u0411\u0443\u0440\u0443<\/a> \u0438 <a href=\"https:\/\/github.com\/kaizensoze\" rel=\"nofollow\">\u0414\u0436\u043e \u0413\u0430\u043b\u043b\u043e<\/a>, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043e\u0437\u0434\u0430\u043b\u0438 \u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u044c <code>github<\/code> \u0434\u043e \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u043e\u043d \u043f\u0440\u0435\u0432\u0440\u0430\u0442\u0438\u043b\u0441\u044f \u0432 <code>@octokit\/rest<\/code>.<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/496598\/\"> https:\/\/habr.com\/ru\/post\/496598\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/496598\/\">\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/9l\/zi\/3k\/9lzi3kc9ivgzrrzghpyddw_rdfe.png\"><\/p>\n<p>  <\/p>\n<p><code>@octokit\/rest<\/code> \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u043d\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u043e\u0439 GitHub, \u0438 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0430\u0434\u0430\u043f\u0442\u0430\u0446\u0438\u044e <a href=\"https:\/\/www.npmjs.com\/package\/github\" rel=\"nofollow\">github<\/a> \u2014 \u0441\u0430\u043c\u043e\u0433\u043e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0433\u043e \u043f\u0430\u043a\u0435\u0442\u0430 2017 \u0433\u043e\u0434\u0430 \u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <a href=\"https:\/\/github.com\/bkeepers\" rel=\"nofollow\">@bkeepers<\/a>. \u0412 \u044d\u0442\u043e\u043c \u043f\u043e\u0441\u0442\u0435 \u0431\u0443\u0434\u0435\u043c \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u044c \u043f\u0440\u043e <a href=\"https:\/\/github.com\/octokit\/rest.js\/\" rel=\"nofollow\"><code>@octokit\/rest<\/code><\/a> \u2014 \u0442\u0435\u043f\u0435\u0440\u044c \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 JavaScript SDK \u0434\u043b\u044f <a href=\"https:\/\/developer.github.com\/v3\" rel=\"nofollow\">GitHub REST API<\/a>.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-301689","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/301689","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=301689"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/301689\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=301689"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=301689"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=301689"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}