@distilled.cloud/forgejo 0.0.0 → 1.0.0-rc.9

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 (88) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +71 -0
  3. package/lib/credentials.d.ts +35 -0
  4. package/lib/credentials.d.ts.map +1 -0
  5. package/lib/credentials.js +57 -0
  6. package/lib/credentials.js.map +1 -0
  7. package/lib/errors.d.ts +56 -0
  8. package/lib/errors.d.ts.map +1 -0
  9. package/lib/errors.js +36 -0
  10. package/lib/errors.js.map +1 -0
  11. package/lib/index.d.ts +28 -0
  12. package/lib/index.d.ts.map +1 -0
  13. package/lib/index.js +28 -0
  14. package/lib/index.js.map +1 -0
  15. package/lib/protocol.d.ts +18 -0
  16. package/lib/protocol.d.ts.map +1 -0
  17. package/lib/protocol.js +61 -0
  18. package/lib/protocol.js.map +1 -0
  19. package/lib/retry.d.ts +50 -0
  20. package/lib/retry.d.ts.map +1 -0
  21. package/lib/retry.js +43 -0
  22. package/lib/retry.js.map +1 -0
  23. package/lib/services/activitypub.d.ts +121 -0
  24. package/lib/services/activitypub.d.ts.map +1 -0
  25. package/lib/services/activitypub.js +202 -0
  26. package/lib/services/activitypub.js.map +1 -0
  27. package/lib/services/admin.d.ts +1196 -0
  28. package/lib/services/admin.d.ts.map +1 -0
  29. package/lib/services/admin.js +1276 -0
  30. package/lib/services/admin.js.map +1 -0
  31. package/lib/services/index.d.ts +11 -0
  32. package/lib/services/index.d.ts.map +1 -0
  33. package/lib/services/index.js +12 -0
  34. package/lib/services/index.js.map +1 -0
  35. package/lib/services/issue.d.ts +1479 -0
  36. package/lib/services/issue.d.ts.map +1 -0
  37. package/lib/services/issue.js +1732 -0
  38. package/lib/services/issue.js.map +1 -0
  39. package/lib/services/miscellaneous.d.ts +494 -0
  40. package/lib/services/miscellaneous.d.ts.map +1 -0
  41. package/lib/services/miscellaneous.js +471 -0
  42. package/lib/services/miscellaneous.js.map +1 -0
  43. package/lib/services/notification.d.ts +390 -0
  44. package/lib/services/notification.d.ts.map +1 -0
  45. package/lib/services/notification.js +344 -0
  46. package/lib/services/notification.js.map +1 -0
  47. package/lib/services/organization.d.ts +1593 -0
  48. package/lib/services/organization.d.ts.map +1 -0
  49. package/lib/services/organization.js +1672 -0
  50. package/lib/services/organization.js.map +1 -0
  51. package/lib/services/package.d.ts +347 -0
  52. package/lib/services/package.d.ts.map +1 -0
  53. package/lib/services/package.js +320 -0
  54. package/lib/services/package.js.map +1 -0
  55. package/lib/services/repository.d.ts +4770 -0
  56. package/lib/services/repository.d.ts.map +1 -0
  57. package/lib/services/repository.js +5449 -0
  58. package/lib/services/repository.js.map +1 -0
  59. package/lib/services/settings.d.ts +67 -0
  60. package/lib/services/settings.d.ts.map +1 -0
  61. package/lib/services/settings.js +87 -0
  62. package/lib/services/settings.js.map +1 -0
  63. package/lib/services/user.d.ts +1764 -0
  64. package/lib/services/user.d.ts.map +1 -0
  65. package/lib/services/user.js +1921 -0
  66. package/lib/services/user.js.map +1 -0
  67. package/lib/traits.d.ts +10 -0
  68. package/lib/traits.d.ts.map +1 -0
  69. package/lib/traits.js +11 -0
  70. package/lib/traits.js.map +1 -0
  71. package/package.json +78 -6
  72. package/src/credentials.ts +89 -0
  73. package/src/errors.ts +72 -0
  74. package/src/index.ts +31 -0
  75. package/src/protocol.ts +86 -0
  76. package/src/retry.ts +74 -0
  77. package/src/services/activitypub.ts +415 -0
  78. package/src/services/admin.ts +3103 -0
  79. package/src/services/index.ts +11 -0
  80. package/src/services/issue.ts +3949 -0
  81. package/src/services/miscellaneous.ts +1118 -0
  82. package/src/services/notification.ts +847 -0
  83. package/src/services/organization.ts +4008 -0
  84. package/src/services/package.ts +767 -0
  85. package/src/services/repository.ts +12839 -0
  86. package/src/services/settings.ts +190 -0
  87. package/src/services/user.ts +4669 -0
  88. package/src/traits.ts +44 -0
