mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-27 22:39:33 +09:00
Update type definitions
This commit is contained in:
parent
bc3b3bb1c0
commit
2a84e5034e
@ -1,5 +1,5 @@
|
|||||||
import {
|
import {
|
||||||
Ad, Announcement, Antenna, App, AuthSession, Channel, Clip, DateString, DetailedInstanceMetadata, DriveFile, DriveFolder, Following, FollowingFolloweePopulated, FollowingFollowerPopulated, FollowRequest, GalleryPost, InstanceMetadata,
|
Ad, Announcement, Antenna, App, AuthSession, Channel, Clip, DateString, DetailedInstanceMetadata, DriveFile, DriveFolder, Following, FollowingFolloweePopulated, FollowingFollowerPopulated, FollowRequest, GalleryPost, Instance, InstanceMetadata,
|
||||||
LiteInstanceMetadata,
|
LiteInstanceMetadata,
|
||||||
MeDetailed,
|
MeDetailed,
|
||||||
Note, NoteFavorite, OriginType, Page, ServerInfo, Stats, User, UserDetailed, UserGroup, UserList, UserSorting
|
Note, NoteFavorite, OriginType, Page, ServerInfo, Stats, User, UserDetailed, UserGroup, UserList, UserSorting
|
||||||
@ -251,17 +251,17 @@ export type Endpoints = {
|
|||||||
|
|
||||||
// drive
|
// drive
|
||||||
'drive': { req: {}; res: { capacity: number; usage: number; }; };
|
'drive': { req: {}; res: { capacity: number; usage: number; }; };
|
||||||
'drive/files': { req: TODO; res: TODO; };
|
'drive/files': { req: { folderId?: DriveFolder['id'] | null; type?: DriveFile['type'] | null; limit?: number; sinceId?: DriveFile['id']; untilId?: DriveFile['id']; }; res: DriveFile[]; };
|
||||||
'drive/files/attached-notes': { req: TODO; res: TODO; };
|
'drive/files/attached-notes': { req: TODO; res: TODO; };
|
||||||
'drive/files/check-existence': { req: TODO; res: TODO; };
|
'drive/files/check-existence': { req: TODO; res: TODO; };
|
||||||
'drive/files/create': { req: TODO; res: TODO; };
|
'drive/files/create': { req: TODO; res: TODO; };
|
||||||
'drive/files/delete': { req: { fileId: DriveFile['id']; }; res: null; };
|
'drive/files/delete': { req: { fileId: DriveFile['id']; }; res: null; };
|
||||||
'drive/files/find-by-hash': { req: TODO; res: TODO; };
|
'drive/files/find-by-hash': { req: TODO; res: TODO; };
|
||||||
'drive/files/find': { req: TODO; res: TODO; };
|
'drive/files/find': { req: TODO; res: TODO; };
|
||||||
'drive/files/show': { req: TODO; res: TODO; };
|
'drive/files/show': { req: { fileId?: DriveFile['id']; url?: string; }; res: DriveFile; };
|
||||||
'drive/files/update': { req: TODO; res: TODO; };
|
'drive/files/update': { req: TODO; res: TODO; };
|
||||||
'drive/files/upload-from-url': { req: TODO; res: TODO; };
|
'drive/files/upload-from-url': { req: TODO; res: TODO; };
|
||||||
'drive/folders': { req: TODO; res: TODO; };
|
'drive/folders': { req: { folderId?: DriveFolder['id'] | null; limit?: number; sinceId?: DriveFile['id']; untilId?: DriveFile['id']; }; res: DriveFolder[]; };
|
||||||
'drive/folders/create': { req: TODO; res: TODO; };
|
'drive/folders/create': { req: TODO; res: TODO; };
|
||||||
'drive/folders/delete': { req: { folderId: DriveFolder['id']; }; res: null; };
|
'drive/folders/delete': { req: { folderId: DriveFolder['id']; }; res: null; };
|
||||||
'drive/folders/find': { req: TODO; res: TODO; };
|
'drive/folders/find': { req: TODO; res: TODO; };
|
||||||
@ -276,13 +276,29 @@ export type Endpoints = {
|
|||||||
'endpoints': { req: {}; res: string[]; };
|
'endpoints': { req: {}; res: string[]; };
|
||||||
|
|
||||||
// federation
|
// federation
|
||||||
'federation/dns': { req: TODO; res: TODO; };
|
'federation/dns': { req: { host: string; }; res: {
|
||||||
|
a: string[];
|
||||||
|
aaaa: string[];
|
||||||
|
cname: string[];
|
||||||
|
txt: string[];
|
||||||
|
}; };
|
||||||
'federation/followers': { req: { host: string; limit?: number; sinceId?: Following['id']; untilId?: Following['id']; }; res: FollowingFolloweePopulated[]; };
|
'federation/followers': { req: { host: string; limit?: number; sinceId?: Following['id']; untilId?: Following['id']; }; res: FollowingFolloweePopulated[]; };
|
||||||
'federation/following': { req: { host: string; limit?: number; sinceId?: Following['id']; untilId?: Following['id']; }; res: FollowingFolloweePopulated[]; };
|
'federation/following': { req: { host: string; limit?: number; sinceId?: Following['id']; untilId?: Following['id']; }; res: FollowingFolloweePopulated[]; };
|
||||||
'federation/instances': { req: TODO; res: TODO; };
|
'federation/instances': { req: {
|
||||||
'federation/show-instance': { req: TODO; res: TODO; };
|
host?: string | null;
|
||||||
'federation/update-remote-user': { req: TODO; res: TODO; };
|
blocked?: boolean | null;
|
||||||
'federation/users': { req: TODO; res: TODO; };
|
notResponding?: boolean | null;
|
||||||
|
suspended?: boolean | null;
|
||||||
|
federating?: boolean | null;
|
||||||
|
subscribing?: boolean | null;
|
||||||
|
publishing?: boolean | null;
|
||||||
|
limit?: number;
|
||||||
|
offset?: number;
|
||||||
|
sort?: '+pubSub' | '-pubSub' | '+notes' | '-notes' | '+users' | '-users' | '+following' | '-following' | '+followers' | '-followers' | '+caughtAt' | '-caughtAt' | '+lastCommunicatedAt' | '-lastCommunicatedAt' | '+driveUsage' | '-driveUsage' | '+driveFiles' | '-driveFiles';
|
||||||
|
}; res: Instance[]; };
|
||||||
|
'federation/show-instance': { req: { host: string; }; res: Instance; };
|
||||||
|
'federation/update-remote-user': { req: { userId: User['id']; }; res: null; };
|
||||||
|
'federation/users': { req: { host: string; limit?: number; sinceId?: User['id']; untilId?: User['id']; }; res: UserDetailed[]; };
|
||||||
|
|
||||||
// following
|
// following
|
||||||
'following/create': { req: { userId: User['id'] }; res: User; };
|
'following/create': { req: { userId: User['id'] }; res: User; };
|
||||||
|
@ -338,5 +338,34 @@ export type FollowingFollowerPopulated = Following & {
|
|||||||
follower: UserDetailed;
|
follower: UserDetailed;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type Instance = {
|
||||||
|
id: ID;
|
||||||
|
caughtAt: DateString;
|
||||||
|
host: string;
|
||||||
|
usersCount: number;
|
||||||
|
notesCount: number;
|
||||||
|
followingCount: number;
|
||||||
|
followersCount: number;
|
||||||
|
driveUsage: number;
|
||||||
|
driveFiles: number;
|
||||||
|
latestRequestSentAt: DateString | null;
|
||||||
|
latestStatus: number | null;
|
||||||
|
latestRequestReceivedAt: DateString | null;
|
||||||
|
lastCommunicatedAt: DateString;
|
||||||
|
isNotResponding: boolean;
|
||||||
|
isSuspended: boolean;
|
||||||
|
softwareName: string | null;
|
||||||
|
softwareVersion: string | null;
|
||||||
|
openRegistrations: boolean | null;
|
||||||
|
name: string | null;
|
||||||
|
description: string | null;
|
||||||
|
maintainerName: string | null;
|
||||||
|
maintainerEmail: string | null;
|
||||||
|
iconUrl: string | null;
|
||||||
|
faviconUrl: string | null;
|
||||||
|
themeColor: string | null;
|
||||||
|
infoUpdatedAt: DateString | null;
|
||||||
|
};
|
||||||
|
|
||||||
export type UserSorting = '+follower' | '-follower' | '+createdAt' | '-createdAt' | '+updatedAt' | '-updatedAt';
|
export type UserSorting = '+follower' | '-follower' | '+createdAt' | '-createdAt' | '+updatedAt' | '-updatedAt';
|
||||||
export type OriginType = 'combined' | 'local' | 'remote';
|
export type OriginType = 'combined' | 'local' | 'remote';
|
||||||
|
Loading…
Reference in New Issue
Block a user