Skip to content

Commit

Permalink
📝 集成华为
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangyd-c committed Aug 5, 2019
1 parent 665daa3 commit 1ab1cc1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/main/java/me/zhyd/oauth/request/AuthHuaweiRequest.java
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ protected AuthUser getUserInfo(AuthToken authToken) {
.nickname(object.getString("userName"))
.gender(gender)
.avatar(object.getString("headPictureURL"))
.token(authToken)
.source(source)
.build();
}

Expand Down
2 changes: 1 addition & 1 deletion src/test/java/me/zhyd/oauth/sdk/ThirdPartSdkTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public void huawei() {
.execute();
System.out.println(response.body());

// {"access_token":"CF1IGrYGi\/s0JddMwEQ1i0xBwWI7CepxuAm9HP9wvjuPOYyXItkSh6PVLfeD7AcDD3BS0APzgyyrS\/GK9FF9Hk91WrAROGfTfTVlh0DdEw9k4NW77EjQmA==","expires_in":3600,"refresh_token":"CF41WqZNkgaJhDtW1Kv5rypr8PklmwVsKlAbFLXmxte0mrTdvJd9k8vTrIlw5NoMnNn7nZ2b3fpgsl4zabm10QQEHY2H+s5qwx1dxXR\/arV6JQ9OYMDk+A==","scope":"https:\/\/www.huawei.com\/auth\/account\/mobile.number https:\/\/www.huawei.com\/auth\/account\/base.profile","token_type":"Bearer"}
// {"access_token":"accessToken","expires_in":3600,"refresh_token":"refreshToken","scope":"https:\/\/www.huawei.com\/auth\/account\/base.profile","token_type":"Bearer"}

//
HttpResponse response2 = HttpRequest.post("https://api.vmall.com/rest.php")
Expand Down

0 comments on commit 1ab1cc1

Please sign in to comment.