Skip to content

Commit

Permalink
update: misskey-js types
Browse files Browse the repository at this point in the history
  • Loading branch information
chan-mai committed Aug 2, 2024
1 parent ef17f56 commit 4269513
Show file tree
Hide file tree
Showing 5 changed files with 98 additions and 2 deletions.
8 changes: 8 additions & 0 deletions packages/misskey-js/etc/misskey-js.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1722,6 +1722,8 @@ declare namespace entities {
UsersListsGetMembershipsResponse,
UsersNotesRequest,
UsersNotesResponse,
UsersPagesRequest,
UsersPagesResponse,
UsersFlashsRequest,
UsersFlashsResponse,
UsersReactionsRequest,
Expand Down Expand Up @@ -3168,6 +3170,12 @@ type UsersNotesRequest = operations['users___notes']['requestBody']['content']['
// @public (undocumented)
type UsersNotesResponse = operations['users___notes']['responses']['200']['content']['application/json'];

// @public (undocumented)
type UsersPagesRequest = operations['users___pages']['requestBody']['content']['application/json'];

// @public (undocumented)
type UsersPagesResponse = operations['users___pages']['responses']['200']['content']['application/json'];

// @public (undocumented)
type UsersReactionsRequest = operations['users___reactions']['requestBody']['content']['application/json'];

Expand Down
11 changes: 11 additions & 0 deletions packages/misskey-js/src/autogen/apiClientJSDoc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3968,6 +3968,17 @@ declare module '../api.js' {
credential?: string | null,
): Promise<SwitchCaseResponseType<E, P>>;

/**
* Show all pages this user created.
*
* **Credential required**: *No*
*/
request<E extends 'users/pages', P extends Endpoints[E]['req']>(
endpoint: E,
params: P,
credential?: string | null,
): Promise<SwitchCaseResponseType<E, P>>;

/**
* Show all flashs this user created.
*
Expand Down
4 changes: 4 additions & 0 deletions packages/misskey-js/src/autogen/endpoint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -532,6 +532,8 @@ import type {
UsersListsGetMembershipsResponse,
UsersNotesRequest,
UsersNotesResponse,
UsersPagesRequest,
UsersPagesResponse,
UsersFlashsRequest,
UsersFlashsResponse,
UsersReactionsRequest,
Expand Down Expand Up @@ -928,6 +930,7 @@ export type Endpoints = {
'users/lists/update-membership': { req: UsersListsUpdateMembershipRequest; res: EmptyResponse };
'users/lists/get-memberships': { req: UsersListsGetMembershipsRequest; res: UsersListsGetMembershipsResponse };
'users/notes': { req: UsersNotesRequest; res: UsersNotesResponse };
'users/pages': { req: UsersPagesRequest; res: UsersPagesResponse };
'users/flashs': { req: UsersFlashsRequest; res: UsersFlashsResponse };
'users/reactions': { req: UsersReactionsRequest; res: UsersReactionsResponse };
'users/recommendation': { req: UsersRecommendationRequest; res: UsersRecommendationResponse };
Expand Down Expand Up @@ -1309,6 +1312,7 @@ export const endpointReqTypes: Record<keyof Endpoints, 'application/json' | 'mul
'users/lists/update-membership': 'application/json',
'users/lists/get-memberships': 'application/json',
'users/notes': 'application/json',
'users/pages': 'application/json',
'users/flashs': 'application/json',
'users/reactions': 'application/json',
'users/recommendation': 'application/json',
Expand Down
2 changes: 2 additions & 0 deletions packages/misskey-js/src/autogen/entities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,8 @@ export type UsersListsGetMembershipsRequest = operations['users___lists___get-me
export type UsersListsGetMembershipsResponse = operations['users___lists___get-memberships']['responses']['200']['content']['application/json'];
export type UsersNotesRequest = operations['users___notes']['requestBody']['content']['application/json'];
export type UsersNotesResponse = operations['users___notes']['responses']['200']['content']['application/json'];
export type UsersPagesRequest = operations['users___pages']['requestBody']['content']['application/json'];
export type UsersPagesResponse = operations['users___pages']['responses']['200']['content']['application/json'];
export type UsersFlashsRequest = operations['users___flashs']['requestBody']['content']['application/json'];
export type UsersFlashsResponse = operations['users___flashs']['responses']['200']['content']['application/json'];
export type UsersReactionsRequest = operations['users___reactions']['requestBody']['content']['application/json'];
Expand Down
75 changes: 73 additions & 2 deletions packages/misskey-js/src/autogen/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3419,6 +3419,15 @@ export type paths = {
*/
post: operations['users___notes'];
};
'/users/pages': {
/**
* users/pages
* @description Show all pages this user created.
*
* **Credential required**: *No*
*/
post: operations['users___pages'];
};
'/users/flashs': {
/**
* users/flashs
Expand Down Expand Up @@ -4004,7 +4013,7 @@ export type components = {
/** @enum {string} */
icon: 'info' | 'warning' | 'error' | 'success';
/** @enum {string} */
display: 'dialog' | 'normal' | 'banner' | 'emergency';
display: 'dialog' | 'normal' | 'banner';
needConfirmationToRead: boolean;
silence: boolean;
forYou: boolean;
Expand Down Expand Up @@ -4511,7 +4520,7 @@ export type components = {
isFollowing?: boolean;
isFavorited?: boolean;
pinnedNotes?: components['schemas']['Note'][];
annoucement: string | null;
announcement: string | null;
};
QueueCount: {
waiting: number;
Expand Down Expand Up @@ -11440,6 +11449,7 @@ export type operations = {
'application/json': {
name: string;
description?: string | null;
announcement?: string | null;
/** Format: misskey:id */
bannerId?: string | null;
color?: string;
Expand Down Expand Up @@ -19590,6 +19600,7 @@ export type operations = {
publicReactions?: boolean;
carefulBot?: boolean;
autoAcceptFollowed?: boolean;
autoRejectFollowRequest?: boolean;
noCrawle?: boolean;
preventAiLearning?: boolean;
isBot?: boolean;
Expand Down Expand Up @@ -26177,6 +26188,66 @@ export type operations = {
};
};
};
/**
* users/pages
* @description Show all pages this user created.
*
* **Credential required**: *No*
*/
users___pages: {
requestBody: {
content: {
'application/json': {
/** Format: misskey:id */
userId: string;
/** @default 10 */
limit?: number;
/** Format: misskey:id */
sinceId?: string;
/** Format: misskey:id */
untilId?: string;
};
};
};
responses: {
/** @description OK (with results) */
200: {
content: {
'application/json': components['schemas']['Page'][];
};
};
/** @description Client error */
400: {
content: {
'application/json': components['schemas']['Error'];
};
};
/** @description Authentication error */
401: {
content: {
'application/json': components['schemas']['Error'];
};
};
/** @description Forbidden error */
403: {
content: {
'application/json': components['schemas']['Error'];
};
};
/** @description I'm Ai */
418: {
content: {
'application/json': components['schemas']['Error'];
};
};
/** @description Internal server error */
500: {
content: {
'application/json': components['schemas']['Error'];
};
};
};
};
/**
* users/flashs
* @description Show all flashs this user created.
Expand Down

0 comments on commit 4269513

Please sign in to comment.