@colveor/admin 0.0.0-stage → 0.5.2

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.
Files changed (154) hide show
  1. package/LICENSE.md +106 -0
  2. package/TAILWINDADMIN-LICENSE +21 -0
  3. package/dist/account/data.d.ts +1 -0
  4. package/dist/account/data.js +44 -0
  5. package/dist/account/profile.d.ts +6 -0
  6. package/dist/account/profile.js +118 -0
  7. package/dist/account/sessions.d.ts +1 -0
  8. package/dist/account/sessions.js +26 -0
  9. package/dist/account/shared.d.ts +26 -0
  10. package/dist/account/shared.js +44 -0
  11. package/dist/account/two-factor.d.ts +5 -0
  12. package/dist/account/two-factor.js +60 -0
  13. package/dist/actions.d.ts +39 -0
  14. package/dist/actions.js +81 -0
  15. package/dist/api/audit.gen.d.ts +80 -0
  16. package/dist/api/audit.gen.js +43 -0
  17. package/dist/api/auth.gen.d.ts +537 -0
  18. package/dist/api/auth.gen.js +313 -0
  19. package/dist/api/errors.gen.d.ts +16 -0
  20. package/dist/api/errors.gen.js +2 -0
  21. package/dist/api/gormx.gen.d.ts +60 -0
  22. package/dist/api/gormx.gen.js +16 -0
  23. package/dist/api/health.gen.d.ts +103 -0
  24. package/dist/api/health.gen.js +23 -0
  25. package/dist/api/index.gen.d.ts +21 -0
  26. package/dist/api/index.gen.js +22 -0
  27. package/dist/api/invitations.gen.d.ts +128 -0
  28. package/dist/api/invitations.gen.js +57 -0
  29. package/dist/api/ledger.gen.d.ts +269 -0
  30. package/dist/api/ledger.gen.js +113 -0
  31. package/dist/api/msgtemplate.gen.d.ts +31 -0
  32. package/dist/api/msgtemplate.gen.js +2 -0
  33. package/dist/api/notifications.gen.d.ts +66 -0
  34. package/dist/api/notifications.gen.js +28 -0
  35. package/dist/api/outbox.gen.d.ts +8 -0
  36. package/dist/api/outbox.gen.js +2 -0
  37. package/dist/api/queue.gen.d.ts +112 -0
  38. package/dist/api/queue.gen.js +15 -0
  39. package/dist/api/rbac.gen.d.ts +406 -0
  40. package/dist/api/rbac.gen.js +191 -0
  41. package/dist/api/reauth.gen.d.ts +289 -0
  42. package/dist/api/reauth.gen.js +122 -0
  43. package/dist/api/recorded_payments.gen.d.ts +171 -0
  44. package/dist/api/recorded_payments.gen.js +79 -0
  45. package/dist/api/sessions.gen.d.ts +64 -0
  46. package/dist/api/sessions.gen.js +48 -0
  47. package/dist/api/settings.gen.d.ts +147 -0
  48. package/dist/api/settings.gen.js +69 -0
  49. package/dist/api/storage.gen.d.ts +327 -0
  50. package/dist/api/storage.gen.js +208 -0
  51. package/dist/api/support_access.gen.d.ts +155 -0
  52. package/dist/api/support_access.gen.js +131 -0
  53. package/dist/api/users.gen.d.ts +407 -0
  54. package/dist/api/users.gen.js +159 -0
  55. package/dist/api/verification.gen.d.ts +427 -0
  56. package/dist/api/verification.gen.js +280 -0
  57. package/dist/api/webhooks.gen.d.ts +110 -0
  58. package/dist/api/webhooks.gen.js +45 -0
  59. package/dist/auth-layout.d.ts +9 -0
  60. package/dist/auth-layout.js +5 -0
  61. package/dist/client.d.ts +41 -0
  62. package/dist/client.js +72 -0
  63. package/dist/config.d.ts +27 -0
  64. package/dist/config.js +82 -0
  65. package/dist/dates.d.ts +4 -0
  66. package/dist/dates.js +16 -0
  67. package/dist/header.d.ts +12 -0
  68. package/dist/header.js +105 -0
  69. package/dist/icons.d.ts +2 -0
  70. package/dist/icons.js +15 -0
  71. package/dist/index.d.ts +28 -0
  72. package/dist/index.js +42 -0
  73. package/dist/kit/avatar.d.ts +5 -0
  74. package/dist/kit/avatar.js +16 -0
  75. package/dist/kit/badge.d.ts +10 -0
  76. package/dist/kit/badge.js +31 -0
  77. package/dist/kit/card.d.ts +12 -0
  78. package/dist/kit/card.js +7 -0
  79. package/dist/kit/code-area.d.ts +15 -0
  80. package/dist/kit/code-area.js +69 -0
  81. package/dist/kit/dropdown.d.ts +26 -0
  82. package/dist/kit/dropdown.js +67 -0
  83. package/dist/kit/filter-tabs.d.ts +9 -0
  84. package/dist/kit/filter-tabs.js +7 -0
  85. package/dist/kit/modal.d.ts +8 -0
  86. package/dist/kit/modal.js +15 -0
  87. package/dist/kit/page-header.d.ts +13 -0
  88. package/dist/kit/page-header.js +13 -0
  89. package/dist/kit/search.d.ts +4 -0
  90. package/dist/kit/search.js +16 -0
  91. package/dist/kit/tooltip.d.ts +17 -0
  92. package/dist/kit/tooltip.js +52 -0
  93. package/dist/message-editor.d.ts +9 -0
  94. package/dist/message-editor.js +80 -0
  95. package/dist/money.d.ts +10 -0
  96. package/dist/money.js +17 -0
  97. package/dist/next.d.ts +6 -0
  98. package/dist/next.js +19 -0
  99. package/dist/pages/account.d.ts +1 -0
  100. package/dist/pages/account.js +47 -0
  101. package/dist/pages/audit.d.ts +1 -0
  102. package/dist/pages/audit.js +88 -0
  103. package/dist/pages/forgot-password.d.ts +1 -0
  104. package/dist/pages/forgot-password.js +73 -0
  105. package/dist/pages/ledger.d.ts +1 -0
  106. package/dist/pages/ledger.js +132 -0
  107. package/dist/pages/roles.d.ts +1 -0
  108. package/dist/pages/roles.js +102 -0
  109. package/dist/pages/settings.d.ts +1 -0
  110. package/dist/pages/settings.js +86 -0
  111. package/dist/pages/sign-in.d.ts +5 -0
  112. package/dist/pages/sign-in.js +117 -0
  113. package/dist/pages/status.d.ts +1 -0
  114. package/dist/pages/status.js +122 -0
  115. package/dist/pages/support.d.ts +1 -0
  116. package/dist/pages/support.js +90 -0
  117. package/dist/pages/teams.d.ts +1 -0
  118. package/dist/pages/teams.js +94 -0
  119. package/dist/pages/users.d.ts +1 -0
  120. package/dist/pages/users.js +158 -0
  121. package/dist/pages/webhooks.d.ts +1 -0
  122. package/dist/pages/webhooks.js +88 -0
  123. package/dist/permissions.d.ts +5 -0
  124. package/dist/permissions.js +31 -0
  125. package/dist/proof.d.ts +10 -0
  126. package/dist/proof.js +78 -0
  127. package/dist/proxy.d.ts +10 -0
  128. package/dist/proxy.js +166 -0
  129. package/dist/retry.d.ts +8 -0
  130. package/dist/retry.js +30 -0
  131. package/dist/router.d.ts +13 -0
  132. package/dist/router.js +14 -0
  133. package/dist/setting-fields.d.ts +12 -0
  134. package/dist/setting-fields.js +102 -0
  135. package/dist/setting-list.d.ts +22 -0
  136. package/dist/setting-list.js +78 -0
  137. package/dist/shell.d.ts +40 -0
  138. package/dist/shell.js +97 -0
  139. package/dist/support.d.ts +37 -0
  140. package/dist/support.js +76 -0
  141. package/dist/table.d.ts +40 -0
  142. package/dist/table.js +73 -0
  143. package/dist/ui.d.ts +39 -0
  144. package/dist/ui.js +56 -0
  145. package/dist/user-actions.d.ts +30 -0
  146. package/dist/user-actions.js +129 -0
  147. package/dist/user-roles.d.ts +4 -0
  148. package/dist/user-roles.js +51 -0
  149. package/dist/user-row-menu.d.ts +14 -0
  150. package/dist/user-row-menu.js +45 -0
  151. package/dist/version.d.ts +1 -0
  152. package/dist/version.js +3 -0
  153. package/package.json +59 -4
  154. package/README.md +0 -3
