🐛 fix(auth): Remove unused telephone code login function and update typings for telephone login requests
This commit is contained in:
parent
7b6bb7bc69
commit
72396851ff
@ -62,21 +62,6 @@ export async function telephoneLogin(
|
||||
});
|
||||
}
|
||||
|
||||
/** User Telephone login POST /v1/auth/login/telephone/code */
|
||||
export async function telephoneCodeLogin(
|
||||
body: API.TelephoneCodeLoginRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.LoginResponse }>('/v1/auth/login/telephone/code', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** User register POST /v1/auth/register */
|
||||
export async function userRegister(
|
||||
body: API.UserRegisterRequest,
|
||||
|
||||
10
apps/admin/services/common/typings.d.ts
vendored
10
apps/admin/services/common/typings.d.ts
vendored
@ -277,6 +277,7 @@ declare namespace API {
|
||||
};
|
||||
|
||||
type SendCodeResponse = {
|
||||
code?: string;
|
||||
status: boolean;
|
||||
};
|
||||
|
||||
@ -425,15 +426,9 @@ declare namespace API {
|
||||
exist: boolean;
|
||||
};
|
||||
|
||||
type TelephoneCodeLoginRequest = {
|
||||
telephone: string;
|
||||
telephone_area_code: string;
|
||||
telephone_code: string;
|
||||
cf_token?: string;
|
||||
};
|
||||
|
||||
type TelephoneLoginRequest = {
|
||||
telephone: string;
|
||||
telephone_code: string;
|
||||
telephone_area_code: string;
|
||||
password: string;
|
||||
cf_token?: string;
|
||||
@ -450,6 +445,7 @@ declare namespace API {
|
||||
|
||||
type TelephoneResetPasswordRequest = {
|
||||
telephone: string;
|
||||
telephone_area_code: string;
|
||||
password: string;
|
||||
code?: string;
|
||||
cf_token?: string;
|
||||
|
||||
@ -62,21 +62,6 @@ export async function telephoneLogin(
|
||||
});
|
||||
}
|
||||
|
||||
/** User Telephone login POST /v1/auth/login/telephone/code */
|
||||
export async function telephoneCodeLogin(
|
||||
body: API.TelephoneCodeLoginRequest,
|
||||
options?: { [key: string]: any },
|
||||
) {
|
||||
return request<API.Response & { data?: API.LoginResponse }>('/v1/auth/login/telephone/code', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
data: body,
|
||||
...(options || {}),
|
||||
});
|
||||
}
|
||||
|
||||
/** User register POST /v1/auth/register */
|
||||
export async function userRegister(
|
||||
body: API.UserRegisterRequest,
|
||||
|
||||
10
apps/user/services/common/typings.d.ts
vendored
10
apps/user/services/common/typings.d.ts
vendored
@ -277,6 +277,7 @@ declare namespace API {
|
||||
};
|
||||
|
||||
type SendCodeResponse = {
|
||||
code?: string;
|
||||
status: boolean;
|
||||
};
|
||||
|
||||
@ -425,15 +426,9 @@ declare namespace API {
|
||||
exist: boolean;
|
||||
};
|
||||
|
||||
type TelephoneCodeLoginRequest = {
|
||||
telephone: string;
|
||||
telephone_area_code: string;
|
||||
telephone_code: string;
|
||||
cf_token?: string;
|
||||
};
|
||||
|
||||
type TelephoneLoginRequest = {
|
||||
telephone: string;
|
||||
telephone_code: string;
|
||||
telephone_area_code: string;
|
||||
password: string;
|
||||
cf_token?: string;
|
||||
@ -450,6 +445,7 @@ declare namespace API {
|
||||
|
||||
type TelephoneResetPasswordRequest = {
|
||||
telephone: string;
|
||||
telephone_area_code: string;
|
||||
password: string;
|
||||
code?: string;
|
||||
cf_token?: string;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user