@@ -0,0 +1,1118 @@
1
+ // AUTO-GENERATED by scripts/generate.ts from .generated-specs (specs/spec-mirror-forgejo). Do not edit.
2
+ import * as S from "@distilled.cloud/core/schema";
3
+ import * as API from "@distilled.cloud/core/api";
4
+ import * as C from "@distilled.cloud/core/category";
5
+ import * as T from "../traits.ts";
6
+ import {
7
+ ForgejoProtocol,
8
+ type ForgejoOpError,
9
+ type ForgejoOpContext,
10
+ } from "../protocol.ts";
11
+ import * as Retry from "../retry.ts";
12
+
13
+ export type { ForgejoOpError, ForgejoOpContext };
14
+
15
+ export class NotFound
16
+ extends /*@__PURE__*/ T.applyErrorMatchers(
17
+ /*@__PURE__*/ S.TaggedError<NotFound>()("NotFound", {
18
+ code: S.Number,
19
+ message: S.String,
20
+ }).pipe(C.withBadRequestError),
21
+ [{ status: 404 }],
22
+ ) {}
23
+
24
+ export class UnprocessableEntity
25
+ extends /*@__PURE__*/ T.applyErrorMatchers(
26
+ /*@__PURE__*/ S.TaggedError<UnprocessableEntity>()("UnprocessableEntity", {
27
+ code: S.Number,
28
+ message: S.String,
29
+ }).pipe(C.withBadRequestError),
30
+ [{ status: 422 }],
31
+ ) {}
32
+
33
+ export interface GetActionsRunRequest {}
34
+ export const GetActionsRunRequest = /*@__PURE__*/ S.suspend(() =>
35
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/actions/run", code: 200 })),
36
+ ).annotate({
37
+ identifier: "GetActionsRunRequest",
38
+ }) as any as S.Schema<GetActionsRunRequest>;
39
+
40
+ /** ExternalTracker represents settings for external tracker */
41
+ export interface ExternalTracker {
42
+ /** External Issue Tracker URL Format. Use the placeholders {user}, {repo} and {index} for the username, repository name and issue index. */
43
+ external_tracker_format?: string;
44
+ /** External Issue Tracker issue regular expression */
45
+ external_tracker_regexp_pattern?: string;
46
+ /** External Issue Tracker Number Format, either `numeric`, `alphanumeric`, or `regexp` */
47
+ external_tracker_style?: string;
48
+ /** URL of external issue tracker. */
49
+ external_tracker_url?: string;
50
+ }
51
+ export const ExternalTracker = /*@__PURE__*/ S.suspend(() =>
52
+ S.Struct({
53
+ external_tracker_format: S.optional(S.String),
54
+ external_tracker_regexp_pattern: S.optional(S.String),
55
+ external_tracker_style: S.optional(S.String),
56
+ external_tracker_url: S.optional(S.String),
57
+ }),
58
+ ).annotate({
59
+ identifier: "ExternalTracker",
60
+ }) as any as S.Schema<ExternalTracker>;
61
+
62
+ /** ExternalWiki represents setting for external wiki */
63
+ export interface ExternalWiki {
64
+ /** URL of external wiki. */
65
+ external_wiki_url?: string;
66
+ }
67
+ export const ExternalWiki = /*@__PURE__*/ S.suspend(() =>
68
+ S.Struct({
69
+ external_wiki_url: S.optional(S.String),
70
+ }),
71
+ ).annotate({ identifier: "ExternalWiki" }) as any as S.Schema<ExternalWiki>;
72
+
73
+ /** InternalTracker represents settings for internal tracker */
74
+ export interface InternalTracker {
75
+ /** Let only contributors track time (Built-in issue tracker) */
76
+ allow_only_contributors_to_track_time?: boolean;
77
+ /** Enable dependencies for issues and pull requests (Built-in issue tracker) */
78
+ enable_issue_dependencies?: boolean;
79
+ /** Enable time tracking (Built-in issue tracker) */
80
+ enable_time_tracker?: boolean;
81
+ }
82
+ export const InternalTracker = /*@__PURE__*/ S.suspend(() =>
83
+ S.Struct({
84
+ allow_only_contributors_to_track_time: S.optional(S.Boolean),
85
+ enable_issue_dependencies: S.optional(S.Boolean),
86
+ enable_time_tracker: S.optional(S.Boolean),
87
+ }),
88
+ ).annotate({
89
+ identifier: "InternalTracker",
90
+ }) as any as S.Schema<InternalTracker>;
91
+
92
+ /** ObjectFormatName of the underlying git repository */
93
+ export type RepositoryObjectFormatName = "sha1" | "sha256";
94
+ export const RepositoryObjectFormatName = /*@__PURE__*/ S.String;
95
+
96
+ /** User represents a user */
97
+ export interface User {
98
+ /** Is user active */
99
+ active?: boolean;
100
+ /** URL to the user's avatar */
101
+ avatar_url?: string;
102
+ created?: string;
103
+ /** the user's description */
104
+ description?: string;
105
+ email?: string;
106
+ /** user counts */
107
+ followers_count?: number;
108
+ following_count?: number;
109
+ /** the user's full name */
110
+ full_name?: string;
111
+ /** URL to the user's profile page */
112
+ html_url?: string;
113
+ /** the user's id */
114
+ id: number;
115
+ /** Is the user an administrator */
116
+ is_admin?: boolean;
117
+ /** User locale */
118
+ language?: string;
119
+ last_login?: string;
120
+ /** the user's location */
121
+ location?: string;
122
+ /** the user's username */
123
+ login: string;
124
+ /** the user's authentication sign-in name. */
125
+ login_name?: string;
126
+ /** Is user login prohibited */
127
+ prohibit_login?: boolean;
128
+ /** the user's pronouns */
129
+ pronouns?: string;
130
+ /** Is user restricted */
131
+ restricted?: boolean;
132
+ /** The ID of the user's Authentication Source */
133
+ source_id?: number;
134
+ starred_repos_count?: number;
135
+ /** User visibility level option: public, limited, private */
136
+ visibility?: string;
137
+ /** the user's website */
138
+ website?: string;
139
+ }
140
+ export const User = /*@__PURE__*/ S.suspend(() =>
141
+ S.Struct({
142
+ active: S.optional(S.Boolean),
143
+ avatar_url: S.optional(S.String),
144
+ created: S.optional(S.String),
145
+ description: S.optional(S.String),
146
+ email: S.optional(S.String),
147
+ followers_count: S.optional(S.Number),
148
+ following_count: S.optional(S.Number),
149
+ full_name: S.optional(S.String),
150
+ html_url: S.optional(S.String),
151
+ id: S.Number,
152
+ is_admin: S.optional(S.Boolean),
153
+ language: S.optional(S.String),
154
+ last_login: S.optional(S.String),
155
+ location: S.optional(S.String),
156
+ login: S.String,
157
+ login_name: S.optional(S.String),
158
+ prohibit_login: S.optional(S.Boolean),
159
+ pronouns: S.optional(S.String),
160
+ restricted: S.optional(S.Boolean),
161
+ source_id: S.optional(S.Number),
162
+ starred_repos_count: S.optional(S.Number),
163
+ visibility: S.optional(S.String),
164
+ website: S.optional(S.String),
165
+ }),
166
+ ).annotate({ identifier: "User" }) as any as S.Schema<User>;
167
+
168
+ /** Permission represents a set of permissions */
169
+ export interface Permission {
170
+ admin?: boolean;
171
+ pull?: boolean;
172
+ push?: boolean;
173
+ }
174
+ export const Permission = /*@__PURE__*/ S.suspend(() =>
175
+ S.Struct({
176
+ admin: S.optional(S.Boolean),
177
+ pull: S.optional(S.Boolean),
178
+ push: S.optional(S.Boolean),
179
+ }),
180
+ ).annotate({ identifier: "Permission" }) as any as S.Schema<Permission>;
181
+
182
+ /** Organization represents an organization */
183
+ export interface Organization {
184
+ avatar_url?: string;
185
+ created?: string;
186
+ description?: string;
187
+ email?: string;
188
+ full_name?: string;
189
+ id: number;
190
+ location?: string;
191
+ name?: string;
192
+ repo_admin_change_team_access?: boolean;
193
+ /** deprecated */
194
+ username: string;
195
+ visibility?: string;
196
+ website?: string;
197
+ }
198
+ export const Organization = /*@__PURE__*/ S.suspend(() =>
199
+ S.Struct({
200
+ avatar_url: S.optional(S.String),
201
+ created: S.optional(S.String),
202
+ description: S.optional(S.String),
203
+ email: S.optional(S.String),
204
+ full_name: S.optional(S.String),
205
+ id: S.Number,
206
+ location: S.optional(S.String),
207
+ name: S.optional(S.String),
208
+ repo_admin_change_team_access: S.optional(S.Boolean),
209
+ username: S.String,
210
+ visibility: S.optional(S.String),
211
+ website: S.optional(S.String),
212
+ }),
213
+ ).annotate({ identifier: "Organization" }) as any as S.Schema<Organization>;
214
+
215
+ export type TeamPermission = "none" | "read" | "write" | "admin" | "owner";
216
+ export const TeamPermission = /*@__PURE__*/ S.String;
217
+
218
+ export type TeamUnitsList = Array<string>;
219
+ export const TeamUnitsList = /*@__PURE__*/ S.Array(
220
+ S.String,
221
+ ) as any as S.Schema<TeamUnitsList>;
222
+
223
+ export type TeamUnitsMapMap = { [key: string]: string | undefined };
224
+ export const TeamUnitsMapMap = /*@__PURE__*/ S.Record(
225
+ S.String,
226
+ S.String,
227
+ ) as any as S.Schema<TeamUnitsMapMap>;
228
+
229
+ /** Team represents a team in an organization */
230
+ export interface Team {
231
+ can_create_org_repo?: boolean;
232
+ description?: string;
233
+ id: number;
234
+ includes_all_repositories?: boolean;
235
+ name: string;
236
+ organization?: Organization;
237
+ permission?: TeamPermission;
238
+ units?: TeamUnitsList;
239
+ units_map?: TeamUnitsMapMap;
240
+ }
241
+ export const Team = /*@__PURE__*/ S.suspend(() =>
242
+ S.Struct({
243
+ can_create_org_repo: S.optional(S.Boolean),
244
+ description: S.optional(S.String),
245
+ id: S.Number,
246
+ includes_all_repositories: S.optional(S.Boolean),
247
+ name: S.String,
248
+ organization: S.optional(Organization),
249
+ permission: S.optional(TeamPermission),
250
+ units: S.optional(TeamUnitsList),
251
+ units_map: S.optional(TeamUnitsMapMap),
252
+ }),
253
+ ).annotate({ identifier: "Team" }) as any as S.Schema<Team>;
254
+
255
+ export type RepoTransferTeamsList = Array<Team>;
256
+ export const RepoTransferTeamsList = /*@__PURE__*/ S.Array(
257
+ Team,
258
+ ) as any as S.Schema<RepoTransferTeamsList>;
259
+
260
+ /** RepoTransfer represents a pending repo transfer */
261
+ export interface RepoTransfer {
262
+ doer?: User;
263
+ recipient?: User;
264
+ teams?: RepoTransferTeamsList;
265
+ }
266
+ export const RepoTransfer = /*@__PURE__*/ S.suspend(() =>
267
+ S.Struct({
268
+ doer: S.optional(User),
269
+ recipient: S.optional(User),
270
+ teams: S.optional(RepoTransferTeamsList),
271
+ }),
272
+ ).annotate({ identifier: "RepoTransfer" }) as any as S.Schema<RepoTransfer>;
273
+
274
+ export type RepositoryTopicsList = Array<string>;
275
+ export const RepositoryTopicsList = /*@__PURE__*/ S.Array(
276
+ S.String,
277
+ ) as any as S.Schema<RepositoryTopicsList>;
278
+
279
+ /** Repository represents a repository */
280
+ export interface Repository {
281
+ allow_fast_forward_only_merge?: boolean;
282
+ allow_merge_commits?: boolean;
283
+ allow_rebase?: boolean;
284
+ allow_rebase_explicit?: boolean;
285
+ allow_rebase_update?: boolean;
286
+ allow_squash_merge?: boolean;
287
+ archived?: boolean;
288
+ archived_at?: string;
289
+ avatar_url?: string;
290
+ clone_url: string;
291
+ created_at: string;
292
+ default_allow_maintainer_edit?: boolean;
293
+ default_branch: string;
294
+ default_delete_branch_after_merge?: boolean;
295
+ default_merge_style?: string;
296
+ default_update_style?: string;
297
+ description?: string;
298
+ empty?: boolean;
299
+ external_tracker?: ExternalTracker;
300
+ external_wiki?: ExternalWiki;
301
+ fork?: boolean;
302
+ forks_count?: number;
303
+ full_name: string;
304
+ globally_editable_wiki?: boolean;
305
+ has_actions?: boolean;
306
+ has_issues?: boolean;
307
+ has_packages?: boolean;
308
+ has_projects?: boolean;
309
+ has_pull_requests?: boolean;
310
+ has_releases?: boolean;
311
+ /** is the wiki enabled */
312
+ has_wiki?: boolean;
313
+ /** have wiki pages ever been created */
314
+ has_wiki_contents?: boolean;
315
+ html_url: string;
316
+ id: number;
317
+ ignore_whitespace_conflicts?: boolean;
318
+ internal?: boolean;
319
+ internal_tracker?: InternalTracker;
320
+ language?: string;
321
+ languages_url?: string;
322
+ link?: string;
323
+ mirror?: boolean;
324
+ mirror_interval?: string;
325
+ mirror_updated?: string;
326
+ name: string;
327
+ /** ObjectFormatName of the underlying git repository */
328
+ object_format_name?: RepositoryObjectFormatName;
329
+ open_issues_count?: number;
330
+ open_pr_counter?: number;
331
+ original_url?: string;
332
+ owner: User;
333
+ parent?: Repository;
334
+ permissions?: Permission;
335
+ private?: boolean;
336
+ release_counter?: number;
337
+ repo_transfer?: RepoTransfer;
338
+ size?: number;
339
+ ssh_url: string;
340
+ stars_count?: number;
341
+ template?: boolean;
342
+ topics?: RepositoryTopicsList;
343
+ updated_at: string;
344
+ url?: string;
345
+ watchers_count?: number;
346
+ website?: string;
347
+ wiki_branch?: string;
348
+ wiki_clone_url?: string;
349
+ wiki_ssh_url?: string;
350
+ }
351
+ export const Repository = /*@__PURE__*/ S.suspend(() =>
352
+ S.Struct({
353
+ allow_fast_forward_only_merge: S.optional(S.Boolean),
354
+ allow_merge_commits: S.optional(S.Boolean),
355
+ allow_rebase: S.optional(S.Boolean),
356
+ allow_rebase_explicit: S.optional(S.Boolean),
357
+ allow_rebase_update: S.optional(S.Boolean),
358
+ allow_squash_merge: S.optional(S.Boolean),
359
+ archived: S.optional(S.Boolean),
360
+ archived_at: S.optional(S.String),
361
+ avatar_url: S.optional(S.String),
362
+ clone_url: S.String,
363
+ created_at: S.String,
364
+ default_allow_maintainer_edit: S.optional(S.Boolean),
365
+ default_branch: S.String,
366
+ default_delete_branch_after_merge: S.optional(S.Boolean),
367
+ default_merge_style: S.optional(S.String),
368
+ default_update_style: S.optional(S.String),
369
+ description: S.optional(S.String),
370
+ empty: S.optional(S.Boolean),
371
+ external_tracker: S.optional(ExternalTracker),
372
+ external_wiki: S.optional(ExternalWiki),
373
+ fork: S.optional(S.Boolean),
374
+ forks_count: S.optional(S.Number),
375
+ full_name: S.String,
376
+ globally_editable_wiki: S.optional(S.Boolean),
377
+ has_actions: S.optional(S.Boolean),
378
+ has_issues: S.optional(S.Boolean),
379
+ has_packages: S.optional(S.Boolean),
380
+ has_projects: S.optional(S.Boolean),
381
+ has_pull_requests: S.optional(S.Boolean),
382
+ has_releases: S.optional(S.Boolean),
383
+ has_wiki: S.optional(S.Boolean),
384
+ has_wiki_contents: S.optional(S.Boolean),
385
+ html_url: S.String,
386
+ id: S.Number,
387
+ ignore_whitespace_conflicts: S.optional(S.Boolean),
388
+ internal: S.optional(S.Boolean),
389
+ internal_tracker: S.optional(InternalTracker),
390
+ language: S.optional(S.String),
391
+ languages_url: S.optional(S.String),
392
+ link: S.optional(S.String),
393
+ mirror: S.optional(S.Boolean),
394
+ mirror_interval: S.optional(S.String),
395
+ mirror_updated: S.optional(S.String),
396
+ name: S.String,
397
+ object_format_name: S.optional(RepositoryObjectFormatName),
398
+ open_issues_count: S.optional(S.Number),
399
+ open_pr_counter: S.optional(S.Number),
400
+ original_url: S.optional(S.String),
401
+ owner: User,
402
+ parent: S.optional(Repository),
403
+ permissions: S.optional(Permission),
404
+ private: S.optional(S.Boolean),
405
+ release_counter: S.optional(S.Number),
406
+ repo_transfer: S.optional(RepoTransfer),
407
+ size: S.optional(S.Number),
408
+ ssh_url: S.String,
409
+ stars_count: S.optional(S.Number),
410
+ template: S.optional(S.Boolean),
411
+ topics: S.optional(RepositoryTopicsList),
412
+ updated_at: S.String,
413
+ url: S.optional(S.String),
414
+ watchers_count: S.optional(S.Number),
415
+ website: S.optional(S.String),
416
+ wiki_branch: S.optional(S.String),
417
+ wiki_clone_url: S.optional(S.String),
418
+ wiki_ssh_url: S.optional(S.String),
419
+ }),
420
+ ).annotate({ identifier: "Repository" }) as any as S.Schema<Repository>;
421
+
422
+ /** ActionRun represents an action run */
423
+ export interface ActionRun {
424
+ /** the cron id for the schedule trigger */
425
+ ScheduleID?: number;
426
+ /** who approved this action run */
427
+ approved_by?: number;
428
+ /** the commit sha the action run ran on */
429
+ commit_sha?: string;
430
+ /** when the action run was created */
431
+ created?: string;
432
+ duration?: number;
433
+ /** the webhook event that causes the workflow to run */
434
+ event?: string;
435
+ /** the payload of the webhook event that causes the workflow to run */
436
+ event_payload?: string;
437
+ /** the url of this action run */
438
+ html_url?: string;
439
+ /** the action run id */
440
+ id?: number;
441
+ /** a unique number for each run of a repository */
442
+ index_in_repo?: number;
443
+ /** If this is triggered by a PR from a forked repository or an untrusted user, we need to check if it is approved and limit permissions when running the workflow. */
444
+ is_fork_pull_request?: boolean;
445
+ /** has the commit/tag/… the action run ran on been deleted */
446
+ is_ref_deleted?: boolean;
447
+ /** may need approval if it's a fork pull request */
448
+ need_approval?: boolean;
449
+ /** the commit/tag/… the action run ran on */
450
+ prettyref?: string;
451
+ repository?: Repository;
452
+ /** when the action run was started */
453
+ started?: string;
454
+ /** the current status of this run */
455
+ status?: string;
456
+ /** when the action run was stopped */
457
+ stopped?: string;
458
+ /** the action run's title */
459
+ title?: string;
460
+ /** the trigger event defined in the `on` configuration of the triggered workflow */
461
+ trigger_event?: string;
462
+ trigger_user?: User;
463
+ /** when the action run was last updated */
464
+ updated?: string;
465
+ /** the name of workflow file */
466
+ workflow_id?: string;
467
+ }
468
+ export const ActionRun = /*@__PURE__*/ S.suspend(() =>
469
+ S.Struct({
470
+ ScheduleID: S.optional(S.Number),
471
+ approved_by: S.optional(S.Number),
472
+ commit_sha: S.optional(S.String),
473
+ created: S.optional(S.String),
474
+ duration: S.optional(S.Number),
475
+ event: S.optional(S.String),
476
+ event_payload: S.optional(S.String),
477
+ html_url: S.optional(S.String),
478
+ id: S.optional(S.Number),
479
+ index_in_repo: S.optional(S.Number),
480
+ is_fork_pull_request: S.optional(S.Boolean),
481
+ is_ref_deleted: S.optional(S.Boolean),
482
+ need_approval: S.optional(S.Boolean),
483
+ prettyref: S.optional(S.String),
484
+ repository: S.optional(Repository),
485
+ started: S.optional(S.String),
486
+ status: S.optional(S.String),
487
+ stopped: S.optional(S.String),
488
+ title: S.optional(S.String),
489
+ trigger_event: S.optional(S.String),
490
+ trigger_user: S.optional(User),
491
+ updated: S.optional(S.String),
492
+ workflow_id: S.optional(S.String),
493
+ }),
494
+ ).annotate({ identifier: "ActionRun" }) as any as S.Schema<ActionRun>;
495
+
496
+ export interface GetGitignoreTemplateInfoRequest {
497
+ /** name of the template */
498
+ name: string;
499
+ }
500
+ export const GetGitignoreTemplateInfoRequest = /*@__PURE__*/ S.suspend(() =>
501
+ S.Struct({
502
+ name: S.String.pipe(T.Label()),
503
+ }).pipe(
504
+ T.Http({ method: "GET", uri: "/gitignore/templates/{name}", code: 200 }),
505
+ ),
506
+ ).annotate({
507
+ identifier: "GetGitignoreTemplateInfoRequest",
508
+ }) as any as S.Schema<GetGitignoreTemplateInfoRequest>;
509
+
510
+ /** GitignoreTemplateInfo name and text of a gitignore template */
511
+ export interface GitignoreTemplateInfo {
512
+ name?: string;
513
+ source?: string;
514
+ }
515
+ export const GitignoreTemplateInfo = /*@__PURE__*/ S.suspend(() =>
516
+ S.Struct({
517
+ name: S.optional(S.String),
518
+ source: S.optional(S.String),
519
+ }),
520
+ ).annotate({
521
+ identifier: "GitignoreTemplateInfo",
522
+ }) as any as S.Schema<GitignoreTemplateInfo>;
523
+
524
+ export interface GetLabelTemplateInfoRequest {
525
+ /** name of the template */
526
+ name: string;
527
+ }
528
+ export const GetLabelTemplateInfoRequest = /*@__PURE__*/ S.suspend(() =>
529
+ S.Struct({
530
+ name: S.String.pipe(T.Label()),
531
+ }).pipe(T.Http({ method: "GET", uri: "/label/templates/{name}", code: 200 })),
532
+ ).annotate({
533
+ identifier: "GetLabelTemplateInfoRequest",
534
+ }) as any as S.Schema<GetLabelTemplateInfoRequest>;
535
+
536
+ /** LabelTemplate info of a Label template */
537
+ export interface LabelTemplate {
538
+ color?: string;
539
+ description?: string;
540
+ exclusive?: boolean;
541
+ name?: string;
542
+ }
543
+ export const LabelTemplate = /*@__PURE__*/ S.suspend(() =>
544
+ S.Struct({
545
+ color: S.optional(S.String),
546
+ description: S.optional(S.String),
547
+ exclusive: S.optional(S.Boolean),
548
+ name: S.optional(S.String),
549
+ }),
550
+ ).annotate({ identifier: "LabelTemplate" }) as any as S.Schema<LabelTemplate>;
551
+
552
+ export type GetLabelTemplateInfoResponseBodyList = Array<LabelTemplate>;
553
+ export const GetLabelTemplateInfoResponseBodyList = /*@__PURE__*/ S.Array(
554
+ LabelTemplate,
555
+ ) as any as S.Schema<GetLabelTemplateInfoResponseBodyList>;
556
+
557
+ export type GetLabelTemplateInfoResponse = GetLabelTemplateInfoResponseBodyList;
558
+ export const GetLabelTemplateInfoResponse = /*@__PURE__*/ S.suspend(() =>
559
+ GetLabelTemplateInfoResponseBodyList.pipe(T.RawResponseRoot()),
560
+ ).annotate({
561
+ identifier: "GetLabelTemplateInfoResponse",
562
+ }) as any as S.Schema<GetLabelTemplateInfoResponse>;
563
+
564
+ export interface GetLicenseTemplateInfoRequest {
565
+ /** name of the license */
566
+ name: string;
567
+ }
568
+ export const GetLicenseTemplateInfoRequest = /*@__PURE__*/ S.suspend(() =>
569
+ S.Struct({
570
+ name: S.String.pipe(T.Label()),
571
+ }).pipe(T.Http({ method: "GET", uri: "/licenses/{name}", code: 200 })),
572
+ ).annotate({
573
+ identifier: "GetLicenseTemplateInfoRequest",
574
+ }) as any as S.Schema<GetLicenseTemplateInfoRequest>;
575
+
576
+ /** LicensesInfo contains information about a License */
577
+ export interface LicenseTemplateInfo {
578
+ body?: string;
579
+ implementation?: string;
580
+ key?: string;
581
+ name?: string;
582
+ url?: string;
583
+ }
584
+ export const LicenseTemplateInfo = /*@__PURE__*/ S.suspend(() =>
585
+ S.Struct({
586
+ body: S.optional(S.String),
587
+ implementation: S.optional(S.String),
588
+ key: S.optional(S.String),
589
+ name: S.optional(S.String),
590
+ url: S.optional(S.String),
591
+ }),
592
+ ).annotate({
593
+ identifier: "LicenseTemplateInfo",
594
+ }) as any as S.Schema<LicenseTemplateInfo>;
595
+
596
+ export interface GetNodeInfoRequest {}
597
+ export const GetNodeInfoRequest = /*@__PURE__*/ S.suspend(() =>
598
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/nodeinfo", code: 200 })),
599
+ ).annotate({
600
+ identifier: "GetNodeInfoRequest",
601
+ }) as any as S.Schema<GetNodeInfoRequest>;
602
+
603
+ export type NodeInfoProtocolsList = Array<string>;
604
+ export const NodeInfoProtocolsList = /*@__PURE__*/ S.Array(
605
+ S.String,
606
+ ) as any as S.Schema<NodeInfoProtocolsList>;
607
+
608
+ export type NodeInfoServicesInboundList = Array<string>;
609
+ export const NodeInfoServicesInboundList = /*@__PURE__*/ S.Array(
610
+ S.String,
611
+ ) as any as S.Schema<NodeInfoServicesInboundList>;
612
+
613
+ export type NodeInfoServicesOutboundList = Array<string>;
614
+ export const NodeInfoServicesOutboundList = /*@__PURE__*/ S.Array(
615
+ S.String,
616
+ ) as any as S.Schema<NodeInfoServicesOutboundList>;
617
+
618
+ /** NodeInfoServices contains the third party sites this server can connect to via their application API */
619
+ export interface NodeInfoServices {
620
+ inbound?: NodeInfoServicesInboundList;
621
+ outbound?: NodeInfoServicesOutboundList;
622
+ }
623
+ export const NodeInfoServices = /*@__PURE__*/ S.suspend(() =>
624
+ S.Struct({
625
+ inbound: S.optional(NodeInfoServicesInboundList),
626
+ outbound: S.optional(NodeInfoServicesOutboundList),
627
+ }),
628
+ ).annotate({
629
+ identifier: "NodeInfoServices",
630
+ }) as any as S.Schema<NodeInfoServices>;
631
+
632
+ /** NodeInfoSoftware contains Metadata about server software in use */
633
+ export interface NodeInfoSoftware {
634
+ homepage?: string;
635
+ name?: string;
636
+ repository?: string;
637
+ version?: string;
638
+ }
639
+ export const NodeInfoSoftware = /*@__PURE__*/ S.suspend(() =>
640
+ S.Struct({
641
+ homepage: S.optional(S.String),
642
+ name: S.optional(S.String),
643
+ repository: S.optional(S.String),
644
+ version: S.optional(S.String),
645
+ }),
646
+ ).annotate({
647
+ identifier: "NodeInfoSoftware",
648
+ }) as any as S.Schema<NodeInfoSoftware>;
649
+
650
+ /** NodeInfoUsageUsers contains statistics about the users of this server */
651
+ export interface NodeInfoUsageUsers {
652
+ activeHalfyear?: number;
653
+ activeMonth?: number;
654
+ total?: number;
655
+ }
656
+ export const NodeInfoUsageUsers = /*@__PURE__*/ S.suspend(() =>
657
+ S.Struct({
658
+ activeHalfyear: S.optional(S.Number),
659
+ activeMonth: S.optional(S.Number),
660
+ total: S.optional(S.Number),
661
+ }),
662
+ ).annotate({
663
+ identifier: "NodeInfoUsageUsers",
664
+ }) as any as S.Schema<NodeInfoUsageUsers>;
665
+
666
+ /** NodeInfoUsage contains usage statistics for this server */
667
+ export interface NodeInfoUsage {
668
+ localComments?: number;
669
+ localPosts?: number;
670
+ users?: NodeInfoUsageUsers;
671
+ }
672
+ export const NodeInfoUsage = /*@__PURE__*/ S.suspend(() =>
673
+ S.Struct({
674
+ localComments: S.optional(S.Number),
675
+ localPosts: S.optional(S.Number),
676
+ users: S.optional(NodeInfoUsageUsers),
677
+ }),
678
+ ).annotate({ identifier: "NodeInfoUsage" }) as any as S.Schema<NodeInfoUsage>;
679
+
680
+ /** NodeInfo contains standardized way of exposing metadata about a server running one of the distributed social networks */
681
+ export interface NodeInfo {
682
+ metadata?: unknown;
683
+ openRegistrations?: boolean;
684
+ protocols?: NodeInfoProtocolsList;
685
+ services?: NodeInfoServices;
686
+ software?: NodeInfoSoftware;
687
+ usage?: NodeInfoUsage;
688
+ version?: string;
689
+ }
690
+ export const NodeInfo = /*@__PURE__*/ S.suspend(() =>
691
+ S.Struct({
692
+ metadata: S.optional(S.Unknown),
693
+ openRegistrations: S.optional(S.Boolean),
694
+ protocols: S.optional(NodeInfoProtocolsList),
695
+ services: S.optional(NodeInfoServices),
696
+ software: S.optional(NodeInfoSoftware),
697
+ usage: S.optional(NodeInfoUsage),
698
+ version: S.optional(S.String),
699
+ }),
700
+ ).annotate({ identifier: "NodeInfo" }) as any as S.Schema<NodeInfo>;
701
+
702
+ export interface GetSigningKeyRequest {}
703
+ export const GetSigningKeyRequest = /*@__PURE__*/ S.suspend(() =>
704
+ S.Struct({}).pipe(
705
+ T.Http({ method: "GET", uri: "/signing-key.gpg", code: 200 }),
706
+ ),
707
+ ).annotate({
708
+ identifier: "GetSigningKeyRequest",
709
+ }) as any as S.Schema<GetSigningKeyRequest>;
710
+
711
+ export type GetSigningKeyResponse = string;
712
+ export const GetSigningKeyResponse = /*@__PURE__*/ S.suspend(() =>
713
+ S.String.pipe(T.RawResponseRoot()),
714
+ ).annotate({
715
+ identifier: "GetSigningKeyResponse",
716
+ }) as any as S.Schema<GetSigningKeyResponse>;
717
+
718
+ export interface GetSSHSigningKeyRequest {}
719
+ export const GetSSHSigningKeyRequest = /*@__PURE__*/ S.suspend(() =>
720
+ S.Struct({}).pipe(
721
+ T.Http({ method: "GET", uri: "/signing-key.ssh", code: 200 }),
722
+ ),
723
+ ).annotate({
724
+ identifier: "GetSSHSigningKeyRequest",
725
+ }) as any as S.Schema<GetSSHSigningKeyRequest>;
726
+
727
+ export type GetSSHSigningKeyResponse = string;
728
+ export const GetSSHSigningKeyResponse = /*@__PURE__*/ S.suspend(() =>
729
+ S.String.pipe(T.RawResponseRoot()),
730
+ ).annotate({
731
+ identifier: "GetSSHSigningKeyResponse",
732
+ }) as any as S.Schema<GetSSHSigningKeyResponse>;
733
+
734
+ export interface GetVersionRequest {}
735
+ export const GetVersionRequest = /*@__PURE__*/ S.suspend(() =>
736
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/version", code: 200 })),
737
+ ).annotate({
738
+ identifier: "GetVersionRequest",
739
+ }) as any as S.Schema<GetVersionRequest>;
740
+
741
+ /** ServerVersion wraps the version of the server */
742
+ export interface ServerVersion {
743
+ version?: string;
744
+ }
745
+ export const ServerVersion = /*@__PURE__*/ S.suspend(() =>
746
+ S.Struct({
747
+ version: S.optional(S.String),
748
+ }),
749
+ ).annotate({ identifier: "ServerVersion" }) as any as S.Schema<ServerVersion>;
750
+
751
+ export interface ListGitignoresTemplatesRequest {}
752
+ export const ListGitignoresTemplatesRequest = /*@__PURE__*/ S.suspend(() =>
753
+ S.Struct({}).pipe(
754
+ T.Http({ method: "GET", uri: "/gitignore/templates", code: 200 }),
755
+ ),
756
+ ).annotate({
757
+ identifier: "ListGitignoresTemplatesRequest",
758
+ }) as any as S.Schema<ListGitignoresTemplatesRequest>;
759
+
760
+ export type ListGitignoresTemplatesResponseBodyList = Array<string>;
761
+ export const ListGitignoresTemplatesResponseBodyList = /*@__PURE__*/ S.Array(
762
+ S.String,
763
+ ) as any as S.Schema<ListGitignoresTemplatesResponseBodyList>;
764
+
765
+ export type ListGitignoresTemplatesResponse =
766
+ ListGitignoresTemplatesResponseBodyList;
767
+ export const ListGitignoresTemplatesResponse = /*@__PURE__*/ S.suspend(() =>
768
+ ListGitignoresTemplatesResponseBodyList.pipe(T.RawResponseRoot()),
769
+ ).annotate({
770
+ identifier: "ListGitignoresTemplatesResponse",
771
+ }) as any as S.Schema<ListGitignoresTemplatesResponse>;
772
+
773
+ export interface ListLabelTemplatesRequest {}
774
+ export const ListLabelTemplatesRequest = /*@__PURE__*/ S.suspend(() =>
775
+ S.Struct({}).pipe(
776
+ T.Http({ method: "GET", uri: "/label/templates", code: 200 }),
777
+ ),
778
+ ).annotate({
779
+ identifier: "ListLabelTemplatesRequest",
780
+ }) as any as S.Schema<ListLabelTemplatesRequest>;
781
+
782
+ export type ListLabelTemplatesResponseBodyList = Array<string>;
783
+ export const ListLabelTemplatesResponseBodyList = /*@__PURE__*/ S.Array(
784
+ S.String,
785
+ ) as any as S.Schema<ListLabelTemplatesResponseBodyList>;
786
+
787
+ export type ListLabelTemplatesResponse = ListLabelTemplatesResponseBodyList;
788
+ export const ListLabelTemplatesResponse = /*@__PURE__*/ S.suspend(() =>
789
+ ListLabelTemplatesResponseBodyList.pipe(T.RawResponseRoot()),
790
+ ).annotate({
791
+ identifier: "ListLabelTemplatesResponse",
792
+ }) as any as S.Schema<ListLabelTemplatesResponse>;
793
+
794
+ export interface ListLicenseTemplatesRequest {}
795
+ export const ListLicenseTemplatesRequest = /*@__PURE__*/ S.suspend(() =>
796
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/licenses", code: 200 })),
797
+ ).annotate({
798
+ identifier: "ListLicenseTemplatesRequest",
799
+ }) as any as S.Schema<ListLicenseTemplatesRequest>;
800
+
801
+ /** LicensesListEntry is used for the API */
802
+ export interface LicensesTemplateListEntry {
803
+ key?: string;
804
+ name?: string;
805
+ url?: string;
806
+ }
807
+ export const LicensesTemplateListEntry = /*@__PURE__*/ S.suspend(() =>
808
+ S.Struct({
809
+ key: S.optional(S.String),
810
+ name: S.optional(S.String),
811
+ url: S.optional(S.String),
812
+ }),
813
+ ).annotate({
814
+ identifier: "LicensesTemplateListEntry",
815
+ }) as any as S.Schema<LicensesTemplateListEntry>;
816
+
817
+ export type ListLicenseTemplatesResponseBodyList =
818
+ Array<LicensesTemplateListEntry>;
819
+ export const ListLicenseTemplatesResponseBodyList = /*@__PURE__*/ S.Array(
820
+ LicensesTemplateListEntry,
821
+ ) as any as S.Schema<ListLicenseTemplatesResponseBodyList>;
822
+
823
+ export type ListLicenseTemplatesResponse = ListLicenseTemplatesResponseBodyList;
824
+ export const ListLicenseTemplatesResponse = /*@__PURE__*/ S.suspend(() =>
825
+ ListLicenseTemplatesResponseBodyList.pipe(T.RawResponseRoot()),
826
+ ).annotate({
827
+ identifier: "ListLicenseTemplatesResponse",
828
+ }) as any as S.Schema<ListLicenseTemplatesResponse>;
829
+
830
+ export interface RenderMarkdownRequest {
831
+ /** Context to render */
832
+ Context?: string;
833
+ /** Mode to render (comment, gfm, markdown) */
834
+ Mode?: string;
835
+ /** Text markdown to render */
836
+ Text?: string;
837
+ /** Is it a wiki page ? */
838
+ Wiki?: boolean;
839
+ }
840
+ export const RenderMarkdownRequest = /*@__PURE__*/ S.suspend(() =>
841
+ S.Struct({
842
+ Context: S.optional(S.String),
843
+ Mode: S.optional(S.String),
844
+ Text: S.optional(S.String),
845
+ Wiki: S.optional(S.Boolean),
846
+ }).pipe(T.Http({ method: "POST", uri: "/markdown", code: 200 })),
847
+ ).annotate({
848
+ identifier: "RenderMarkdownRequest",
849
+ }) as any as S.Schema<RenderMarkdownRequest>;
850
+
851
+ export type RenderMarkdownResponse = string;
852
+ export const RenderMarkdownResponse = /*@__PURE__*/ S.suspend(() =>
853
+ S.String.pipe(T.RawResponseRoot()),
854
+ ).annotate({
855
+ identifier: "RenderMarkdownResponse",
856
+ }) as any as S.Schema<RenderMarkdownResponse>;
857
+
858
+ export interface RenderMarkdownRawRequest {
859
+ body: string;
860
+ }
861
+ export const RenderMarkdownRawRequest = /*@__PURE__*/ S.suspend(() =>
862
+ S.Struct({
863
+ body: S.String.pipe(T.HttpBody()),
864
+ }).pipe(T.Http({ method: "POST", uri: "/markdown/raw", code: 200 })),
865
+ ).annotate({
866
+ identifier: "RenderMarkdownRawRequest",
867
+ }) as any as S.Schema<RenderMarkdownRawRequest>;
868
+
869
+ export type RenderMarkdownRawResponse = string;
870
+ export const RenderMarkdownRawResponse = /*@__PURE__*/ S.suspend(() =>
871
+ S.String.pipe(T.RawResponseRoot()),
872
+ ).annotate({
873
+ identifier: "RenderMarkdownRawResponse",
874
+ }) as any as S.Schema<RenderMarkdownRawResponse>;
875
+
876
+ export interface RenderMarkupRequest {
877
+ /** The current branch path where the form gets posted */
878
+ BranchPath?: string;
879
+ /** Context to render */
880
+ Context?: string;
881
+ /** File path for detecting extension in file mode */
882
+ FilePath?: string;
883
+ /** Mode to render (comment, gfm, markdown, file) */
884
+ Mode?: string;
885
+ /** Text markup to render */
886
+ Text?: string;
887
+ /** Is it a wiki page ? */
888
+ Wiki?: boolean;
889
+ }
890
+ export const RenderMarkupRequest = /*@__PURE__*/ S.suspend(() =>
891
+ S.Struct({
892
+ BranchPath: S.optional(S.String),
893
+ Context: S.optional(S.String),
894
+ FilePath: S.optional(S.String),
895
+ Mode: S.optional(S.String),
896
+ Text: S.optional(S.String),
897
+ Wiki: S.optional(S.Boolean),
898
+ }).pipe(T.Http({ method: "POST", uri: "/markup", code: 200 })),
899
+ ).annotate({
900
+ identifier: "RenderMarkupRequest",
901
+ }) as any as S.Schema<RenderMarkupRequest>;
902
+
903
+ export type RenderMarkupResponse = string;
904
+ export const RenderMarkupResponse = /*@__PURE__*/ S.suspend(() =>
905
+ S.String.pipe(T.RawResponseRoot()),
906
+ ).annotate({
907
+ identifier: "RenderMarkupResponse",
908
+ }) as any as S.Schema<RenderMarkupResponse>;
909
+
910
+ export type GetActionsRunError = ForgejoOpError;
911
+ /** Get a workflow run associated with a token The automatic actions token must be used as the authentication mechanism (<code>Authorization: Bearer $&#x7b;&#x7b; forgejo.token &#x7d;&#x7d;</code>); other types of tokens cannot be used. The token is associated with the job, which must be still running for the request to this endpoint to succeed. */
912
+ export const getActionsRun: API.OperationMethod<
913
+ GetActionsRunRequest,
914
+ ActionRun,
915
+ GetActionsRunError,
916
+ ForgejoOpContext
917
+ > = /*@__PURE__*/ API.make(() => ({
918
+ input: GetActionsRunRequest,
919
+ output: ActionRun,
920
+ errors: [],
921
+ protocol: ForgejoProtocol,
922
+ retry: Retry.Retry,
923
+ }));
924
+
925
+ export type GetGitignoreTemplateInfoError = NotFound | ForgejoOpError;
926
+ /** Returns information about a gitignore template */
927
+ export const getGitignoreTemplateInfo: API.OperationMethod<
928
+ GetGitignoreTemplateInfoRequest,
929
+ GitignoreTemplateInfo,
930
+ GetGitignoreTemplateInfoError,
931
+ ForgejoOpContext
932
+ > = /*@__PURE__*/ API.make(() => ({
933
+ input: GetGitignoreTemplateInfoRequest,
934
+ output: GitignoreTemplateInfo,
935
+ errors: [NotFound],
936
+ protocol: ForgejoProtocol,
937
+ retry: Retry.Retry,
938
+ }));
939
+
940
+ export type GetLabelTemplateInfoError = NotFound | ForgejoOpError;
941
+ /** Returns all labels in a template */
942
+ export const getLabelTemplateInfo: API.OperationMethod<
943
+ GetLabelTemplateInfoRequest,
944
+ GetLabelTemplateInfoResponse,
945
+ GetLabelTemplateInfoError,
946
+ ForgejoOpContext
947
+ > = /*@__PURE__*/ API.make(() => ({
948
+ input: GetLabelTemplateInfoRequest,
949
+ output: GetLabelTemplateInfoResponse,
950
+ errors: [NotFound],
951
+ protocol: ForgejoProtocol,
952
+ retry: Retry.Retry,
953
+ }));
954
+
955
+ export type GetLicenseTemplateInfoError = NotFound | ForgejoOpError;
956
+ /** Returns information about a license template */
957
+ export const getLicenseTemplateInfo: API.OperationMethod<
958
+ GetLicenseTemplateInfoRequest,
959
+ LicenseTemplateInfo,
960
+ GetLicenseTemplateInfoError,
961
+ ForgejoOpContext
962
+ > = /*@__PURE__*/ API.make(() => ({
963
+ input: GetLicenseTemplateInfoRequest,
964
+ output: LicenseTemplateInfo,
965
+ errors: [NotFound],
966
+ protocol: ForgejoProtocol,
967
+ retry: Retry.Retry,
968
+ }));
969
+
970
+ export type GetNodeInfoError = ForgejoOpError;
971
+ /** Returns the nodeinfo of the Forgejo application */
972
+ export const getNodeInfo: API.OperationMethod<
973
+ GetNodeInfoRequest,
974
+ NodeInfo,
975
+ GetNodeInfoError,
976
+ ForgejoOpContext
977
+ > = /*@__PURE__*/ API.make(() => ({
978
+ input: GetNodeInfoRequest,
979
+ output: NodeInfo,
980
+ errors: [],
981
+ protocol: ForgejoProtocol,
982
+ retry: Retry.Retry,
983
+ }));
984
+
985
+ export type GetSigningKeyError = ForgejoOpError;
986
+ /** Get default signing-key.gpg */
987
+ export const getSigningKey: API.OperationMethod<
988
+ GetSigningKeyRequest,
989
+ GetSigningKeyResponse,
990
+ GetSigningKeyError,
991
+ ForgejoOpContext
992
+ > = /*@__PURE__*/ API.make(() => ({
993
+ input: GetSigningKeyRequest,
994
+ output: GetSigningKeyResponse,
995
+ errors: [],
996
+ protocol: ForgejoProtocol,
997
+ retry: Retry.Retry,
998
+ }));
999
+
1000
+ export type GetSSHSigningKeyError = NotFound | ForgejoOpError;
1001
+ /** Get default signing-key.ssh */
1002
+ export const getSSHSigningKey: API.OperationMethod<
1003
+ GetSSHSigningKeyRequest,
1004
+ GetSSHSigningKeyResponse,
1005
+ GetSSHSigningKeyError,
1006
+ ForgejoOpContext
1007
+ > = /*@__PURE__*/ API.make(() => ({
1008
+ input: GetSSHSigningKeyRequest,
1009
+ output: GetSSHSigningKeyResponse,
1010
+ errors: [NotFound],
1011
+ protocol: ForgejoProtocol,
1012
+ retry: Retry.Retry,
1013
+ }));
1014
+
1015
+ export type GetVersionError = ForgejoOpError;
1016
+ /** Returns the version of the running application */
1017
+ export const getVersion: API.OperationMethod<
1018
+ GetVersionRequest,
1019
+ ServerVersion,
1020
+ GetVersionError,
1021
+ ForgejoOpContext
1022
+ > = /*@__PURE__*/ API.make(() => ({
1023
+ input: GetVersionRequest,
1024
+ output: ServerVersion,
1025
+ errors: [],
1026
+ protocol: ForgejoProtocol,
1027
+ retry: Retry.Retry,
1028
+ }));
1029
+
1030
+ export type ListGitignoresTemplatesError = ForgejoOpError;
1031
+ /** Returns a list of all gitignore templates */
1032
+ export const listGitignoresTemplates: API.OperationMethod<
1033
+ ListGitignoresTemplatesRequest,
1034
+ ListGitignoresTemplatesResponse,
1035
+ ListGitignoresTemplatesError,
1036
+ ForgejoOpContext
1037
+ > = /*@__PURE__*/ API.make(() => ({
1038
+ input: ListGitignoresTemplatesRequest,
1039
+ output: ListGitignoresTemplatesResponse,
1040
+ errors: [],
1041
+ protocol: ForgejoProtocol,
1042
+ retry: Retry.Retry,
1043
+ }));
1044
+
1045
+ export type ListLabelTemplatesError = ForgejoOpError;
1046
+ /** Returns a list of all label templates */
1047
+ export const listLabelTemplates: API.OperationMethod<
1048
+ ListLabelTemplatesRequest,
1049
+ ListLabelTemplatesResponse,
1050
+ ListLabelTemplatesError,
1051
+ ForgejoOpContext
1052
+ > = /*@__PURE__*/ API.make(() => ({
1053
+ input: ListLabelTemplatesRequest,
1054
+ output: ListLabelTemplatesResponse,
1055
+ errors: [],
1056
+ protocol: ForgejoProtocol,
1057
+ retry: Retry.Retry,
1058
+ }));
1059
+
1060
+ export type ListLicenseTemplatesError = ForgejoOpError;
1061
+ /** Returns a list of all license templates */
1062
+ export const listLicenseTemplates: API.OperationMethod<
1063
+ ListLicenseTemplatesRequest,
1064
+ ListLicenseTemplatesResponse,
1065
+ ListLicenseTemplatesError,
1066
+ ForgejoOpContext
1067
+ > = /*@__PURE__*/ API.make(() => ({
1068
+ input: ListLicenseTemplatesRequest,
1069
+ output: ListLicenseTemplatesResponse,
1070
+ errors: [],
1071
+ protocol: ForgejoProtocol,
1072
+ retry: Retry.Retry,
1073
+ }));
1074
+
1075
+ export type RenderMarkdownError = UnprocessableEntity | ForgejoOpError;
1076
+ /** Render a markdown document as HTML */
1077
+ export const renderMarkdown: API.OperationMethod<
1078
+ RenderMarkdownRequest,
1079
+ RenderMarkdownResponse,
1080
+ RenderMarkdownError,
1081
+ ForgejoOpContext
1082
+ > = /*@__PURE__*/ API.make(() => ({
1083
+ input: RenderMarkdownRequest,
1084
+ output: RenderMarkdownResponse,
1085
+ errors: [UnprocessableEntity],
1086
+ protocol: ForgejoProtocol,
1087
+ retry: Retry.Retry,
1088
+ }));
1089
+
1090
+ export type RenderMarkdownRawError = UnprocessableEntity | ForgejoOpError;
1091
+ /** Render raw markdown as HTML */
1092
+ export const renderMarkdownRaw: API.OperationMethod<
1093
+ RenderMarkdownRawRequest,
1094
+ RenderMarkdownRawResponse,
1095
+ RenderMarkdownRawError,
1096
+ ForgejoOpContext
1097
+ > = /*@__PURE__*/ API.make(() => ({
1098
+ input: RenderMarkdownRawRequest,
1099
+ output: RenderMarkdownRawResponse,
1100
+ errors: [UnprocessableEntity],
1101
+ protocol: ForgejoProtocol,
1102
+ retry: Retry.Retry,
1103
+ }));
1104
+
1105
+ export type RenderMarkupError = UnprocessableEntity | ForgejoOpError;
1106
+ /** Render a markup document as HTML */
1107
+ export const renderMarkup: API.OperationMethod<
1108
+ RenderMarkupRequest,
1109
+ RenderMarkupResponse,
1110
+ RenderMarkupError,
1111
+ ForgejoOpContext
1112
+ > = /*@__PURE__*/ API.make(() => ({
1113
+ input: RenderMarkupRequest,
1114
+ output: RenderMarkupResponse,
1115
+ errors: [UnprocessableEntity],
1116
+ protocol: ForgejoProtocol,
1117
+ retry: Retry.Retry,
1118
+ }));