🎉 chore(init): project initialization
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Query announcement GET /v1/public/announcement/list */
|
||||
export async function queryAnnouncement(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.QueryAnnouncementParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.QueryAnnouncementResponse }>(
|
||||
'/v1/public/announcement/list',
|
||||
{
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Get document detail GET /v1/public/document/detail */
|
||||
export async function queryDocumentDetail(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.QueryDocumentDetailParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.DocumentDetail }>('/v1/public/document/detail', {
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Get document list GET /v1/public/document/list */
|
||||
export async function queryDocumentList(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QueryDocumentListResponse }>(
|
||||
'/v1/public/document/list',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
// API 更新时间:
|
||||
// API 唯一标识:
|
||||
import * as announcement from './announcement';
|
||||
import * as document from './document';
|
||||
import * as order from './order';
|
||||
import * as payment from './payment';
|
||||
import * as subscribe from './subscribe';
|
||||
import * as ticket from './ticket';
|
||||
import * as user from './user';
|
||||
|
||||
export default {
|
||||
announcement,
|
||||
document,
|
||||
order,
|
||||
payment,
|
||||
subscribe,
|
||||
ticket,
|
||||
user,
|
||||
};
|
||||
@@ -0,0 +1,129 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Checkout order POST /v1/public/order/checkout */
|
||||
export async function checkoutOrder(
|
||||
body: API.CheckoutOrderRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.CheckoutOrderResponse }>('/v1/public/order/checkout', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Close order POST /v1/public/order/close */
|
||||
export async function closeOrder(body: API.CloseOrderRequest, options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/order/close', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Get order GET /v1/public/order/detail */
|
||||
export async function queryOrderDetail(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.QueryOrderDetailParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.OrderDetails }>('/v1/public/order/detail', {
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Get order list GET /v1/public/order/list */
|
||||
export async function queryOrderList(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.QueryOrderListParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.QueryOrderListResponse }>('/v1/public/order/list', {
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Pre create order POST /v1/public/order/pre */
|
||||
export async function preCreateOrder(
|
||||
body: API.PurchaseOrderRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.PreOrderResponse }>('/v1/public/order/pre', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** purchase Subscription POST /v1/public/order/purchase */
|
||||
export async function purchase(body: API.PurchaseOrderRequest, options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.PurchaseOrderResponse }>('/v1/public/order/purchase', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** 此处后端没有提供注释 POST /v1/public/order/recharge */
|
||||
export async function recharge(body: API.RechargeOrderRequest, options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.RechargeOrderResponse }>('/v1/public/order/recharge', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Renewal Subscription POST /v1/public/order/renewal */
|
||||
export async function renewal(body: API.RenewalOrderRequest, options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.RenewalOrderResponse }>('/v1/public/order/renewal', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Reset traffic POST /v1/public/order/reset */
|
||||
export async function resetTraffic(
|
||||
body: API.ResetTrafficOrderRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.ResetTrafficOrderResponse }>(
|
||||
'/v1/public/order/reset',
|
||||
{
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Get available payment methods GET /v1/public/payment/methods */
|
||||
export async function getAvailablePaymentMethods(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.GetAvailablePaymentMethodsResponse }>(
|
||||
'/v1/public/payment/methods',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Get application config GET /v1/public/subscribe/application/config */
|
||||
export async function queryApplicationConfig(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QueryApplicationConfigResponse }>(
|
||||
'/v1/public/subscribe/application/config',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/** Get subscribe group list GET /v1/public/subscribe/group/list */
|
||||
export async function querySubscribeGroupList(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QuerySubscribeGroupListResponse }>(
|
||||
'/v1/public/subscribe/group/list',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/** Get subscribe list GET /v1/public/subscribe/list */
|
||||
export async function querySubscribeList(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QuerySubscribeListResponse }>(
|
||||
'/v1/public/subscribe/list',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Update ticket status PUT /v1/public/ticket/ */
|
||||
export async function updateUserTicketStatus(
|
||||
body: API.UpdateUserTicketStatusRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/ticket/', {
|
||||
method: 'PUT',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Create ticket POST /v1/public/ticket/ */
|
||||
export async function createUserTicket(
|
||||
body: API.CreateUserTicketRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/ticket/', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Get ticket detail GET /v1/public/ticket/detail */
|
||||
export async function getUserTicketDetails(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.GetUserTicketDetailsParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.UserTicket }>('/v1/public/ticket/detail', {
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Create ticket follow POST /v1/public/ticket/follow */
|
||||
export async function createUserTicketFollow(
|
||||
body: API.CreateUserTicketFollowRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/ticket/follow', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Get ticket list GET /v1/public/ticket/list */
|
||||
export async function getUserTicketList(
|
||||
// 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
|
||||
params: API.GetUserTicketListParams,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.GetUserTicketListResponse }>(
|
||||
'/v1/public/ticket/list',
|
||||
{
|
||||
method: 'GET',
|
||||
params: {
|
||||
...params,
|
||||
},
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
Vendored
+425
@@ -0,0 +1,425 @@
|
||||
declare namespace API {
|
||||
type AnnouncementDetails = {
|
||||
id: number;
|
||||
title: string;
|
||||
content: string;
|
||||
created_at: number;
|
||||
updated_at: number;
|
||||
};
|
||||
|
||||
type ApplicationConfig = {
|
||||
id: number;
|
||||
name: string;
|
||||
platform: string;
|
||||
subscribe_type: string;
|
||||
icon: string;
|
||||
url: string;
|
||||
};
|
||||
|
||||
type CheckoutOrderRequest = {
|
||||
orderNo: string;
|
||||
};
|
||||
|
||||
type CheckoutOrderResponse = {
|
||||
type: string;
|
||||
checkout_url?: string;
|
||||
stripe?: StripePayment;
|
||||
};
|
||||
|
||||
type CloseOrderRequest = {
|
||||
orderNo: string;
|
||||
};
|
||||
|
||||
type CreateUserTicketFollowRequest = {
|
||||
ticket_id: number;
|
||||
from: string;
|
||||
type: number;
|
||||
content: string;
|
||||
};
|
||||
|
||||
type CreateUserTicketRequest = {
|
||||
title: string;
|
||||
description: string;
|
||||
};
|
||||
|
||||
type DocumentDetail = {
|
||||
id: number;
|
||||
title: string;
|
||||
content: string;
|
||||
tags: string[];
|
||||
created_at: number;
|
||||
updated_at: number;
|
||||
};
|
||||
|
||||
type DocumentItem = {
|
||||
id: number;
|
||||
title: string;
|
||||
tags: string[];
|
||||
updated_at: number;
|
||||
};
|
||||
|
||||
type GetAvailablePaymentMethodsResponse = {
|
||||
list: PaymentItem[];
|
||||
};
|
||||
|
||||
type GetUserTicketDetailRequest = {
|
||||
id: number;
|
||||
};
|
||||
|
||||
type GetUserTicketDetailsParams = {
|
||||
id: number;
|
||||
};
|
||||
|
||||
type GetUserTicketListParams = {
|
||||
page: number;
|
||||
size: number;
|
||||
status?: number;
|
||||
search?: string;
|
||||
};
|
||||
|
||||
type GetUserTicketListRequest = {
|
||||
page: number;
|
||||
size: number;
|
||||
status?: number;
|
||||
search?: string;
|
||||
};
|
||||
|
||||
type GetUserTicketListResponse = {
|
||||
total: number;
|
||||
list: UserTicket[];
|
||||
};
|
||||
|
||||
type OrderDetails = {
|
||||
id: number;
|
||||
orderNo: string;
|
||||
type: number;
|
||||
subscribe_id: number;
|
||||
subscribe: SubscribeInfo;
|
||||
quantity: number;
|
||||
price: number;
|
||||
amount: number;
|
||||
fee_amount: number;
|
||||
coupon: string;
|
||||
reduction: number;
|
||||
trade_no: string;
|
||||
method: string;
|
||||
status: number;
|
||||
created_at: number;
|
||||
};
|
||||
|
||||
type PaymentItem = {
|
||||
id: number;
|
||||
name: string;
|
||||
mark: string;
|
||||
icon: string;
|
||||
domain: string;
|
||||
fee_mode: number;
|
||||
fee_percent: number;
|
||||
fee_amount: number;
|
||||
enable: boolean;
|
||||
};
|
||||
|
||||
type PreOrderResponse = {
|
||||
price: number;
|
||||
amount: number;
|
||||
fee_amount: number;
|
||||
coupon: number;
|
||||
reduction: number;
|
||||
};
|
||||
|
||||
type PreRenewalOrderResponse = {
|
||||
orderNo: string;
|
||||
};
|
||||
|
||||
type PurchaseOrderRequest = {
|
||||
subscribe_id: number;
|
||||
quantity: number;
|
||||
payment: string;
|
||||
coupon?: string;
|
||||
};
|
||||
|
||||
type PurchaseOrderResponse = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type QueryAnnouncementParams = {
|
||||
page: number;
|
||||
size: number;
|
||||
};
|
||||
|
||||
type QueryAnnouncementRequest = {
|
||||
page: number;
|
||||
size: number;
|
||||
};
|
||||
|
||||
type QueryAnnouncementResponse = {
|
||||
total: number;
|
||||
announcements: AnnouncementDetails[];
|
||||
};
|
||||
|
||||
type QueryApplicationConfigResponse = {
|
||||
windows: ApplicationConfig[];
|
||||
mac: ApplicationConfig[];
|
||||
linux: ApplicationConfig[];
|
||||
android: ApplicationConfig[];
|
||||
ios: ApplicationConfig[];
|
||||
};
|
||||
|
||||
type QueryDocumentDetailParams = {
|
||||
id: number;
|
||||
};
|
||||
|
||||
type QueryDocumentDetailRequest = {
|
||||
id: number;
|
||||
};
|
||||
|
||||
type QueryDocumentListResponse = {
|
||||
total: number;
|
||||
list: DocumentItem[];
|
||||
};
|
||||
|
||||
type QueryOrderDetailParams = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type QueryOrderDetailRequest = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type QueryOrderListParams = {
|
||||
page: number;
|
||||
size: number;
|
||||
};
|
||||
|
||||
type QueryOrderListRequest = {
|
||||
page: number;
|
||||
size: number;
|
||||
};
|
||||
|
||||
type QueryOrderListResponse = {
|
||||
total: number;
|
||||
list: OrderDetails[];
|
||||
};
|
||||
|
||||
type QuerySubscribeGroupListResponse = {
|
||||
list: UserSubscribeGroupDetails[];
|
||||
total: number;
|
||||
};
|
||||
|
||||
type QuerySubscribeListResponse = {
|
||||
list: SubscribeDetails[];
|
||||
total: number;
|
||||
};
|
||||
|
||||
type QueryUserBalanceLogListResponse = {
|
||||
list: UserBalanceLog[];
|
||||
total: number;
|
||||
};
|
||||
|
||||
type QueryUserSubscribeListResponse = {
|
||||
list: UserSubscribe[];
|
||||
total: number;
|
||||
};
|
||||
|
||||
type RechargeOrderRequest = {
|
||||
amount: number;
|
||||
payment: string;
|
||||
};
|
||||
|
||||
type RechargeOrderResponse = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type RenewalOrderRequest = {
|
||||
subscribe_id: number;
|
||||
quantity: number;
|
||||
payment: string;
|
||||
coupon?: string;
|
||||
subscribe_mark: string;
|
||||
};
|
||||
|
||||
type RenewalOrderResponse = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type ResetTrafficOrderRequest = {
|
||||
subscribe_id: number;
|
||||
subscribe_mark: string;
|
||||
payment: string;
|
||||
};
|
||||
|
||||
type ResetTrafficOrderResponse = {
|
||||
order_no: string;
|
||||
};
|
||||
|
||||
type Response = {
|
||||
/** 状态码 */
|
||||
code?: number;
|
||||
/** 消息 */
|
||||
msg?: string;
|
||||
/** 数据 */
|
||||
data?: Record<string, any>;
|
||||
};
|
||||
|
||||
type StripePayment = {
|
||||
method: string;
|
||||
client_secret: string;
|
||||
publishable_key: string;
|
||||
};
|
||||
|
||||
type SubscribeDetails = {
|
||||
id: number;
|
||||
name: string;
|
||||
description: string;
|
||||
unit_price: number;
|
||||
discount: UserSubscribeDiscount[];
|
||||
replacement: number;
|
||||
inventory: number;
|
||||
traffic: number;
|
||||
group_id: number;
|
||||
speed_limit: number;
|
||||
device_limit: number;
|
||||
quota: number;
|
||||
show: boolean;
|
||||
sell: boolean;
|
||||
};
|
||||
|
||||
type SubscribeDiscountInfo = {
|
||||
months: number;
|
||||
discount: number;
|
||||
};
|
||||
|
||||
type SubscribeInfo = {
|
||||
id: number;
|
||||
name: string;
|
||||
description: string;
|
||||
discount: string;
|
||||
unit_price: number;
|
||||
replacement: number;
|
||||
inventory: number;
|
||||
traffic: number;
|
||||
group_id: number;
|
||||
speed_limit: number;
|
||||
device_limit: number;
|
||||
quota: number;
|
||||
show: boolean;
|
||||
sell: boolean;
|
||||
};
|
||||
|
||||
type SubscribeItem = {
|
||||
id: number;
|
||||
name: string;
|
||||
description: string;
|
||||
discount: string;
|
||||
unit_price: number;
|
||||
replacement: number;
|
||||
inventory: number;
|
||||
traffic: number;
|
||||
group_id: number;
|
||||
speed_limit: number;
|
||||
device_limit: number;
|
||||
quota: number;
|
||||
show: boolean;
|
||||
sell: boolean;
|
||||
};
|
||||
|
||||
type UpdateUserNotifyRequest = {
|
||||
enable_balance_notify: boolean;
|
||||
enable_login_notify: boolean;
|
||||
enable_subscribe_notify: boolean;
|
||||
enable_trade_notify: boolean;
|
||||
};
|
||||
|
||||
type UpdateUserNotifySettingRequet = {
|
||||
telegram: number;
|
||||
enable_email_notify: boolean;
|
||||
enable_telegram_notify: boolean;
|
||||
};
|
||||
|
||||
type UpdateUserPasswordRequest = {
|
||||
password: string;
|
||||
};
|
||||
|
||||
type UpdateUserTicketStatusRequest = {
|
||||
id: number;
|
||||
status: number;
|
||||
};
|
||||
|
||||
type UserBalanceLog = {
|
||||
id: number;
|
||||
user_id: number;
|
||||
amount: number;
|
||||
type: number;
|
||||
order_id: number;
|
||||
balance: number;
|
||||
created_at: number;
|
||||
};
|
||||
|
||||
type UserFollow = {
|
||||
id: number;
|
||||
ticket_id: number;
|
||||
from: string;
|
||||
type: number;
|
||||
content: string;
|
||||
created_at: number;
|
||||
};
|
||||
|
||||
type UserInfo = {
|
||||
id: number;
|
||||
email: string;
|
||||
avatar: string;
|
||||
balance: number;
|
||||
telegram: number;
|
||||
refer_code: string;
|
||||
referer_id: number;
|
||||
enable: boolean;
|
||||
valid_email: boolean;
|
||||
enable_email_notify: boolean;
|
||||
enable_telegram_notify: boolean;
|
||||
enable_balance_notify: boolean;
|
||||
enable_login_notify: boolean;
|
||||
enable_subscribe_notify: boolean;
|
||||
enable_trade_notify: boolean;
|
||||
created_at: number;
|
||||
updated_at: number;
|
||||
};
|
||||
|
||||
type UserSubscribe = {
|
||||
id: number;
|
||||
user_id: number;
|
||||
order_id: number;
|
||||
subscribe_id: number;
|
||||
subscribe: SubscribeItem;
|
||||
start_time: number;
|
||||
expire_time: number;
|
||||
traffic: number;
|
||||
download: number;
|
||||
upload: number;
|
||||
mark: string;
|
||||
status: number;
|
||||
created_at: number;
|
||||
updated_at: number;
|
||||
};
|
||||
|
||||
type UserSubscribeDiscount = {
|
||||
months: number;
|
||||
discount: number;
|
||||
};
|
||||
|
||||
type UserSubscribeGroupDetails = {
|
||||
id: number;
|
||||
name: string;
|
||||
description: string;
|
||||
};
|
||||
|
||||
type UserTicket = {
|
||||
id: number;
|
||||
title: string;
|
||||
description: string;
|
||||
user_id: number;
|
||||
follow?: UserFollow[];
|
||||
status: number;
|
||||
created_at: number;
|
||||
updated_at: number;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,78 @@
|
||||
// @ts-ignore
|
||||
/* eslint-disable */
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** Query User Balance Log GET /v1/public/user/balance_log */
|
||||
export async function queryUserBalanceLog(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QueryUserBalanceLogListResponse }>(
|
||||
'/v1/public/user/balance_log',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/** Query User Info GET /v1/public/user/info */
|
||||
export async function queryUserInfo(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.UserInfo }>('/v1/public/user/info', {
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Update User Notify PUT /v1/public/user/notify */
|
||||
export async function updateUserNotify(
|
||||
body: API.UpdateUserNotifyRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/user/notify', {
|
||||
method: 'PUT',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Update User Notify Setting PUT /v1/public/user/notify_setting */
|
||||
export async function updateUserNotifySetting(
|
||||
body: API.UpdateUserNotifySettingRequet,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/user/notify_setting', {
|
||||
method: 'PUT',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Update User Password PUT /v1/public/user/password */
|
||||
export async function updateUserPassword(
|
||||
body: API.UpdateUserPasswordRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: any }>('/v1/public/user/password', {
|
||||
method: 'PUT',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** Query User Subscribe GET /v1/public/user/subscribe */
|
||||
export async function queryUserSubscribe(options?: { [key: string]: any }) {
|
||||
return request<API.Response & { data?: API.QueryUserSubscribeListResponse }>(
|
||||
'/v1/public/user/subscribe',
|
||||
{
|
||||
method: 'GET',
|
||||
...(options || {}),
|
||||
},
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user