chore(backend, misskey-js): add type for signup (#11043)
* chore(backend, misskey-js): add type for signup * rerun
This commit is contained in:

committed by
GitHub

parent
a2c0573f84
commit
7bb8c71543
@@ -2,7 +2,7 @@ import type {
|
||||
Ad, Announcement, Antenna, App, AuthSession, Blocking, Channel, Clip, DateString, DetailedInstanceMetadata, DriveFile, DriveFolder, Following, FollowingFolloweePopulated, FollowingFollowerPopulated, FollowRequest, GalleryPost, Instance,
|
||||
LiteInstanceMetadata,
|
||||
MeDetailed,
|
||||
Note, NoteFavorite, OriginType, Page, ServerInfo, Stats, User, UserDetailed, UserGroup, UserList, UserSorting, Notification, NoteReaction, Signin, MessagingMessage,
|
||||
Note, NoteFavorite, OriginType, Page, ServerInfo, Stats, User, UserDetailed, MeSignup, UserGroup, UserList, UserSorting, Notification, NoteReaction, Signin, MessagingMessage,
|
||||
} from './entities.js';
|
||||
|
||||
type TODO = Record<string, any> | null;
|
||||
@@ -549,6 +549,21 @@ export type Endpoints = {
|
||||
'room/show': { req: TODO; res: TODO; };
|
||||
'room/update': { req: TODO; res: TODO; };
|
||||
|
||||
// signup
|
||||
'signup': {
|
||||
req: {
|
||||
username: string;
|
||||
password: string;
|
||||
host?: string;
|
||||
invitationCode?: string;
|
||||
emailAddress?: string;
|
||||
'hcaptcha-response'?: string;
|
||||
'g-recaptcha-response'?: string;
|
||||
'turnstile-response'?: string;
|
||||
};
|
||||
res: MeSignup | null;
|
||||
};
|
||||
|
||||
// stats
|
||||
'stats': { req: NoParams; res: Stats; };
|
||||
|
||||
|
@@ -107,6 +107,20 @@ export type MeDetailed = UserDetailed & {
|
||||
[other: string]: any;
|
||||
};
|
||||
|
||||
export type MeDetailedWithSecret = MeDetailed & {
|
||||
email: string;
|
||||
emailVerified: boolean;
|
||||
securityKeysList: {
|
||||
id: string;
|
||||
name: string;
|
||||
lastUsed: string;
|
||||
}[];
|
||||
};
|
||||
|
||||
export type MeSignup = MeDetailedWithSecret & {
|
||||
token: string;
|
||||
};
|
||||
|
||||
export type DriveFile = {
|
||||
id: ID;
|
||||
createdAt: DateString;
|
||||
|
Reference in New Issue
Block a user