GitHub API для лицензий в настоящее время возвращает только 12 результатов:
$ curl -iG https://api.github.com/licenses
HTTP/1.1 200 OK
Server: GitHub.com
Date: Tue, 05 Jun 2018 04:56:50 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 2325
Status: 200 OK
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 54
X-RateLimit-Reset: 1528176682
Cache-Control: public, max-age=60, s-maxage=60
Vary: Accept
ETag: "732c80ab130b5c627593816bfe032ba3"
X-GitHub-Media-Type: github.v3; format=json
Access-Control-Expose-Headers: ETag, Link, Retry-After, X-GitHub-OTP, X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval
Access-Control-Allow-Origin: *
Strict-Transport-Security: max-age=31536000; includeSubdomains; preload
X-Frame-Options: deny
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin
Content-Security-Policy: default-src 'none'
X-Runtime-rack: 0.018674
X-GitHub-Request-Id: 8CD8:1459:19390F:3A5318:5B161811
[
{
"key": "gpl-3.0",
"name": "GNU General Public License v3.0",
"spdx_id": "GPL-3.0",
"url": "https://api.github.com/licenses/gpl-3.0",
"node_id": "MDc6TGljZW5zZTk="
},
{
"key": "gpl-2.0",
"name": "GNU General Public License v2.0",
"spdx_id": "GPL-2.0",
"url": "https://api.github.com/licenses/gpl-2.0",
"node_id": "MDc6TGljZW5zZTg="
},
{
"key": "bsd-2-clause",
"name": "BSD 2-Clause \"Simplified\" License",
"spdx_id": "BSD-2-Clause",
"url": "https://api.github.com/licenses/bsd-2-clause",
"node_id": "MDc6TGljZW5zZTQ="
},
{
"key": "epl-2.0",
"name": "Eclipse Public License 2.0",
"spdx_id": "EPL-2.0",
"url": "https://api.github.com/licenses/epl-2.0",
"node_id": "MDc6TGljZW5zZTMy"
},
{
"key": "apache-2.0",
"name": "Apache License 2.0",
"spdx_id": "Apache-2.0",
"url": "https://api.github.com/licenses/apache-2.0",
"node_id": "MDc6TGljZW5zZTI="
},
{
"key": "lgpl-3.0",
"name": "GNU Lesser General Public License v3.0",
"spdx_id": "LGPL-3.0",
"url": "https://api.github.com/licenses/lgpl-3.0",
"node_id": "MDc6TGljZW5zZTEy"
},
{
"key": "bsd-3-clause",
"name": "BSD 3-Clause \"New\" or \"Revised\" License",
"spdx_id": "BSD-3-Clause",
"url": "https://api.github.com/licenses/bsd-3-clause",
"node_id": "MDc6TGljZW5zZTU="
},
{
"key": "lgpl-2.1",
"name": "GNU Lesser General Public License v2.1",
"spdx_id": "LGPL-2.1",
"url": "https://api.github.com/licenses/lgpl-2.1",
"node_id": "MDc6TGljZW5zZTEx"
},
{
"key": "agpl-3.0",
"name": "GNU Affero General Public License v3.0",
"spdx_id": "AGPL-3.0",
"url": "https://api.github.com/licenses/agpl-3.0",
"node_id": "MDc6TGljZW5zZTE="
},
{
"key": "unlicense",
"name": "The Unlicense",
"spdx_id": "Unlicense",
"url": "https://api.github.com/licenses/unlicense",
"node_id": "MDc6TGljZW5zZTE1"
},
{
"key": "mit",
"name": "MIT License",
"spdx_id": "MIT",
"url": "https://api.github.com/licenses/mit",
"node_id": "MDc6TGljZW5zZTEz"
},
{
"key": "mpl-2.0",
"name": "Mozilla Public License 2.0",
"spdx_id": "MPL-2.0",
"url": "https://api.github.com/licenses/mpl-2.0",
"node_id": "MDc6TGljZW5zZTE0"
}
]
Нет ссылок на следующую страницу в заголовках.Так что, похоже, это полный набор результатов для API лицензий.Это ожидается?Я хочу найти способ получить всю информацию о лицензии от GitHub.Единственный другой способ, которым я вижу, это получить каждый репозиторий.