简体   繁体   English

Github API个人访问令牌抛出未经授权的错误

[英]Github API personal access tokens throws Unauthorized error

I've created a personal access token on github, it works when I use it like this: 我在github上创建了一个个人访问令牌,当我像这样使用它时它可以工作:

https://api.github.com/users/xyz/repos?access_token=TOKEN

But it throws Unauthorized error when I try using Pagination like this: 但是当我尝试使用像这样的分页时,它会抛出Unauthorized错误:

https://api.github.com/users/xyz/repos?access_token=TOKEN?page=1&per_page=10

Try and replace the second ? 尝试并替换第二个? by & : by &

https://api.github.com/users/xyz/repos?access_token=TOKEN&page=1&per_page=10
                                                       ^^^^^

That should allow you to chain URL parameters. 这应该允许您链接 URL参数。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM