-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathInviteInfo.php
More file actions
44 lines (40 loc) · 1.09 KB
/
InviteInfo.php
File metadata and controls
44 lines (40 loc) · 1.09 KB
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
<?php
require("./Expand.php");
$AccessToken = $_POST['AccessToken'];
if ($AccessToken == '') {
echo json_encode(
array(
'Status' => 18
)
); #参数不全
} else {
$Url = 'https://api-drive.mypikpak.com/vip/v1/activity/inviteInfo';
$Header = array(
'User-Agent: PikPakWeb (github.com/UallenQbit/PikPakWeb)',
'Authorization: Bearer ' . $AccessToken
);
$Result = CurlGet($Url, $Header);
$JsonData = json_decode($Result, true);
if (isset($JsonData['add_days']) == false) {
if ($JsonData['error'] == 'unauthenticated') {
echo json_encode(
array(
'Status' => 48
)
); #AccessToken不可用
} else {
echo json_encode(
array(
'Status' => 183
)
); #数据获取失败
}
} else {
echo json_encode(
array(
'Status' => 0,
'Data' => $Result
)
);
}
}