@@ -0,0 +1,313 @@
1
+ //////////
2
+ // source: actions.go
3
+ /**
4
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
5
+ * the action name with outcome failure and the error code as reason.
6
+ */
7
+ export const ActionRegistered = "auth.Registered";
8
+ /**
9
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
10
+ * the action name with outcome failure and the error code as reason.
11
+ */
12
+ export const ActionSignedIn = "auth.SignedIn";
13
+ /**
14
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
15
+ * the action name with outcome failure and the error code as reason.
16
+ */
17
+ export const ActionSignedOut = "auth.SignedOut";
18
+ /**
19
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
20
+ * the action name with outcome failure and the error code as reason.
21
+ */
22
+ export const ActionSignedOutEverywhere = "auth.SignedOutEverywhere";
23
+ /**
24
+ * An admin's, on another user (docs/user-admin.md).
25
+ */
26
+ export const ActionUserSignedOut = "auth.UserSignedOut";
27
+ /**
28
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
29
+ * the action name with outcome failure and the error code as reason.
30
+ */
31
+ export const ActionUserSuspended = "users.UserSuspended";
32
+ /**
33
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
34
+ * the action name with outcome failure and the error code as reason.
35
+ */
36
+ export const ActionUserReactivated = "users.UserReactivated";
37
+ /**
38
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
39
+ * the action name with outcome failure and the error code as reason.
40
+ */
41
+ export const ActionRefreshTokenReused = "auth.RefreshTokenReused";
42
+ /**
43
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
44
+ * the action name with outcome failure and the error code as reason.
45
+ */
46
+ export const ActionPasswordChanged = "auth.PasswordChanged";
47
+ /**
48
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
49
+ * the action name with outcome failure and the error code as reason.
50
+ */
51
+ export const ActionPasswordReset = "auth.PasswordReset";
52
+ /**
53
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
54
+ * the action name with outcome failure and the error code as reason.
55
+ */
56
+ export const ActionPasswordResetRequested = "auth.PasswordResetRequested";
57
+ /**
58
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
59
+ * the action name with outcome failure and the error code as reason.
60
+ */
61
+ export const ActionIdentifierChanged = "auth.IdentifierChanged";
62
+ /**
63
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
64
+ * the action name with outcome failure and the error code as reason.
65
+ */
66
+ export const ActionIdentifierDetached = "auth.IdentifierDetached";
67
+ /**
68
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
69
+ * the action name with outcome failure and the error code as reason.
70
+ */
71
+ export const ActionContactConfirmed = "auth.ContactConfirmed";
72
+ /**
73
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
74
+ * the action name with outcome failure and the error code as reason.
75
+ */
76
+ export const ActionAccountClaimed = "auth.AccountClaimed";
77
+ /**
78
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
79
+ * the action name with outcome failure and the error code as reason.
80
+ */
81
+ export const ActionIdentityLinked = "auth.IdentityLinked";
82
+ /**
83
+ * Actions recorded in the audit log (section 42.1). A refused attempt keeps
84
+ * the action name with outcome failure and the error code as reason.
85
+ */
86
+ export const ActionIdentityUnlinked = "auth.IdentityUnlinked";
87
+ //////////
88
+ // source: consent.go
89
+ /**
90
+ * SettingTermsVersion is the terms a new user accepts; empty: none.
91
+ */
92
+ export const SettingTermsVersion = "auth.terms_version";
93
+ /**
94
+ * Consent documents.
95
+ */
96
+ export const DocumentTerms = "terms";
97
+ /**
98
+ * Consent documents.
99
+ */
100
+ export const DocumentMarketing = "marketing";
101
+ export const ErrCodeTermsRequired = "auth.terms_required";
102
+ export const ErrCodeTermsOutdated = "auth.terms_outdated";
103
+ /**
104
+ * ActionConsentChanged records an accepted terms version or a marketing
105
+ * opt-in change.
106
+ */
107
+ export const ActionConsentChanged = "auth.ConsentChanged";
108
+ /**
109
+ * ActionChangeIdentifier is the re-authentication action that
110
+ * PUT /v1/auth/identifier requires (X-Reauth-Token).
111
+ */
112
+ export const ActionChangeIdentifier = "change_identifier";
113
+ /**
114
+ * ActionLinkIdentity is the re-authentication action that
115
+ * POST /v1/auth/identities/{provider} requires: a connected provider can
116
+ * sign in to the account.
117
+ */
118
+ export const ActionLinkIdentity = "link_identity";
119
+ /**
120
+ * ActionUnlinkIdentity is the re-authentication action that
121
+ * DELETE /v1/auth/identities/{provider} requires: disconnecting removes a
122
+ * way to sign in.
123
+ */
124
+ export const ActionUnlinkIdentity = "unlink_identity";
125
+ //////////
126
+ // source: errors.go
127
+ /**
128
+ * Credential & Account error codes
129
+ */
130
+ export const ErrCodeInvalidCredentials = "auth.invalid_credentials";
131
+ /**
132
+ * Stable error codes for this module (section 42.5: <module>.<error>).
133
+ * These are part of the module's public contract: once released, a code must
134
+ * not change meaning.
135
+ */
136
+ export const ErrCodeUserNotFound = "auth.user_not_found";
137
+ /**
138
+ * Stable error codes for this module (section 42.5: <module>.<error>).
139
+ * These are part of the module's public contract: once released, a code must
140
+ * not change meaning.
141
+ */
142
+ export const ErrCodeUserAlreadyExists = "auth.user_already_exists";
143
+ /**
144
+ * Stable error codes for this module (section 42.5: <module>.<error>).
145
+ * These are part of the module's public contract: once released, a code must
146
+ * not change meaning.
147
+ */
148
+ export const ErrCodeInvalidMFAToken = "auth.invalid_mfa_token";
149
+ /**
150
+ * Stable error codes for this module (section 42.5: <module>.<error>).
151
+ * These are part of the module's public contract: once released, a code must
152
+ * not change meaning.
153
+ */
154
+ export const ErrCodeInvalidRefreshToken = "auth.invalid_refresh_token";
155
+ /**
156
+ * Stable error codes for this module (section 42.5: <module>.<error>).
157
+ * These are part of the module's public contract: once released, a code must
158
+ * not change meaning.
159
+ */
160
+ export const ErrCodeUnauthenticated = "auth.unauthenticated";
161
+ /**
162
+ * Stable error codes for this module (section 42.5: <module>.<error>).
163
+ * These are part of the module's public contract: once released, a code must
164
+ * not change meaning.
165
+ */
166
+ export const ErrCodeAccountSuspended = "auth.account_suspended";
167
+ /**
168
+ * Stable error codes for this module (section 42.5: <module>.<error>).
169
+ * These are part of the module's public contract: once released, a code must
170
+ * not change meaning.
171
+ */
172
+ export const ErrCodeAccountLocked = "auth.account_locked";
173
+ /**
174
+ * Stable error codes for this module (section 42.5: <module>.<error>).
175
+ * These are part of the module's public contract: once released, a code must
176
+ * not change meaning.
177
+ */
178
+ export const ErrCodeAccountRevoked = "auth.account_revoked";
179
+ /**
180
+ * Stable error codes for this module (section 42.5: <module>.<error>).
181
+ * These are part of the module's public contract: once released, a code must
182
+ * not change meaning.
183
+ */
184
+ export const ErrCodeAccountPending = "auth.account_pending";
185
+ /**
186
+ * Stable error codes for this module (section 42.5: <module>.<error>).
187
+ * These are part of the module's public contract: once released, a code must
188
+ * not change meaning.
189
+ */
190
+ export const ErrCodeInvalidCurrentPassword = "auth.invalid_current_password";
191
+ /**
192
+ * Social sign-in error codes
193
+ */
194
+ export const ErrCodeProviderUnavailable = "auth.provider_unavailable";
195
+ /**
196
+ * Stable error codes for this module (section 42.5: <module>.<error>).
197
+ * These are part of the module's public contract: once released, a code must
198
+ * not change meaning.
199
+ */
200
+ export const ErrCodeInvalidIdentityToken = "auth.invalid_identity_token";
201
+ /**
202
+ * Stable error codes for this module (section 42.5: <module>.<error>).
203
+ * These are part of the module's public contract: once released, a code must
204
+ * not change meaning.
205
+ */
206
+ export const ErrCodeAccountExists = "auth.account_exists";
207
+ /**
208
+ * Stable error codes for this module (section 42.5: <module>.<error>).
209
+ * These are part of the module's public contract: once released, a code must
210
+ * not change meaning.
211
+ */
212
+ export const ErrCodeIdentityInUse = "auth.identity_in_use";
213
+ /**
214
+ * Stable error codes for this module (section 42.5: <module>.<error>).
215
+ * These are part of the module's public contract: once released, a code must
216
+ * not change meaning.
217
+ */
218
+ export const ErrCodeProviderLinked = "auth.provider_already_linked";
219
+ /**
220
+ * Stable error codes for this module (section 42.5: <module>.<error>).
221
+ * These are part of the module's public contract: once released, a code must
222
+ * not change meaning.
223
+ */
224
+ export const ErrCodeIdentityNotFound = "auth.identity_not_found";
225
+ /**
226
+ * Stable error codes for this module (section 42.5: <module>.<error>).
227
+ * These are part of the module's public contract: once released, a code must
228
+ * not change meaning.
229
+ */
230
+ export const ErrCodeLastSignInMethod = "auth.last_sign_in_method";
231
+ /**
232
+ * Stable error codes for this module (section 42.5: <module>.<error>).
233
+ * These are part of the module's public contract: once released, a code must
234
+ * not change meaning.
235
+ */
236
+ export const ErrCodeInvalidNonce = "auth.invalid_nonce";
237
+ /**
238
+ * Stable error codes for this module (section 42.5: <module>.<error>).
239
+ * These are part of the module's public contract: once released, a code must
240
+ * not change meaning.
241
+ */
242
+ export const ErrCodeEmailNotVerified = "auth.email_not_verified";
243
+ /**
244
+ * Stable error codes for this module (section 42.5: <module>.<error>).
245
+ * These are part of the module's public contract: once released, a code must
246
+ * not change meaning.
247
+ */
248
+ export const ErrCodeUnverifiedAccount = "auth.unverified_account";
249
+ //////////
250
+ // source: permissions.go
251
+ /**
252
+ * An admin's actions on another user (docs/user-admin.md). Keys name the
253
+ * users they act on, though this module guards them: it owns sign-in and
254
+ * sessions.
255
+ */
256
+ export const PermissionSuspendUsers = "users.suspend";
257
+ /**
258
+ * An admin's actions on another user (docs/user-admin.md). Keys name the
259
+ * users they act on, though this module guards them: it owns sign-in and
260
+ * sessions.
261
+ */
262
+ export const PermissionSignOutUsers = "users.sign_out";
263
+ //////////
264
+ // source: ratelimits.go
265
+ /**
266
+ * Rate limit policies (each tunable through its two settings,
267
+ * auth.rate_limit.<name>.limit and .per_seconds).
268
+ */
269
+ export const RateLimitLogin = "auth.login";
270
+ /**
271
+ * RateLimitLoginAccount is per email signed in to, on top of the per-IP
272
+ * auth.login: attempts spread across many IPs (credential stuffing)
273
+ * still hit it.
274
+ */
275
+ export const RateLimitLoginAccount = "auth.login_account";
276
+ /**
277
+ * Rate limit policies (each tunable through its two settings,
278
+ * auth.rate_limit.<name>.limit and .per_seconds).
279
+ */
280
+ export const RateLimitRegister = "auth.register";
281
+ /**
282
+ * Rate limit policies (each tunable through its two settings,
283
+ * auth.rate_limit.<name>.limit and .per_seconds).
284
+ */
285
+ export const RateLimitPasswordReset = "auth.password_reset";
286
+ /**
287
+ * RateLimitChangePassword is per user: the current password is checked
288
+ * on every attempt, so it must not be guessable from a signed-in
289
+ * session.
290
+ */
291
+ export const RateLimitChangePassword = "auth.change_password";
292
+ /**
293
+ * Rate limit policies (each tunable through its two settings,
294
+ * auth.rate_limit.<name>.limit and .per_seconds).
295
+ */
296
+ export const RateLimitOAuth = "auth.oauth";
297
+ /**
298
+ * Rate limit policies (each tunable through its two settings,
299
+ * auth.rate_limit.<name>.limit and .per_seconds).
300
+ */
301
+ export const RateLimitRefresh = "auth.refresh";
302
+ //////////
303
+ // source: settings.go
304
+ /**
305
+ * SettingRequireVerifiedEmail: when on, password accounts get no tokens
306
+ * until their email is verified.
307
+ */
308
+ export const SettingRequireVerifiedEmail = "auth.require_verified_email";
309
+ /**
310
+ * SettingMFATokenTTLSeconds is how long a sign-in waits for its second
311
+ * factor.
312
+ */
313
+ export const SettingMFATokenTTLSeconds = "auth.mfa.token_ttl_seconds";
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Error is an application error. Code is the stable identifier clients may
3
+ * branch on, such as "tasks.not_found"; it must not change once released
4
+ * (Rule 19 applies the same stability rule to permissions).
5
+ */
6
+ export interface Error {
7
+ status: number;
8
+ error: string;
9
+ code?: string;
10
+ message?: string;
11
+ request_id?: string;
12
+ timestamp: string;
13
+ data?: {
14
+ [key: string]: unknown;
15
+ };
16
+ }
@@ -0,0 +1,2 @@
1
+ // Code generated by tygo. DO NOT EDIT.
2
+ export {};
@@ -0,0 +1,60 @@
1
+ /**
2
+ * Page is one page of a list, the response of every list endpoint.
3
+ * NextPage, PreviousPage and LastPage are links to other pages: the client
4
+ * sends one back as ?page=<value>, and null means there is no such page.
5
+ * They are not page numbers: pages are read by key, not skipped with
6
+ * OFFSET, so page 50,000 costs what page 1 does.
7
+ * Total is counted up to the pagination.count_cap setting. Above it,
8
+ * TotalCapped is true (show "5,000+"), and the count continues from the
9
+ * page that reaches it, so Total and TotalPages grow as the client goes
10
+ * forward. LastPage is given only once Total is exact.
11
+ */
12
+ export interface Page<T extends unknown> {
13
+ items: T[];
14
+ page: number;
15
+ total_pages: number;
16
+ total: number;
17
+ total_capped: boolean;
18
+ next_page?: string;
19
+ previous_page?: string;
20
+ last_page?: string;
21
+ }
22
+ /**
23
+ * Keyset is the order a list is paged in. A page starts after (or, going
24
+ * back, before) the boundary row's values instead of skipping rows, and
25
+ * rows added or removed meanwhile do not shift other pages.
26
+ * Columns end with a unique one (usually the primary key) so no two rows
27
+ * tie, must all be NOT NULL, and need an index in this order (after the
28
+ * equality filters) to stay fast on large tables. Values returns those
29
+ * columns' values from a row, in the same order.
30
+ */
31
+ export interface Keyset<M extends unknown> {
32
+ Columns: string[];
33
+ Desc: boolean;
34
+ Values: unknown;
35
+ }
36
+ /**
37
+ * PageLimits are the page sizes a list accepts (Default when the client
38
+ * sends no limit, Max the most it may ask for) and CountCap, the most rows
39
+ * one count reads.
40
+ */
41
+ export interface PageLimits {
42
+ Default: number;
43
+ Max: number;
44
+ CountCap: number;
45
+ }
46
+ /**
47
+ * Pagination settings, for every list endpoint. They belong to no module:
48
+ * the composition root registers them.
49
+ */
50
+ export declare const SettingPageDefaultLimit: string;
51
+ /**
52
+ * Pagination settings, for every list endpoint. They belong to no module:
53
+ * the composition root registers them.
54
+ */
55
+ export declare const SettingPageMaxLimit: string;
56
+ /**
57
+ * Pagination settings, for every list endpoint. They belong to no module:
58
+ * the composition root registers them.
59
+ */
60
+ export declare const SettingPageCountCap: string;
@@ -0,0 +1,16 @@
1
+ // Code generated by tygo. DO NOT EDIT.
2
+ /**
3
+ * Pagination settings, for every list endpoint. They belong to no module:
4
+ * the composition root registers them.
5
+ */
6
+ export const SettingPageDefaultLimit = "pagination.default_limit";
7
+ /**
8
+ * Pagination settings, for every list endpoint. They belong to no module:
9
+ * the composition root registers them.
10
+ */
11
+ export const SettingPageMaxLimit = "pagination.max_limit";
12
+ /**
13
+ * Pagination settings, for every list endpoint. They belong to no module:
14
+ * the composition root registers them.
15
+ */
16
+ export const SettingPageCountCap = "pagination.count_cap";
@@ -0,0 +1,103 @@
1
+ import type * as queue from "./queue.gen";
2
+ /**
3
+ * Overall statuses of the report.
4
+ */
5
+ export declare const StatusOK = "ok";
6
+ /**
7
+ * StatusDegraded: a non-critical check failed (the queue, no worker
8
+ * running). The API answers, but some work waits.
9
+ */
10
+ export declare const StatusDegraded = "degraded";
11
+ /**
12
+ * StatusDown: a critical check failed (the database, Redis). Almost
13
+ * nothing works.
14
+ */
15
+ export declare const StatusDown = "down";
16
+ /**
17
+ * Report is the system's state, as seen from the API process answering. It
18
+ * is refreshed at most every few seconds (CachedFor) however often it is
19
+ * asked for.
20
+ */
21
+ export interface Report {
22
+ status: string;
23
+ checked_at: string;
24
+ /**
25
+ * Checks are keyed by check name ("database", "redis", "queue",
26
+ * "<module>.<what>"): every module can add its own.
27
+ */
28
+ checks: {
29
+ [key: string]: Check;
30
+ };
31
+ process: Process;
32
+ }
33
+ /**
34
+ * Check is the result of one check. Status is "ok", "down" or "disabled".
35
+ */
36
+ export interface Check {
37
+ status: string;
38
+ critical: boolean;
39
+ latency_ms: number;
40
+ /**
41
+ * Message says what is wrong. Causes with hosts or user names are only
42
+ * in the server's log.
43
+ */
44
+ message?: string;
45
+ details?: unknown;
46
+ }
47
+ /**
48
+ * Process is the API process answering the request.
49
+ */
50
+ export interface Process {
51
+ app: string;
52
+ env: string;
53
+ /**
54
+ * FrameworkVersion is the colveor-go version the API was built with
55
+ * (named neutrally: a project's API doesn't name colveor)
56
+ * ("v0.5.0"; "(devel)" for a local checkout). The admin panel warns
57
+ * when it doesn't match its own.
58
+ */
59
+ framework_version: string;
60
+ started_at: string;
61
+ uptime_seconds: number;
62
+ go_version: string;
63
+ cpus: number;
64
+ goroutines: number;
65
+ heap_bytes: number;
66
+ }
67
+ /**
68
+ * DatabaseDetails is the connection pool of this process.
69
+ */
70
+ export interface DatabaseDetails {
71
+ open_connections: number;
72
+ in_use: number;
73
+ idle: number;
74
+ max_open: number;
75
+ wait_count: number;
76
+ wait_seconds: number;
77
+ }
78
+ export interface RedisDetails {
79
+ version: string;
80
+ used_memory_bytes: number;
81
+ connected_clients: number;
82
+ uptime_seconds: number;
83
+ }
84
+ /**
85
+ * QueueDetails are the job queues, the worker processes serving them, and
86
+ * today's runs of each job type.
87
+ */
88
+ export type QueueDetails = queue.Stats;
89
+ /**
90
+ * PermissionHealthRead guards the status report: it describes the system's
91
+ * internals, so it is not public like the probes.
92
+ */
93
+ export declare const PermissionHealthRead: string;
94
+ /**
95
+ * Service answers the probes.
96
+ */
97
+ export type Service = unknown;
98
+ /**
99
+ * StatusResponse is a probe's answer.
100
+ */
101
+ export interface StatusResponse {
102
+ status: string;
103
+ }
@@ -0,0 +1,23 @@
1
+ //////////
2
+ // source: dto.go
3
+ /**
4
+ * Overall statuses of the report.
5
+ */
6
+ export const StatusOK = "ok";
7
+ /**
8
+ * StatusDegraded: a non-critical check failed (the queue, no worker
9
+ * running). The API answers, but some work waits.
10
+ */
11
+ export const StatusDegraded = "degraded";
12
+ /**
13
+ * StatusDown: a critical check failed (the database, Redis). Almost
14
+ * nothing works.
15
+ */
16
+ export const StatusDown = "down";
17
+ //////////
18
+ // source: permissions.go
19
+ /**
20
+ * PermissionHealthRead guards the status report: it describes the system's
21
+ * internals, so it is not public like the probes.
22
+ */
23
+ export const PermissionHealthRead = "health.read";
@@ -0,0 +1,21 @@
1
+ export * as audit from "./audit.gen";
2
+ export * as auth from "./auth.gen";
3
+ export * as errors from "./errors.gen";
4
+ export * as gormx from "./gormx.gen";
5
+ export * as health from "./health.gen";
6
+ export * as invitations from "./invitations.gen";
7
+ export * as ledger from "./ledger.gen";
8
+ export * as msgtemplate from "./msgtemplate.gen";
9
+ export * as notifications from "./notifications.gen";
10
+ export * as outbox from "./outbox.gen";
11
+ export * as queue from "./queue.gen";
12
+ export * as rbac from "./rbac.gen";
13
+ export * as reauth from "./reauth.gen";
14
+ export * as recorded_payments from "./recorded_payments.gen";
15
+ export * as sessions from "./sessions.gen";
16
+ export * as settings from "./settings.gen";
17
+ export * as storage from "./storage.gen";
18
+ export * as support_access from "./support_access.gen";
19
+ export * as users from "./users.gen";
20
+ export * as verification from "./verification.gen";
21
+ export * as webhooks from "./webhooks.gen";
@@ -0,0 +1,22 @@
1
+ // Code generated by make generate. DO NOT EDIT.
2
+ export * as audit from "./audit.gen";
3
+ export * as auth from "./auth.gen";
4
+ export * as errors from "./errors.gen";
5
+ export * as gormx from "./gormx.gen";
6
+ export * as health from "./health.gen";
7
+ export * as invitations from "./invitations.gen";
8
+ export * as ledger from "./ledger.gen";
9
+ export * as msgtemplate from "./msgtemplate.gen";
10
+ export * as notifications from "./notifications.gen";
11
+ export * as outbox from "./outbox.gen";
12
+ export * as queue from "./queue.gen";
13
+ export * as rbac from "./rbac.gen";
14
+ export * as reauth from "./reauth.gen";
15
+ export * as recorded_payments from "./recorded_payments.gen";
16
+ export * as sessions from "./sessions.gen";
17
+ export * as settings from "./settings.gen";
18
+ export * as storage from "./storage.gen";
19
+ export * as support_access from "./support_access.gen";
20
+ export * as users from "./users.gen";
21
+ export * as verification from "./verification.gen";
22
+ export * as webhooks from "./webhooks.gen";