添加github请求,添加统一获取url接口添加不拦截接口
This commit is contained in:
parent
22474e459f
commit
2ac3e0175e
|
|
@ -4,6 +4,7 @@ import (
|
||||||
"StuAcaWorksAI/proto"
|
"StuAcaWorksAI/proto"
|
||||||
"bytes"
|
"bytes"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
"net/http"
|
"net/http"
|
||||||
)
|
)
|
||||||
|
|
@ -59,5 +60,8 @@ func GetGitHubUserInfo(accessToken string) {
|
||||||
"Authorization": "Bearer " + accessToken,
|
"Authorization": "Bearer " + accessToken,
|
||||||
}
|
}
|
||||||
err, data := DoGetRequest(url, headers)
|
err, data := DoGetRequest(url, headers)
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
fmt.Println("User Info:", string(data))
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue