feat(node): Add status

This commit is contained in:
web@ppanel
2024-11-21 16:06:43 +07:00
parent 6024454d57
commit c06372b644
6 changed files with 43 additions and 0 deletions
+6
View File
@@ -555,6 +555,11 @@ declare namespace API {
enable: boolean;
};
type Push = {
push_at: number;
count: number;
};
type Response = {
/** 状态码 */
code?: number;
@@ -579,6 +584,7 @@ declare namespace API {
shadowsocks?: Shadowsocks;
created_at: number;
updated_at: number;
last: Push;
};
type ServerGroup = {
+8
View File
@@ -21,3 +21,11 @@ export async function getGlobalConfig(options?: { [key: string]: any }) {
...(options || {}),
});
}
/** Get Tos Content GET /v1/common/site/tos */
export async function getTos(options?: { [key: string]: any }) {
return request<API.Response & { data?: API.GetTosResponse }>('/v1/common/site/tos', {
method: 'GET',
...(options || {}),
});
}
+4
View File
@@ -25,6 +25,10 @@ declare namespace API {
subscribe: SubscribeConfig;
};
type GetTosResponse = {
tos_content: string;
};
type InviteConfig = {
forced_invite: boolean;
};