@crowi/api 2.0.0-alpha.0 → 2.0.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/hono/handlers/access-token.d.ts +55 -55
- package/dist/hono/handlers/activation.d.ts +27 -27
- package/dist/hono/handlers/admin/app.d.ts +26 -26
- package/dist/hono/handlers/admin/auth.d.ts +24 -24
- package/dist/hono/handlers/admin/mail.d.ts +30 -30
- package/dist/hono/handlers/admin/plugins.d.ts +112 -112
- package/dist/hono/handlers/admin/search.d.ts +21 -21
- package/dist/hono/handlers/admin/security.d.ts +24 -24
- package/dist/hono/handlers/admin/storage.d.ts +19 -19
- package/dist/hono/handlers/admin/users.d.ts +305 -305
- package/dist/hono/handlers/adminCrypto.d.ts +32 -32
- package/dist/hono/handlers/app.d.ts +11 -8
- package/dist/hono/handlers/app.js +31 -1
- package/dist/hono/handlers/app.js.map +1 -1
- package/dist/hono/handlers/attachment.d.ts +180 -180
- package/dist/hono/handlers/autocomplete.d.ts +45 -45
- package/dist/hono/handlers/backlink.d.ts +33 -33
- package/dist/hono/handlers/bookmark.d.ts +95 -95
- package/dist/hono/handlers/comment.d.ts +55 -55
- package/dist/hono/handlers/draft.d.ts +27 -27
- package/dist/hono/handlers/emailChange.d.ts +25 -25
- package/dist/hono/handlers/installer.d.ts +16 -16
- package/dist/hono/handlers/inviteAccept.d.ts +37 -37
- package/dist/hono/handlers/me.d.ts +92 -92
- package/dist/hono/handlers/notification.d.ts +94 -94
- package/dist/hono/handlers/oauth.d.ts +58 -58
- package/dist/hono/handlers/page-collab.d.ts +20 -20
- package/dist/hono/handlers/page-preview.d.ts +7 -7
- package/dist/hono/handlers/page.d.ts +333 -333
- package/dist/hono/handlers/passwordReset.d.ts +37 -37
- package/dist/hono/handlers/presence.d.ts +44 -44
- package/dist/hono/handlers/revision.d.ts +99 -99
- package/dist/hono/handlers/search.d.ts +64 -64
- package/dist/hono/handlers/tokenAuth.d.ts +80 -80
- package/dist/hono/handlers/user.d.ts +102 -102
- package/dist/hono/handlers/user.js +15 -5
- package/dist/hono/handlers/user.js.map +1 -1
- package/dist/hono/index.d.ts +94 -94
- package/dist/mcp/result.d.ts +15 -0
- package/dist/mcp/result.js +20 -1
- package/dist/mcp/result.js.map +1 -1
- package/dist/mcp/tools/page.js +9 -4
- package/dist/mcp/tools/page.js.map +1 -1
- package/dist/migration/migrations/index.js +2 -0
- package/dist/migration/migrations/index.js.map +1 -1
- package/dist/migration/migrations/relocate-reserved-api-paths.d.ts +3 -0
- package/dist/migration/migrations/relocate-reserved-api-paths.js +135 -0
- package/dist/migration/migrations/relocate-reserved-api-paths.js.map +1 -0
- package/dist/models/page.js +9 -2
- package/dist/models/page.js.map +1 -1
- package/dist/util/replace-url.d.ts +85 -0
- package/dist/util/replace-url.js +251 -0
- package/dist/util/replace-url.js.map +1 -0
- package/package.json +6 -4
- package/public/images/file-not-found.png +0 -0
- package/views/mail/activation.mjml +9 -0
- package/views/mail/activation.text +13 -0
- package/views/mail/adminApprovalPending.mjml +7 -0
- package/views/mail/adminApprovalPending.text +11 -0
- package/views/mail/emailChange.mjml +9 -0
- package/views/mail/emailChange.text +13 -0
- package/views/mail/invite.mjml +9 -0
- package/views/mail/invite.text +13 -0
- package/views/mail/layout.mjml +36 -0
- package/views/mail/passwordChanged.mjml +4 -0
- package/views/mail/passwordChanged.text +9 -0
- package/views/mail/passwordReset.mjml +9 -0
- package/views/mail/passwordReset.text +13 -0
- package/views/mail/test.mjml +2 -0
- package/views/mail/test.text +7 -0
|
@@ -10,10 +10,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
output: {
|
|
13
|
-
|
|
13
|
+
error: {
|
|
14
|
+
code: "INTERNAL_ERROR";
|
|
15
|
+
message: "Internal server error";
|
|
16
|
+
};
|
|
14
17
|
};
|
|
15
18
|
outputFormat: "json";
|
|
16
|
-
status:
|
|
19
|
+
status: 500;
|
|
17
20
|
} | {
|
|
18
21
|
input: {
|
|
19
22
|
json: {
|
|
@@ -22,7 +25,7 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
22
25
|
};
|
|
23
26
|
output: {
|
|
24
27
|
error: {
|
|
25
|
-
code: "
|
|
28
|
+
code: "PAGE_NOT_FOUND" | "INVALID_PAGE_ID" | "INTERNAL_ERROR" | "AUTHENTICATION_REQUIRED" | "USER_REGISTERED" | "USER_SUSPENDED" | "USER_INVITED" | "ADMIN_REQUIRED" | "VALIDATION_ERROR" | "INVALID_REQUEST" | "ENCRYPTION_NOT_CONFIGURED" | "MAIL_TEST_FAILED" | "PLUGIN_NOT_FOUND" | "PLUGIN_CONFIG_VALIDATION_FAILED" | "THIRD_PARTY_AUTH_REQUIRED" | "USER_NOT_ACTIVE" | "EMAIL_NOT_CONFIRMED" | "NOT_FOUND" | "CONFLICT" | "SERVICE_UNAVAILABLE" | "APPLICATION_NOT_INSTALLED" | "PAGE_NOT_GRANTED" | "PAGE_REVISION_ERROR" | "INVALID_GRANT" | "COMMENT_NOT_FOUND" | "NOTIFICATION_NOT_FOUND" | "USER_NOT_FOUND" | "USER_EXISTS" | "USERNAME_TAKEN" | "EMAIL_TAKEN" | "EMAIL_NOT_ALLOWED" | "INVALID_ACTIVATION_TOKEN" | "INVALID_INVITE_TOKEN" | "INVITE_ALREADY_ACCEPTED" | "INVALID_RESET_TOKEN" | "INVALID_EMAIL_CHANGE_TOKEN" | "INVALID_CREDENTIALS" | "REFRESH_TOKEN_REQUIRED" | "REGISTRATION_CLOSED";
|
|
26
29
|
message: string;
|
|
27
30
|
details?: any;
|
|
28
31
|
};
|
|
@@ -36,13 +39,10 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
36
39
|
};
|
|
37
40
|
};
|
|
38
41
|
output: {
|
|
39
|
-
|
|
40
|
-
code: "INTERNAL_ERROR";
|
|
41
|
-
message: "Internal server error";
|
|
42
|
-
};
|
|
42
|
+
ok: true;
|
|
43
43
|
};
|
|
44
44
|
outputFormat: "json";
|
|
45
|
-
status:
|
|
45
|
+
status: 200;
|
|
46
46
|
};
|
|
47
47
|
};
|
|
48
48
|
} & {
|
|
@@ -54,10 +54,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
54
54
|
};
|
|
55
55
|
};
|
|
56
56
|
output: {
|
|
57
|
-
|
|
57
|
+
error: {
|
|
58
|
+
code: "INTERNAL_ERROR";
|
|
59
|
+
message: "Internal server error";
|
|
60
|
+
};
|
|
58
61
|
};
|
|
59
62
|
outputFormat: "json";
|
|
60
|
-
status:
|
|
63
|
+
status: 500;
|
|
61
64
|
} | {
|
|
62
65
|
input: {
|
|
63
66
|
query: {
|
|
@@ -66,7 +69,7 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
66
69
|
};
|
|
67
70
|
output: {
|
|
68
71
|
error: {
|
|
69
|
-
code: "
|
|
72
|
+
code: "PAGE_NOT_FOUND" | "INVALID_PAGE_ID" | "INTERNAL_ERROR" | "AUTHENTICATION_REQUIRED" | "USER_REGISTERED" | "USER_SUSPENDED" | "USER_INVITED" | "ADMIN_REQUIRED" | "VALIDATION_ERROR" | "INVALID_REQUEST" | "ENCRYPTION_NOT_CONFIGURED" | "MAIL_TEST_FAILED" | "PLUGIN_NOT_FOUND" | "PLUGIN_CONFIG_VALIDATION_FAILED" | "THIRD_PARTY_AUTH_REQUIRED" | "USER_NOT_ACTIVE" | "EMAIL_NOT_CONFIRMED" | "NOT_FOUND" | "CONFLICT" | "SERVICE_UNAVAILABLE" | "APPLICATION_NOT_INSTALLED" | "PAGE_NOT_GRANTED" | "PAGE_REVISION_ERROR" | "INVALID_GRANT" | "COMMENT_NOT_FOUND" | "NOTIFICATION_NOT_FOUND" | "USER_NOT_FOUND" | "USER_EXISTS" | "USERNAME_TAKEN" | "EMAIL_TAKEN" | "EMAIL_NOT_ALLOWED" | "INVALID_ACTIVATION_TOKEN" | "INVALID_INVITE_TOKEN" | "INVITE_ALREADY_ACCEPTED" | "INVALID_RESET_TOKEN" | "INVALID_EMAIL_CHANGE_TOKEN" | "INVALID_CREDENTIALS" | "REFRESH_TOKEN_REQUIRED" | "REGISTRATION_CLOSED";
|
|
70
73
|
message: string;
|
|
71
74
|
details?: any;
|
|
72
75
|
};
|
|
@@ -80,13 +83,10 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
80
83
|
};
|
|
81
84
|
};
|
|
82
85
|
output: {
|
|
83
|
-
|
|
84
|
-
code: "INTERNAL_ERROR";
|
|
85
|
-
message: "Internal server error";
|
|
86
|
-
};
|
|
86
|
+
ok: true;
|
|
87
87
|
};
|
|
88
88
|
outputFormat: "json";
|
|
89
|
-
status:
|
|
89
|
+
status: 200;
|
|
90
90
|
};
|
|
91
91
|
};
|
|
92
92
|
} & {
|
|
@@ -99,20 +99,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
99
99
|
};
|
|
100
100
|
};
|
|
101
101
|
output: {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
user: {
|
|
106
|
-
id: string;
|
|
107
|
-
username: string;
|
|
108
|
-
email: string;
|
|
109
|
-
name: string;
|
|
110
|
-
image?: string | undefined;
|
|
111
|
-
admin?: boolean | undefined;
|
|
102
|
+
error: {
|
|
103
|
+
code: "INTERNAL_ERROR";
|
|
104
|
+
message: "Internal server error";
|
|
112
105
|
};
|
|
113
106
|
};
|
|
114
107
|
outputFormat: "json";
|
|
115
|
-
status:
|
|
108
|
+
status: 500;
|
|
116
109
|
} | {
|
|
117
110
|
input: {
|
|
118
111
|
json: {
|
|
@@ -122,13 +115,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
122
115
|
};
|
|
123
116
|
output: {
|
|
124
117
|
error: {
|
|
125
|
-
code: "
|
|
118
|
+
code: "PAGE_NOT_FOUND" | "INVALID_PAGE_ID" | "INTERNAL_ERROR" | "AUTHENTICATION_REQUIRED" | "USER_REGISTERED" | "USER_SUSPENDED" | "USER_INVITED" | "ADMIN_REQUIRED" | "VALIDATION_ERROR" | "INVALID_REQUEST" | "ENCRYPTION_NOT_CONFIGURED" | "MAIL_TEST_FAILED" | "PLUGIN_NOT_FOUND" | "PLUGIN_CONFIG_VALIDATION_FAILED" | "THIRD_PARTY_AUTH_REQUIRED" | "USER_NOT_ACTIVE" | "EMAIL_NOT_CONFIRMED" | "NOT_FOUND" | "CONFLICT" | "SERVICE_UNAVAILABLE" | "APPLICATION_NOT_INSTALLED" | "PAGE_NOT_GRANTED" | "PAGE_REVISION_ERROR" | "INVALID_GRANT" | "COMMENT_NOT_FOUND" | "NOTIFICATION_NOT_FOUND" | "USER_NOT_FOUND" | "USER_EXISTS" | "USERNAME_TAKEN" | "EMAIL_TAKEN" | "EMAIL_NOT_ALLOWED" | "INVALID_ACTIVATION_TOKEN" | "INVALID_INVITE_TOKEN" | "INVITE_ALREADY_ACCEPTED" | "INVALID_RESET_TOKEN" | "INVALID_EMAIL_CHANGE_TOKEN" | "INVALID_CREDENTIALS" | "REFRESH_TOKEN_REQUIRED" | "REGISTRATION_CLOSED";
|
|
126
119
|
message: string;
|
|
127
120
|
details?: any;
|
|
128
121
|
};
|
|
129
122
|
};
|
|
130
123
|
outputFormat: "json";
|
|
131
|
-
status:
|
|
124
|
+
status: 404;
|
|
132
125
|
} | {
|
|
133
126
|
input: {
|
|
134
127
|
json: {
|
|
@@ -138,13 +131,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
138
131
|
};
|
|
139
132
|
output: {
|
|
140
133
|
error: {
|
|
141
|
-
code: "
|
|
134
|
+
code: "PAGE_NOT_FOUND" | "INVALID_PAGE_ID" | "INTERNAL_ERROR" | "AUTHENTICATION_REQUIRED" | "USER_REGISTERED" | "USER_SUSPENDED" | "USER_INVITED" | "ADMIN_REQUIRED" | "VALIDATION_ERROR" | "INVALID_REQUEST" | "ENCRYPTION_NOT_CONFIGURED" | "MAIL_TEST_FAILED" | "PLUGIN_NOT_FOUND" | "PLUGIN_CONFIG_VALIDATION_FAILED" | "THIRD_PARTY_AUTH_REQUIRED" | "USER_NOT_ACTIVE" | "EMAIL_NOT_CONFIRMED" | "NOT_FOUND" | "CONFLICT" | "SERVICE_UNAVAILABLE" | "APPLICATION_NOT_INSTALLED" | "PAGE_NOT_GRANTED" | "PAGE_REVISION_ERROR" | "INVALID_GRANT" | "COMMENT_NOT_FOUND" | "NOTIFICATION_NOT_FOUND" | "USER_NOT_FOUND" | "USER_EXISTS" | "USERNAME_TAKEN" | "EMAIL_TAKEN" | "EMAIL_NOT_ALLOWED" | "INVALID_ACTIVATION_TOKEN" | "INVALID_INVITE_TOKEN" | "INVITE_ALREADY_ACCEPTED" | "INVALID_RESET_TOKEN" | "INVALID_EMAIL_CHANGE_TOKEN" | "INVALID_CREDENTIALS" | "REFRESH_TOKEN_REQUIRED" | "REGISTRATION_CLOSED";
|
|
142
135
|
message: string;
|
|
143
136
|
details?: any;
|
|
144
137
|
};
|
|
145
138
|
};
|
|
146
139
|
outputFormat: "json";
|
|
147
|
-
status:
|
|
140
|
+
status: 400;
|
|
148
141
|
} | {
|
|
149
142
|
input: {
|
|
150
143
|
json: {
|
|
@@ -154,13 +147,13 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
154
147
|
};
|
|
155
148
|
output: {
|
|
156
149
|
error: {
|
|
157
|
-
code: "
|
|
150
|
+
code: "PAGE_NOT_FOUND" | "INVALID_PAGE_ID" | "INTERNAL_ERROR" | "AUTHENTICATION_REQUIRED" | "USER_REGISTERED" | "USER_SUSPENDED" | "USER_INVITED" | "ADMIN_REQUIRED" | "VALIDATION_ERROR" | "INVALID_REQUEST" | "ENCRYPTION_NOT_CONFIGURED" | "MAIL_TEST_FAILED" | "PLUGIN_NOT_FOUND" | "PLUGIN_CONFIG_VALIDATION_FAILED" | "THIRD_PARTY_AUTH_REQUIRED" | "USER_NOT_ACTIVE" | "EMAIL_NOT_CONFIRMED" | "NOT_FOUND" | "CONFLICT" | "SERVICE_UNAVAILABLE" | "APPLICATION_NOT_INSTALLED" | "PAGE_NOT_GRANTED" | "PAGE_REVISION_ERROR" | "INVALID_GRANT" | "COMMENT_NOT_FOUND" | "NOTIFICATION_NOT_FOUND" | "USER_NOT_FOUND" | "USER_EXISTS" | "USERNAME_TAKEN" | "EMAIL_TAKEN" | "EMAIL_NOT_ALLOWED" | "INVALID_ACTIVATION_TOKEN" | "INVALID_INVITE_TOKEN" | "INVITE_ALREADY_ACCEPTED" | "INVALID_RESET_TOKEN" | "INVALID_EMAIL_CHANGE_TOKEN" | "INVALID_CREDENTIALS" | "REFRESH_TOKEN_REQUIRED" | "REGISTRATION_CLOSED";
|
|
158
151
|
message: string;
|
|
159
152
|
details?: any;
|
|
160
153
|
};
|
|
161
154
|
};
|
|
162
155
|
outputFormat: "json";
|
|
163
|
-
status:
|
|
156
|
+
status: 401;
|
|
164
157
|
} | {
|
|
165
158
|
input: {
|
|
166
159
|
json: {
|
|
@@ -169,13 +162,20 @@ export declare const registerPasswordResetRoutes: <E extends OpenAPIHono<CrowiHo
|
|
|
169
162
|
};
|
|
170
163
|
};
|
|
171
164
|
output: {
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
165
|
+
accessToken: string;
|
|
166
|
+
refreshToken: string;
|
|
167
|
+
expiresIn: number;
|
|
168
|
+
user: {
|
|
169
|
+
id: string;
|
|
170
|
+
username: string;
|
|
171
|
+
email: string;
|
|
172
|
+
name: string;
|
|
173
|
+
image?: string | undefined;
|
|
174
|
+
admin?: boolean | undefined;
|
|
175
175
|
};
|
|
176
176
|
};
|
|
177
177
|
outputFormat: "json";
|
|
178
|
-
status:
|
|
178
|
+
status: 200;
|
|
179
179
|
};
|
|
180
180
|
};
|
|
181
181
|
}, "/">;
|
|
@@ -10,13 +10,13 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
output: {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
error: {
|
|
14
|
+
code: "INTERNAL_ERROR";
|
|
15
|
+
message: "Internal server error";
|
|
16
|
+
};
|
|
17
17
|
};
|
|
18
18
|
outputFormat: "json";
|
|
19
|
-
status:
|
|
19
|
+
status: 500;
|
|
20
20
|
} | {
|
|
21
21
|
input: {
|
|
22
22
|
param: {
|
|
@@ -25,12 +25,12 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
25
25
|
};
|
|
26
26
|
output: {
|
|
27
27
|
error: {
|
|
28
|
-
code: "
|
|
29
|
-
message:
|
|
28
|
+
code: "PAGE_NOT_FOUND";
|
|
29
|
+
message: "Page not found";
|
|
30
30
|
};
|
|
31
31
|
};
|
|
32
32
|
outputFormat: "json";
|
|
33
|
-
status:
|
|
33
|
+
status: 404;
|
|
34
34
|
} | {
|
|
35
35
|
input: {
|
|
36
36
|
param: {
|
|
@@ -39,13 +39,12 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
39
39
|
};
|
|
40
40
|
output: {
|
|
41
41
|
error: {
|
|
42
|
-
code: "
|
|
43
|
-
message:
|
|
44
|
-
redirectTo?: string | undefined;
|
|
42
|
+
code: "INVALID_PAGE_ID";
|
|
43
|
+
message: string;
|
|
45
44
|
};
|
|
46
45
|
};
|
|
47
46
|
outputFormat: "json";
|
|
48
|
-
status:
|
|
47
|
+
status: 400;
|
|
49
48
|
} | {
|
|
50
49
|
input: {
|
|
51
50
|
param: {
|
|
@@ -54,12 +53,13 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
54
53
|
};
|
|
55
54
|
output: {
|
|
56
55
|
error: {
|
|
57
|
-
code: "
|
|
58
|
-
message: "
|
|
56
|
+
code: "AUTHENTICATION_REQUIRED";
|
|
57
|
+
message: "Authentication is required";
|
|
58
|
+
redirectTo?: string | undefined;
|
|
59
59
|
};
|
|
60
60
|
};
|
|
61
61
|
outputFormat: "json";
|
|
62
|
-
status:
|
|
62
|
+
status: 401;
|
|
63
63
|
} | {
|
|
64
64
|
input: {
|
|
65
65
|
param: {
|
|
@@ -67,13 +67,13 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
67
67
|
};
|
|
68
68
|
};
|
|
69
69
|
output: {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
70
|
+
token: string;
|
|
71
|
+
pageId: string;
|
|
72
|
+
selfUserId: string;
|
|
73
|
+
expiresAt: string;
|
|
74
74
|
};
|
|
75
75
|
outputFormat: "json";
|
|
76
|
-
status:
|
|
76
|
+
status: 200;
|
|
77
77
|
};
|
|
78
78
|
};
|
|
79
79
|
} & {
|
|
@@ -89,17 +89,13 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
89
89
|
};
|
|
90
90
|
};
|
|
91
91
|
output: {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
avatarUrl: string | null;
|
|
97
|
-
likedAt: string | null;
|
|
98
|
-
}[];
|
|
99
|
-
totalCount: number;
|
|
92
|
+
error: {
|
|
93
|
+
code: "INTERNAL_ERROR";
|
|
94
|
+
message: "Internal server error";
|
|
95
|
+
};
|
|
100
96
|
};
|
|
101
97
|
outputFormat: "json";
|
|
102
|
-
status:
|
|
98
|
+
status: 500;
|
|
103
99
|
} | {
|
|
104
100
|
input: {
|
|
105
101
|
param: {
|
|
@@ -112,12 +108,12 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
112
108
|
};
|
|
113
109
|
output: {
|
|
114
110
|
error: {
|
|
115
|
-
code: "
|
|
116
|
-
message:
|
|
111
|
+
code: "PAGE_NOT_FOUND";
|
|
112
|
+
message: "Page not found";
|
|
117
113
|
};
|
|
118
114
|
};
|
|
119
115
|
outputFormat: "json";
|
|
120
|
-
status:
|
|
116
|
+
status: 404;
|
|
121
117
|
} | {
|
|
122
118
|
input: {
|
|
123
119
|
param: {
|
|
@@ -130,13 +126,12 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
130
126
|
};
|
|
131
127
|
output: {
|
|
132
128
|
error: {
|
|
133
|
-
code: "
|
|
134
|
-
message:
|
|
135
|
-
redirectTo?: string | undefined;
|
|
129
|
+
code: "INVALID_PAGE_ID";
|
|
130
|
+
message: string;
|
|
136
131
|
};
|
|
137
132
|
};
|
|
138
133
|
outputFormat: "json";
|
|
139
|
-
status:
|
|
134
|
+
status: 400;
|
|
140
135
|
} | {
|
|
141
136
|
input: {
|
|
142
137
|
param: {
|
|
@@ -149,12 +144,13 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
149
144
|
};
|
|
150
145
|
output: {
|
|
151
146
|
error: {
|
|
152
|
-
code: "
|
|
153
|
-
message: "
|
|
147
|
+
code: "AUTHENTICATION_REQUIRED";
|
|
148
|
+
message: "Authentication is required";
|
|
149
|
+
redirectTo?: string | undefined;
|
|
154
150
|
};
|
|
155
151
|
};
|
|
156
152
|
outputFormat: "json";
|
|
157
|
-
status:
|
|
153
|
+
status: 401;
|
|
158
154
|
} | {
|
|
159
155
|
input: {
|
|
160
156
|
param: {
|
|
@@ -166,13 +162,17 @@ export declare const registerPresenceRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
166
162
|
};
|
|
167
163
|
};
|
|
168
164
|
output: {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
165
|
+
users: {
|
|
166
|
+
id: string;
|
|
167
|
+
username: string;
|
|
168
|
+
displayName: string;
|
|
169
|
+
avatarUrl: string | null;
|
|
170
|
+
likedAt: string | null;
|
|
171
|
+
}[];
|
|
172
|
+
totalCount: number;
|
|
173
173
|
};
|
|
174
174
|
outputFormat: "json";
|
|
175
|
-
status:
|
|
175
|
+
status: 200;
|
|
176
176
|
};
|
|
177
177
|
};
|
|
178
178
|
}, "/">;
|
|
@@ -4,6 +4,64 @@ import type { CrowiHonoBindings } from '../app';
|
|
|
4
4
|
export declare const registerRevisionRoutes: <E extends OpenAPIHono<CrowiHonoBindings>>(app: E, crowi: Crowi) => OpenAPIHono<CrowiHonoBindings, {
|
|
5
5
|
"/pages/:page_id/revisions": {
|
|
6
6
|
$get: {
|
|
7
|
+
input: {
|
|
8
|
+
param: {
|
|
9
|
+
page_id: string;
|
|
10
|
+
};
|
|
11
|
+
} & {
|
|
12
|
+
query: {
|
|
13
|
+
limit?: unknown;
|
|
14
|
+
offset?: unknown;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
output: {
|
|
18
|
+
error: {
|
|
19
|
+
code: "PAGE_NOT_FOUND";
|
|
20
|
+
message: "Page not found";
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
outputFormat: "json";
|
|
24
|
+
status: 404;
|
|
25
|
+
} | {
|
|
26
|
+
input: {
|
|
27
|
+
param: {
|
|
28
|
+
page_id: string;
|
|
29
|
+
};
|
|
30
|
+
} & {
|
|
31
|
+
query: {
|
|
32
|
+
limit?: unknown;
|
|
33
|
+
offset?: unknown;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
output: {
|
|
37
|
+
error: {
|
|
38
|
+
code: "INVALID_REQUEST";
|
|
39
|
+
message: string;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
outputFormat: "json";
|
|
43
|
+
status: 400;
|
|
44
|
+
} | {
|
|
45
|
+
input: {
|
|
46
|
+
param: {
|
|
47
|
+
page_id: string;
|
|
48
|
+
};
|
|
49
|
+
} & {
|
|
50
|
+
query: {
|
|
51
|
+
limit?: unknown;
|
|
52
|
+
offset?: unknown;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
output: {
|
|
56
|
+
error: {
|
|
57
|
+
code: "AUTHENTICATION_REQUIRED";
|
|
58
|
+
message: "Authentication is required";
|
|
59
|
+
redirectTo?: string | undefined;
|
|
60
|
+
};
|
|
61
|
+
};
|
|
62
|
+
outputFormat: "json";
|
|
63
|
+
status: 401;
|
|
64
|
+
} | {
|
|
7
65
|
input: {
|
|
8
66
|
param: {
|
|
9
67
|
page_id: string;
|
|
@@ -56,69 +114,54 @@ export declare const registerRevisionRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
56
114
|
};
|
|
57
115
|
outputFormat: "json";
|
|
58
116
|
status: 200;
|
|
59
|
-
}
|
|
117
|
+
};
|
|
118
|
+
};
|
|
119
|
+
} & {
|
|
120
|
+
"/pages/revisions": {
|
|
121
|
+
$get: {
|
|
60
122
|
input: {
|
|
61
|
-
param: {
|
|
62
|
-
page_id: string;
|
|
63
|
-
};
|
|
64
|
-
} & {
|
|
65
123
|
query: {
|
|
66
|
-
|
|
67
|
-
offset?: unknown;
|
|
124
|
+
ids: string;
|
|
68
125
|
};
|
|
69
126
|
};
|
|
70
127
|
output: {
|
|
71
128
|
error: {
|
|
72
|
-
code: "
|
|
73
|
-
message:
|
|
129
|
+
code: "PAGE_NOT_FOUND";
|
|
130
|
+
message: "Page not found";
|
|
74
131
|
};
|
|
75
132
|
};
|
|
76
133
|
outputFormat: "json";
|
|
77
|
-
status:
|
|
134
|
+
status: 404;
|
|
78
135
|
} | {
|
|
79
136
|
input: {
|
|
80
|
-
param: {
|
|
81
|
-
page_id: string;
|
|
82
|
-
};
|
|
83
|
-
} & {
|
|
84
137
|
query: {
|
|
85
|
-
|
|
86
|
-
offset?: unknown;
|
|
138
|
+
ids: string;
|
|
87
139
|
};
|
|
88
140
|
};
|
|
89
141
|
output: {
|
|
90
142
|
error: {
|
|
91
|
-
code: "
|
|
92
|
-
message:
|
|
93
|
-
redirectTo?: string | undefined;
|
|
143
|
+
code: "INVALID_REQUEST";
|
|
144
|
+
message: string;
|
|
94
145
|
};
|
|
95
146
|
};
|
|
96
147
|
outputFormat: "json";
|
|
97
|
-
status:
|
|
148
|
+
status: 400;
|
|
98
149
|
} | {
|
|
99
150
|
input: {
|
|
100
|
-
param: {
|
|
101
|
-
page_id: string;
|
|
102
|
-
};
|
|
103
|
-
} & {
|
|
104
151
|
query: {
|
|
105
|
-
|
|
106
|
-
offset?: unknown;
|
|
152
|
+
ids: string;
|
|
107
153
|
};
|
|
108
154
|
};
|
|
109
155
|
output: {
|
|
110
156
|
error: {
|
|
111
|
-
code: "
|
|
112
|
-
message: "
|
|
157
|
+
code: "AUTHENTICATION_REQUIRED";
|
|
158
|
+
message: "Authentication is required";
|
|
159
|
+
redirectTo?: string | undefined;
|
|
113
160
|
};
|
|
114
161
|
};
|
|
115
162
|
outputFormat: "json";
|
|
116
|
-
status:
|
|
117
|
-
}
|
|
118
|
-
};
|
|
119
|
-
} & {
|
|
120
|
-
"/pages/revisions": {
|
|
121
|
-
$get: {
|
|
163
|
+
status: 401;
|
|
164
|
+
} | {
|
|
122
165
|
input: {
|
|
123
166
|
query: {
|
|
124
167
|
ids: string;
|
|
@@ -184,54 +227,54 @@ export declare const registerRevisionRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
184
227
|
};
|
|
185
228
|
outputFormat: "json";
|
|
186
229
|
status: 200;
|
|
187
|
-
}
|
|
230
|
+
};
|
|
231
|
+
};
|
|
232
|
+
} & {
|
|
233
|
+
"/pages/revisions/:id": {
|
|
234
|
+
$get: {
|
|
188
235
|
input: {
|
|
189
|
-
|
|
190
|
-
|
|
236
|
+
param: {
|
|
237
|
+
id: string;
|
|
191
238
|
};
|
|
192
239
|
};
|
|
193
240
|
output: {
|
|
194
241
|
error: {
|
|
195
|
-
code: "
|
|
196
|
-
message:
|
|
242
|
+
code: "PAGE_NOT_FOUND";
|
|
243
|
+
message: "Page not found";
|
|
197
244
|
};
|
|
198
245
|
};
|
|
199
246
|
outputFormat: "json";
|
|
200
|
-
status:
|
|
247
|
+
status: 404;
|
|
201
248
|
} | {
|
|
202
249
|
input: {
|
|
203
|
-
|
|
204
|
-
|
|
250
|
+
param: {
|
|
251
|
+
id: string;
|
|
205
252
|
};
|
|
206
253
|
};
|
|
207
254
|
output: {
|
|
208
255
|
error: {
|
|
209
|
-
code: "
|
|
210
|
-
message:
|
|
211
|
-
redirectTo?: string | undefined;
|
|
256
|
+
code: "INVALID_REQUEST";
|
|
257
|
+
message: string;
|
|
212
258
|
};
|
|
213
259
|
};
|
|
214
260
|
outputFormat: "json";
|
|
215
|
-
status:
|
|
261
|
+
status: 400;
|
|
216
262
|
} | {
|
|
217
263
|
input: {
|
|
218
|
-
|
|
219
|
-
|
|
264
|
+
param: {
|
|
265
|
+
id: string;
|
|
220
266
|
};
|
|
221
267
|
};
|
|
222
268
|
output: {
|
|
223
269
|
error: {
|
|
224
|
-
code: "
|
|
225
|
-
message: "
|
|
270
|
+
code: "AUTHENTICATION_REQUIRED";
|
|
271
|
+
message: "Authentication is required";
|
|
272
|
+
redirectTo?: string | undefined;
|
|
226
273
|
};
|
|
227
274
|
};
|
|
228
275
|
outputFormat: "json";
|
|
229
|
-
status:
|
|
230
|
-
}
|
|
231
|
-
};
|
|
232
|
-
} & {
|
|
233
|
-
"/pages/revisions/:id": {
|
|
234
|
-
$get: {
|
|
276
|
+
status: 401;
|
|
277
|
+
} | {
|
|
235
278
|
input: {
|
|
236
279
|
param: {
|
|
237
280
|
id: string;
|
|
@@ -297,49 +340,6 @@ export declare const registerRevisionRoutes: <E extends OpenAPIHono<CrowiHonoBin
|
|
|
297
340
|
};
|
|
298
341
|
outputFormat: "json";
|
|
299
342
|
status: 200;
|
|
300
|
-
} | {
|
|
301
|
-
input: {
|
|
302
|
-
param: {
|
|
303
|
-
id: string;
|
|
304
|
-
};
|
|
305
|
-
};
|
|
306
|
-
output: {
|
|
307
|
-
error: {
|
|
308
|
-
code: "INVALID_REQUEST";
|
|
309
|
-
message: string;
|
|
310
|
-
};
|
|
311
|
-
};
|
|
312
|
-
outputFormat: "json";
|
|
313
|
-
status: 400;
|
|
314
|
-
} | {
|
|
315
|
-
input: {
|
|
316
|
-
param: {
|
|
317
|
-
id: string;
|
|
318
|
-
};
|
|
319
|
-
};
|
|
320
|
-
output: {
|
|
321
|
-
error: {
|
|
322
|
-
code: "AUTHENTICATION_REQUIRED";
|
|
323
|
-
message: "Authentication is required";
|
|
324
|
-
redirectTo?: string | undefined;
|
|
325
|
-
};
|
|
326
|
-
};
|
|
327
|
-
outputFormat: "json";
|
|
328
|
-
status: 401;
|
|
329
|
-
} | {
|
|
330
|
-
input: {
|
|
331
|
-
param: {
|
|
332
|
-
id: string;
|
|
333
|
-
};
|
|
334
|
-
};
|
|
335
|
-
output: {
|
|
336
|
-
error: {
|
|
337
|
-
code: "PAGE_NOT_FOUND";
|
|
338
|
-
message: "Page not found";
|
|
339
|
-
};
|
|
340
|
-
};
|
|
341
|
-
outputFormat: "json";
|
|
342
|
-
status: 404;
|
|
343
343
|
};
|
|
344
344
|
};
|
|
345
345
|
}, "/">;
|