-
Notifications
You must be signed in to change notification settings - Fork 1
/
constant.js
69 lines (64 loc) · 2.39 KB
/
constant.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
// const host = 'https://app.jike.ruguoapp.com'
// const headers = {
// 'platform': 'web',
// 'app-version': '5.3.0',
// 'accept': 'application/json',
// 'content-type': 'application/json'
// }
const host = 'https://api.jellow.club'
const headers = {
'App-Version': '8.0.0',
'ApplicationId': 'io.iftech.jellow',
'Content-Type': 'application/json; charset=utf-8',
'User-Agent': 'okhttp/4.0.1',
}
const endpoint = {
// login
'createSession': 'sessions.create',
'waitLogin': 'sessions.wait_for_login',
'confirmLogin': 'sessions.wait_for_confirmation',
// 'tokenRefresh': 'app_auth_tokens.refresh',
'tokenRefresh': '1.0/app_auth_tokens.refresh',
// myself
'myCollections': '1.0/users/collections/list',
// main page info stream
'newsFeed': '1.0/newsFeed/list',
'newsFeedUnreadCount': '1.0/newsFeed/countUnreads',
'followingUpdate': '1.0/personalUpdate/followingUpdates',
// user
'userProfile': '1.0/users/profile',
'userPost': '1.0/personalUpdate/single',
'userCreatedTopic': '1.0/customTopics/custom/listCreated',
'userSubscribedTopic': '1.0/users/topics/listSubscribed',
'userFollowing': '1.0/userRelation/getFollowingList',
'userFollower': '1.0/userRelation/getFollowerList',
// topic
'topicSelected': '1.0/messages/history',
// 'topicSquare': '1.0/squarePosts/list',
'topicSquare': '1.0/topicFeed/list',
// comment
'listComment': '1.0/comments/listPrimary',
'listCommentReply': '1.0/comments/list',
// creation
'createPost': '1.0/originalPosts/create',
'deletePost': '1.0/originalPosts/remove',
'extractLink': '1.0/readability/extract',
'qiniuUpToken': '1.0/misc/qiniu_uptoken',
// 'pictureUptoken': 'https://upload.jike.ruguoapp.com/token',
// 'pictureUpload': 'https://up.qbox.me/',
'pictureUpload': 'https://upload.qiniup.com',
// interaction
// 'like_it': '1.0/{_p_}/like',
// 'unlike_it': '1.0/{_p_}/unlike',
// 'collect_it': '1.0/{_p_}/collect',
// 'uncollect_it': '1.0/{_p_}/uncollect',
'createRepost': '1.0/reposts/add',
'createComment': '1.0/comments/add',
'deleteComment': '1.0/comments/remove',
// search
'searchTopic': '1.0/users/topics/search',
'searchCollection': '1.0/users/collections/search',
// recommend
'recommendedTopic': '1.0/topics/recommendation/list',
}
module.exports = { host, headers, endpoint }