我剛開始使用github api從我們的倉庫中提取問題記錄。 當我打,curl url獲取我的倉庫中的問題的json文件
curl -k -H "Content-Type: application/json" https://2b9e36bvb9e36b82d38b9c0ab2b9e36b82d3:[email protected]/newlands/hello-world/issues
我得到以下輸出。
> <html><body>You are being <a
> href="https://rnd.git.corp/login?return_to=https%3A%2F%2Frnd.git.corp%2Fnewlands%2Fhello-world%2Fissues">redirected</a>.</body></html>
我的curl命令有什麼問題嗎?理想情況下應該根據git api文檔在我的存儲庫中打印問題列表。感謝任何幫助。
'https:// rnd.git.corp/newlands/hello-world'這是我的respositry網址,與api.github.com不同。 – NewLands
這正是我所說的,問題可能是。 'https:// github.com/Vampire/teamcity-sourceforge/issues'是我的一個網絡版軟件庫問題,'https:// api.github.com/Vampire/teamcity-sourceforge/issues'是一個無效的URL和'https:// api.github.com/repos/Vampire/teamcity-sourceforge/issues'是將URL作爲JSON字符串獲取的API URL。可能與GitHub Enterprise類似。 – Vampire
錯過了告訴你,我嘗試在URL中添加/ repos,即「https:// rnd.git.corp/repos/newlands/hello-world/issues」。它仍然是一樣的。我錯過了什麼? – NewLands