Go · 30049 bytes Raw Blame History
1 // Code generated by sqlc. DO NOT EDIT.
2 // versions:
3 // sqlc v1.31.1
4
5 package metadb
6
7 import (
8 "database/sql/driver"
9 "fmt"
10 "net/netip"
11
12 "github.com/jackc/pgx/v5/pgtype"
13 )
14
15 type CheckConclusion string
16
17 const (
18 CheckConclusionSuccess CheckConclusion = "success"
19 CheckConclusionFailure CheckConclusion = "failure"
20 CheckConclusionNeutral CheckConclusion = "neutral"
21 CheckConclusionCancelled CheckConclusion = "cancelled"
22 CheckConclusionSkipped CheckConclusion = "skipped"
23 CheckConclusionTimedOut CheckConclusion = "timed_out"
24 CheckConclusionActionRequired CheckConclusion = "action_required"
25 CheckConclusionStale CheckConclusion = "stale"
26 )
27
28 func (e *CheckConclusion) Scan(src interface{}) error {
29 switch s := src.(type) {
30 case []byte:
31 *e = CheckConclusion(s)
32 case string:
33 *e = CheckConclusion(s)
34 default:
35 return fmt.Errorf("unsupported scan type for CheckConclusion: %T", src)
36 }
37 return nil
38 }
39
40 type NullCheckConclusion struct {
41 CheckConclusion CheckConclusion
42 Valid bool // Valid is true if CheckConclusion is not NULL
43 }
44
45 // Scan implements the Scanner interface.
46 func (ns *NullCheckConclusion) Scan(value interface{}) error {
47 if value == nil {
48 ns.CheckConclusion, ns.Valid = "", false
49 return nil
50 }
51 ns.Valid = true
52 return ns.CheckConclusion.Scan(value)
53 }
54
55 // Value implements the driver Valuer interface.
56 func (ns NullCheckConclusion) Value() (driver.Value, error) {
57 if !ns.Valid {
58 return nil, nil
59 }
60 return string(ns.CheckConclusion), nil
61 }
62
63 type CheckStatus string
64
65 const (
66 CheckStatusQueued CheckStatus = "queued"
67 CheckStatusInProgress CheckStatus = "in_progress"
68 CheckStatusCompleted CheckStatus = "completed"
69 CheckStatusPending CheckStatus = "pending"
70 )
71
72 func (e *CheckStatus) Scan(src interface{}) error {
73 switch s := src.(type) {
74 case []byte:
75 *e = CheckStatus(s)
76 case string:
77 *e = CheckStatus(s)
78 default:
79 return fmt.Errorf("unsupported scan type for CheckStatus: %T", src)
80 }
81 return nil
82 }
83
84 type NullCheckStatus struct {
85 CheckStatus CheckStatus
86 Valid bool // Valid is true if CheckStatus is not NULL
87 }
88
89 // Scan implements the Scanner interface.
90 func (ns *NullCheckStatus) Scan(value interface{}) error {
91 if value == nil {
92 ns.CheckStatus, ns.Valid = "", false
93 return nil
94 }
95 ns.Valid = true
96 return ns.CheckStatus.Scan(value)
97 }
98
99 // Value implements the driver Valuer interface.
100 func (ns NullCheckStatus) Value() (driver.Value, error) {
101 if !ns.Valid {
102 return nil, nil
103 }
104 return string(ns.CheckStatus), nil
105 }
106
107 type CollabRole string
108
109 const (
110 CollabRoleRead CollabRole = "read"
111 CollabRoleTriage CollabRole = "triage"
112 CollabRoleWrite CollabRole = "write"
113 CollabRoleMaintain CollabRole = "maintain"
114 CollabRoleAdmin CollabRole = "admin"
115 )
116
117 func (e *CollabRole) Scan(src interface{}) error {
118 switch s := src.(type) {
119 case []byte:
120 *e = CollabRole(s)
121 case string:
122 *e = CollabRole(s)
123 default:
124 return fmt.Errorf("unsupported scan type for CollabRole: %T", src)
125 }
126 return nil
127 }
128
129 type NullCollabRole struct {
130 CollabRole CollabRole
131 Valid bool // Valid is true if CollabRole is not NULL
132 }
133
134 // Scan implements the Scanner interface.
135 func (ns *NullCollabRole) Scan(value interface{}) error {
136 if value == nil {
137 ns.CollabRole, ns.Valid = "", false
138 return nil
139 }
140 ns.Valid = true
141 return ns.CollabRole.Scan(value)
142 }
143
144 // Value implements the driver Valuer interface.
145 func (ns NullCollabRole) Value() (driver.Value, error) {
146 if !ns.Valid {
147 return nil, nil
148 }
149 return string(ns.CollabRole), nil
150 }
151
152 type IssueKind string
153
154 const (
155 IssueKindIssue IssueKind = "issue"
156 IssueKindPr IssueKind = "pr"
157 )
158
159 func (e *IssueKind) Scan(src interface{}) error {
160 switch s := src.(type) {
161 case []byte:
162 *e = IssueKind(s)
163 case string:
164 *e = IssueKind(s)
165 default:
166 return fmt.Errorf("unsupported scan type for IssueKind: %T", src)
167 }
168 return nil
169 }
170
171 type NullIssueKind struct {
172 IssueKind IssueKind
173 Valid bool // Valid is true if IssueKind is not NULL
174 }
175
176 // Scan implements the Scanner interface.
177 func (ns *NullIssueKind) Scan(value interface{}) error {
178 if value == nil {
179 ns.IssueKind, ns.Valid = "", false
180 return nil
181 }
182 ns.Valid = true
183 return ns.IssueKind.Scan(value)
184 }
185
186 // Value implements the driver Valuer interface.
187 func (ns NullIssueKind) Value() (driver.Value, error) {
188 if !ns.Valid {
189 return nil, nil
190 }
191 return string(ns.IssueKind), nil
192 }
193
194 type IssueRefSource string
195
196 const (
197 IssueRefSourceCommentBody IssueRefSource = "comment_body"
198 IssueRefSourceIssueBody IssueRefSource = "issue_body"
199 IssueRefSourceCommitMessage IssueRefSource = "commit_message"
200 )
201
202 func (e *IssueRefSource) Scan(src interface{}) error {
203 switch s := src.(type) {
204 case []byte:
205 *e = IssueRefSource(s)
206 case string:
207 *e = IssueRefSource(s)
208 default:
209 return fmt.Errorf("unsupported scan type for IssueRefSource: %T", src)
210 }
211 return nil
212 }
213
214 type NullIssueRefSource struct {
215 IssueRefSource IssueRefSource
216 Valid bool // Valid is true if IssueRefSource is not NULL
217 }
218
219 // Scan implements the Scanner interface.
220 func (ns *NullIssueRefSource) Scan(value interface{}) error {
221 if value == nil {
222 ns.IssueRefSource, ns.Valid = "", false
223 return nil
224 }
225 ns.Valid = true
226 return ns.IssueRefSource.Scan(value)
227 }
228
229 // Value implements the driver Valuer interface.
230 func (ns NullIssueRefSource) Value() (driver.Value, error) {
231 if !ns.Valid {
232 return nil, nil
233 }
234 return string(ns.IssueRefSource), nil
235 }
236
237 type IssueState string
238
239 const (
240 IssueStateOpen IssueState = "open"
241 IssueStateClosed IssueState = "closed"
242 )
243
244 func (e *IssueState) Scan(src interface{}) error {
245 switch s := src.(type) {
246 case []byte:
247 *e = IssueState(s)
248 case string:
249 *e = IssueState(s)
250 default:
251 return fmt.Errorf("unsupported scan type for IssueState: %T", src)
252 }
253 return nil
254 }
255
256 type NullIssueState struct {
257 IssueState IssueState
258 Valid bool // Valid is true if IssueState is not NULL
259 }
260
261 // Scan implements the Scanner interface.
262 func (ns *NullIssueState) Scan(value interface{}) error {
263 if value == nil {
264 ns.IssueState, ns.Valid = "", false
265 return nil
266 }
267 ns.Valid = true
268 return ns.IssueState.Scan(value)
269 }
270
271 // Value implements the driver Valuer interface.
272 func (ns NullIssueState) Value() (driver.Value, error) {
273 if !ns.Valid {
274 return nil, nil
275 }
276 return string(ns.IssueState), nil
277 }
278
279 type IssueStateReason string
280
281 const (
282 IssueStateReasonCompleted IssueStateReason = "completed"
283 IssueStateReasonNotPlanned IssueStateReason = "not_planned"
284 IssueStateReasonReopened IssueStateReason = "reopened"
285 IssueStateReasonDuplicate IssueStateReason = "duplicate"
286 )
287
288 func (e *IssueStateReason) Scan(src interface{}) error {
289 switch s := src.(type) {
290 case []byte:
291 *e = IssueStateReason(s)
292 case string:
293 *e = IssueStateReason(s)
294 default:
295 return fmt.Errorf("unsupported scan type for IssueStateReason: %T", src)
296 }
297 return nil
298 }
299
300 type NullIssueStateReason struct {
301 IssueStateReason IssueStateReason
302 Valid bool // Valid is true if IssueStateReason is not NULL
303 }
304
305 // Scan implements the Scanner interface.
306 func (ns *NullIssueStateReason) Scan(value interface{}) error {
307 if value == nil {
308 ns.IssueStateReason, ns.Valid = "", false
309 return nil
310 }
311 ns.Valid = true
312 return ns.IssueStateReason.Scan(value)
313 }
314
315 // Value implements the driver Valuer interface.
316 func (ns NullIssueStateReason) Value() (driver.Value, error) {
317 if !ns.Valid {
318 return nil, nil
319 }
320 return string(ns.IssueStateReason), nil
321 }
322
323 type MilestoneState string
324
325 const (
326 MilestoneStateOpen MilestoneState = "open"
327 MilestoneStateClosed MilestoneState = "closed"
328 )
329
330 func (e *MilestoneState) Scan(src interface{}) error {
331 switch s := src.(type) {
332 case []byte:
333 *e = MilestoneState(s)
334 case string:
335 *e = MilestoneState(s)
336 default:
337 return fmt.Errorf("unsupported scan type for MilestoneState: %T", src)
338 }
339 return nil
340 }
341
342 type NullMilestoneState struct {
343 MilestoneState MilestoneState
344 Valid bool // Valid is true if MilestoneState is not NULL
345 }
346
347 // Scan implements the Scanner interface.
348 func (ns *NullMilestoneState) Scan(value interface{}) error {
349 if value == nil {
350 ns.MilestoneState, ns.Valid = "", false
351 return nil
352 }
353 ns.Valid = true
354 return ns.MilestoneState.Scan(value)
355 }
356
357 // Value implements the driver Valuer interface.
358 func (ns NullMilestoneState) Value() (driver.Value, error) {
359 if !ns.Valid {
360 return nil, nil
361 }
362 return string(ns.MilestoneState), nil
363 }
364
365 type PrFileStatus string
366
367 const (
368 PrFileStatusAdded PrFileStatus = "added"
369 PrFileStatusModified PrFileStatus = "modified"
370 PrFileStatusDeleted PrFileStatus = "deleted"
371 PrFileStatusRenamed PrFileStatus = "renamed"
372 PrFileStatusCopied PrFileStatus = "copied"
373 )
374
375 func (e *PrFileStatus) Scan(src interface{}) error {
376 switch s := src.(type) {
377 case []byte:
378 *e = PrFileStatus(s)
379 case string:
380 *e = PrFileStatus(s)
381 default:
382 return fmt.Errorf("unsupported scan type for PrFileStatus: %T", src)
383 }
384 return nil
385 }
386
387 type NullPrFileStatus struct {
388 PrFileStatus PrFileStatus
389 Valid bool // Valid is true if PrFileStatus is not NULL
390 }
391
392 // Scan implements the Scanner interface.
393 func (ns *NullPrFileStatus) Scan(value interface{}) error {
394 if value == nil {
395 ns.PrFileStatus, ns.Valid = "", false
396 return nil
397 }
398 ns.Valid = true
399 return ns.PrFileStatus.Scan(value)
400 }
401
402 // Value implements the driver Valuer interface.
403 func (ns NullPrFileStatus) Value() (driver.Value, error) {
404 if !ns.Valid {
405 return nil, nil
406 }
407 return string(ns.PrFileStatus), nil
408 }
409
410 type PrMergeMethod string
411
412 const (
413 PrMergeMethodMerge PrMergeMethod = "merge"
414 PrMergeMethodSquash PrMergeMethod = "squash"
415 PrMergeMethodRebase PrMergeMethod = "rebase"
416 )
417
418 func (e *PrMergeMethod) Scan(src interface{}) error {
419 switch s := src.(type) {
420 case []byte:
421 *e = PrMergeMethod(s)
422 case string:
423 *e = PrMergeMethod(s)
424 default:
425 return fmt.Errorf("unsupported scan type for PrMergeMethod: %T", src)
426 }
427 return nil
428 }
429
430 type NullPrMergeMethod struct {
431 PrMergeMethod PrMergeMethod
432 Valid bool // Valid is true if PrMergeMethod is not NULL
433 }
434
435 // Scan implements the Scanner interface.
436 func (ns *NullPrMergeMethod) Scan(value interface{}) error {
437 if value == nil {
438 ns.PrMergeMethod, ns.Valid = "", false
439 return nil
440 }
441 ns.Valid = true
442 return ns.PrMergeMethod.Scan(value)
443 }
444
445 // Value implements the driver Valuer interface.
446 func (ns NullPrMergeMethod) Value() (driver.Value, error) {
447 if !ns.Valid {
448 return nil, nil
449 }
450 return string(ns.PrMergeMethod), nil
451 }
452
453 type PrMergeableState string
454
455 const (
456 PrMergeableStateUnknown PrMergeableState = "unknown"
457 PrMergeableStateClean PrMergeableState = "clean"
458 PrMergeableStateDirty PrMergeableState = "dirty"
459 PrMergeableStateBlocked PrMergeableState = "blocked"
460 PrMergeableStateBehind PrMergeableState = "behind"
461 )
462
463 func (e *PrMergeableState) Scan(src interface{}) error {
464 switch s := src.(type) {
465 case []byte:
466 *e = PrMergeableState(s)
467 case string:
468 *e = PrMergeableState(s)
469 default:
470 return fmt.Errorf("unsupported scan type for PrMergeableState: %T", src)
471 }
472 return nil
473 }
474
475 type NullPrMergeableState struct {
476 PrMergeableState PrMergeableState
477 Valid bool // Valid is true if PrMergeableState is not NULL
478 }
479
480 // Scan implements the Scanner interface.
481 func (ns *NullPrMergeableState) Scan(value interface{}) error {
482 if value == nil {
483 ns.PrMergeableState, ns.Valid = "", false
484 return nil
485 }
486 ns.Valid = true
487 return ns.PrMergeableState.Scan(value)
488 }
489
490 // Value implements the driver Valuer interface.
491 func (ns NullPrMergeableState) Value() (driver.Value, error) {
492 if !ns.Valid {
493 return nil, nil
494 }
495 return string(ns.PrMergeableState), nil
496 }
497
498 type PrReviewSide string
499
500 const (
501 PrReviewSideLeft PrReviewSide = "left"
502 PrReviewSideRight PrReviewSide = "right"
503 )
504
505 func (e *PrReviewSide) Scan(src interface{}) error {
506 switch s := src.(type) {
507 case []byte:
508 *e = PrReviewSide(s)
509 case string:
510 *e = PrReviewSide(s)
511 default:
512 return fmt.Errorf("unsupported scan type for PrReviewSide: %T", src)
513 }
514 return nil
515 }
516
517 type NullPrReviewSide struct {
518 PrReviewSide PrReviewSide
519 Valid bool // Valid is true if PrReviewSide is not NULL
520 }
521
522 // Scan implements the Scanner interface.
523 func (ns *NullPrReviewSide) Scan(value interface{}) error {
524 if value == nil {
525 ns.PrReviewSide, ns.Valid = "", false
526 return nil
527 }
528 ns.Valid = true
529 return ns.PrReviewSide.Scan(value)
530 }
531
532 // Value implements the driver Valuer interface.
533 func (ns NullPrReviewSide) Value() (driver.Value, error) {
534 if !ns.Valid {
535 return nil, nil
536 }
537 return string(ns.PrReviewSide), nil
538 }
539
540 type PrReviewState string
541
542 const (
543 PrReviewStateComment PrReviewState = "comment"
544 PrReviewStateApprove PrReviewState = "approve"
545 PrReviewStateRequestChanges PrReviewState = "request_changes"
546 )
547
548 func (e *PrReviewState) Scan(src interface{}) error {
549 switch s := src.(type) {
550 case []byte:
551 *e = PrReviewState(s)
552 case string:
553 *e = PrReviewState(s)
554 default:
555 return fmt.Errorf("unsupported scan type for PrReviewState: %T", src)
556 }
557 return nil
558 }
559
560 type NullPrReviewState struct {
561 PrReviewState PrReviewState
562 Valid bool // Valid is true if PrReviewState is not NULL
563 }
564
565 // Scan implements the Scanner interface.
566 func (ns *NullPrReviewState) Scan(value interface{}) error {
567 if value == nil {
568 ns.PrReviewState, ns.Valid = "", false
569 return nil
570 }
571 ns.Valid = true
572 return ns.PrReviewState.Scan(value)
573 }
574
575 // Value implements the driver Valuer interface.
576 func (ns NullPrReviewState) Value() (driver.Value, error) {
577 if !ns.Valid {
578 return nil, nil
579 }
580 return string(ns.PrReviewState), nil
581 }
582
583 type RepoInitStatus string
584
585 const (
586 RepoInitStatusInitialized RepoInitStatus = "initialized"
587 RepoInitStatusInitPending RepoInitStatus = "init_pending"
588 RepoInitStatusInitFailed RepoInitStatus = "init_failed"
589 )
590
591 func (e *RepoInitStatus) Scan(src interface{}) error {
592 switch s := src.(type) {
593 case []byte:
594 *e = RepoInitStatus(s)
595 case string:
596 *e = RepoInitStatus(s)
597 default:
598 return fmt.Errorf("unsupported scan type for RepoInitStatus: %T", src)
599 }
600 return nil
601 }
602
603 type NullRepoInitStatus struct {
604 RepoInitStatus RepoInitStatus
605 Valid bool // Valid is true if RepoInitStatus is not NULL
606 }
607
608 // Scan implements the Scanner interface.
609 func (ns *NullRepoInitStatus) Scan(value interface{}) error {
610 if value == nil {
611 ns.RepoInitStatus, ns.Valid = "", false
612 return nil
613 }
614 ns.Valid = true
615 return ns.RepoInitStatus.Scan(value)
616 }
617
618 // Value implements the driver Valuer interface.
619 func (ns NullRepoInitStatus) Value() (driver.Value, error) {
620 if !ns.Valid {
621 return nil, nil
622 }
623 return string(ns.RepoInitStatus), nil
624 }
625
626 type RepoVisibility string
627
628 const (
629 RepoVisibilityPublic RepoVisibility = "public"
630 RepoVisibilityPrivate RepoVisibility = "private"
631 )
632
633 func (e *RepoVisibility) Scan(src interface{}) error {
634 switch s := src.(type) {
635 case []byte:
636 *e = RepoVisibility(s)
637 case string:
638 *e = RepoVisibility(s)
639 default:
640 return fmt.Errorf("unsupported scan type for RepoVisibility: %T", src)
641 }
642 return nil
643 }
644
645 type NullRepoVisibility struct {
646 RepoVisibility RepoVisibility
647 Valid bool // Valid is true if RepoVisibility is not NULL
648 }
649
650 // Scan implements the Scanner interface.
651 func (ns *NullRepoVisibility) Scan(value interface{}) error {
652 if value == nil {
653 ns.RepoVisibility, ns.Valid = "", false
654 return nil
655 }
656 ns.Valid = true
657 return ns.RepoVisibility.Scan(value)
658 }
659
660 // Value implements the driver Valuer interface.
661 func (ns NullRepoVisibility) Value() (driver.Value, error) {
662 if !ns.Valid {
663 return nil, nil
664 }
665 return string(ns.RepoVisibility), nil
666 }
667
668 type TransferPrincipalKind string
669
670 const (
671 TransferPrincipalKindUser TransferPrincipalKind = "user"
672 TransferPrincipalKindOrg TransferPrincipalKind = "org"
673 )
674
675 func (e *TransferPrincipalKind) Scan(src interface{}) error {
676 switch s := src.(type) {
677 case []byte:
678 *e = TransferPrincipalKind(s)
679 case string:
680 *e = TransferPrincipalKind(s)
681 default:
682 return fmt.Errorf("unsupported scan type for TransferPrincipalKind: %T", src)
683 }
684 return nil
685 }
686
687 type NullTransferPrincipalKind struct {
688 TransferPrincipalKind TransferPrincipalKind
689 Valid bool // Valid is true if TransferPrincipalKind is not NULL
690 }
691
692 // Scan implements the Scanner interface.
693 func (ns *NullTransferPrincipalKind) Scan(value interface{}) error {
694 if value == nil {
695 ns.TransferPrincipalKind, ns.Valid = "", false
696 return nil
697 }
698 ns.Valid = true
699 return ns.TransferPrincipalKind.Scan(value)
700 }
701
702 // Value implements the driver Valuer interface.
703 func (ns NullTransferPrincipalKind) Value() (driver.Value, error) {
704 if !ns.Valid {
705 return nil, nil
706 }
707 return string(ns.TransferPrincipalKind), nil
708 }
709
710 type TransferStatus string
711
712 const (
713 TransferStatusPending TransferStatus = "pending"
714 TransferStatusAccepted TransferStatus = "accepted"
715 TransferStatusDeclined TransferStatus = "declined"
716 TransferStatusCanceled TransferStatus = "canceled"
717 TransferStatusExpired TransferStatus = "expired"
718 )
719
720 func (e *TransferStatus) Scan(src interface{}) error {
721 switch s := src.(type) {
722 case []byte:
723 *e = TransferStatus(s)
724 case string:
725 *e = TransferStatus(s)
726 default:
727 return fmt.Errorf("unsupported scan type for TransferStatus: %T", src)
728 }
729 return nil
730 }
731
732 type NullTransferStatus struct {
733 TransferStatus TransferStatus
734 Valid bool // Valid is true if TransferStatus is not NULL
735 }
736
737 // Scan implements the Scanner interface.
738 func (ns *NullTransferStatus) Scan(value interface{}) error {
739 if value == nil {
740 ns.TransferStatus, ns.Valid = "", false
741 return nil
742 }
743 ns.Valid = true
744 return ns.TransferStatus.Scan(value)
745 }
746
747 // Value implements the driver Valuer interface.
748 func (ns NullTransferStatus) Value() (driver.Value, error) {
749 if !ns.Valid {
750 return nil, nil
751 }
752 return string(ns.TransferStatus), nil
753 }
754
755 type WatchLevel string
756
757 const (
758 WatchLevelAll WatchLevel = "all"
759 WatchLevelParticipating WatchLevel = "participating"
760 WatchLevelIgnore WatchLevel = "ignore"
761 )
762
763 func (e *WatchLevel) Scan(src interface{}) error {
764 switch s := src.(type) {
765 case []byte:
766 *e = WatchLevel(s)
767 case string:
768 *e = WatchLevel(s)
769 default:
770 return fmt.Errorf("unsupported scan type for WatchLevel: %T", src)
771 }
772 return nil
773 }
774
775 type NullWatchLevel struct {
776 WatchLevel WatchLevel
777 Valid bool // Valid is true if WatchLevel is not NULL
778 }
779
780 // Scan implements the Scanner interface.
781 func (ns *NullWatchLevel) Scan(value interface{}) error {
782 if value == nil {
783 ns.WatchLevel, ns.Valid = "", false
784 return nil
785 }
786 ns.Valid = true
787 return ns.WatchLevel.Scan(value)
788 }
789
790 // Value implements the driver Valuer interface.
791 func (ns NullWatchLevel) Value() (driver.Value, error) {
792 if !ns.Valid {
793 return nil, nil
794 }
795 return string(ns.WatchLevel), nil
796 }
797
798 type AuthAuditLog struct {
799 ID int64
800 ActorID pgtype.Int8
801 Action string
802 TargetType string
803 TargetID pgtype.Int8
804 Meta []byte
805 CreatedAt pgtype.Timestamptz
806 }
807
808 type AuthThrottle struct {
809 ID int64
810 Scope string
811 Identifier string
812 Hits int32
813 WindowStartedAt pgtype.Timestamptz
814 }
815
816 type BranchProtectionRule struct {
817 ID int64
818 RepoID int64
819 Pattern string
820 PreventForcePush bool
821 PreventDeletion bool
822 RequirePrForPush bool
823 AllowedPusherUserIds []int64
824 RequireSignedCommits bool
825 StatusChecksRequired []string
826 CreatedAt pgtype.Timestamptz
827 UpdatedAt pgtype.Timestamptz
828 CreatedByUserID pgtype.Int8
829 RequiredReviewCount int32
830 DismissStaleReviewsOnPush bool
831 RequireCodeOwnerReview bool
832 DismissStaleStatusChecksOnPush bool
833 }
834
835 type CheckRun struct {
836 ID int64
837 SuiteID int64
838 RepoID int64
839 HeadSha string
840 Name string
841 Status CheckStatus
842 Conclusion NullCheckConclusion
843 StartedAt pgtype.Timestamptz
844 CompletedAt pgtype.Timestamptz
845 DetailsUrl string
846 Output []byte
847 ExternalID pgtype.Text
848 CreatedAt pgtype.Timestamptz
849 UpdatedAt pgtype.Timestamptz
850 }
851
852 type CheckSuite struct {
853 ID int64
854 RepoID int64
855 HeadSha string
856 AppSlug string
857 Status CheckStatus
858 Conclusion NullCheckConclusion
859 CreatedAt pgtype.Timestamptz
860 UpdatedAt pgtype.Timestamptz
861 }
862
863 type DomainEvent struct {
864 ID int64
865 ActorUserID pgtype.Int8
866 Kind string
867 RepoID pgtype.Int8
868 SourceKind string
869 SourceID int64
870 Public bool
871 Payload []byte
872 CreatedAt pgtype.Timestamptz
873 }
874
875 type EmailVerification struct {
876 ID int64
877 UserEmailID int64
878 TokenHash []byte
879 ExpiresAt pgtype.Timestamptz
880 UsedAt pgtype.Timestamptz
881 CreatedAt pgtype.Timestamptz
882 }
883
884 type Issue struct {
885 ID int64
886 RepoID int64
887 Number int64
888 Kind IssueKind
889 Title string
890 Body string
891 BodyHtmlCached pgtype.Text
892 MdPipelineVersion int32
893 AuthorUserID pgtype.Int8
894 State IssueState
895 StateReason NullIssueStateReason
896 Locked bool
897 LockReason pgtype.Text
898 MilestoneID pgtype.Int8
899 CreatedAt pgtype.Timestamptz
900 UpdatedAt pgtype.Timestamptz
901 EditedAt pgtype.Timestamptz
902 ClosedAt pgtype.Timestamptz
903 ClosedByUserID pgtype.Int8
904 }
905
906 type IssueAssignee struct {
907 IssueID int64
908 UserID int64
909 AssignedAt pgtype.Timestamptz
910 AssignedByUserID pgtype.Int8
911 }
912
913 type IssueComment struct {
914 ID int64
915 IssueID int64
916 AuthorUserID pgtype.Int8
917 Body string
918 BodyHtmlCached pgtype.Text
919 MdPipelineVersion int32
920 CreatedAt pgtype.Timestamptz
921 UpdatedAt pgtype.Timestamptz
922 EditedAt pgtype.Timestamptz
923 }
924
925 type IssueEvent struct {
926 ID int64
927 IssueID int64
928 ActorUserID pgtype.Int8
929 Kind string
930 Meta []byte
931 RefTargetID pgtype.Int8
932 CreatedAt pgtype.Timestamptz
933 }
934
935 type IssueLabel struct {
936 IssueID int64
937 LabelID int64
938 AppliedAt pgtype.Timestamptz
939 AppliedByUserID pgtype.Int8
940 }
941
942 type IssueReference struct {
943 ID int64
944 SourceIssueID pgtype.Int8
945 TargetIssueID int64
946 SourceKind IssueRefSource
947 SourceObjectID pgtype.Int8
948 CreatedAt pgtype.Timestamptz
949 }
950
951 type Job struct {
952 ID int64
953 Kind string
954 Payload []byte
955 RunAt pgtype.Timestamptz
956 Attempts int32
957 MaxAttempts int32
958 LastError pgtype.Text
959 LockedBy pgtype.Text
960 LockedAt pgtype.Timestamptz
961 CompletedAt pgtype.Timestamptz
962 FailedAt pgtype.Timestamptz
963 CreatedAt pgtype.Timestamptz
964 }
965
966 type Label struct {
967 ID int64
968 RepoID int64
969 Name string
970 Color string
971 Description string
972 CreatedAt pgtype.Timestamptz
973 }
974
975 type Meta struct {
976 Key string
977 Value []byte
978 UpdatedAt pgtype.Timestamptz
979 }
980
981 type Milestone struct {
982 ID int64
983 RepoID int64
984 Title string
985 Description string
986 State MilestoneState
987 DueOn pgtype.Timestamptz
988 CreatedAt pgtype.Timestamptz
989 ClosedAt pgtype.Timestamptz
990 }
991
992 type PasswordReset struct {
993 ID int64
994 UserID int64
995 TokenHash []byte
996 ExpiresAt pgtype.Timestamptz
997 UsedAt pgtype.Timestamptz
998 CreatedAt pgtype.Timestamptz
999 }
1000
1001 type PrReview struct {
1002 ID int64
1003 PrIssueID int64
1004 AuthorUserID pgtype.Int8
1005 State PrReviewState
1006 Body string
1007 BodyHtmlCached pgtype.Text
1008 SubmittedAt pgtype.Timestamptz
1009 DismissedAt pgtype.Timestamptz
1010 DismissedByUserID pgtype.Int8
1011 DismissalReason string
1012 }
1013
1014 type PrReviewComment struct {
1015 ID int64
1016 PrIssueID int64
1017 ReviewID pgtype.Int8
1018 AuthorUserID pgtype.Int8
1019 FilePath string
1020 Side PrReviewSide
1021 OriginalCommitSha string
1022 OriginalLine int32
1023 OriginalPosition int32
1024 CurrentPosition pgtype.Int4
1025 Body string
1026 BodyHtmlCached pgtype.Text
1027 InReplyToID pgtype.Int8
1028 Pending bool
1029 ResolvedAt pgtype.Timestamptz
1030 ResolvedByUserID pgtype.Int8
1031 CreatedAt pgtype.Timestamptz
1032 UpdatedAt pgtype.Timestamptz
1033 EditedAt pgtype.Timestamptz
1034 }
1035
1036 type PrReviewRequest struct {
1037 ID int64
1038 PrIssueID int64
1039 RequestedUserID pgtype.Int8
1040 RequestedTeamID pgtype.Int8
1041 RequestedByUserID pgtype.Int8
1042 RequestedAt pgtype.Timestamptz
1043 DismissedAt pgtype.Timestamptz
1044 SatisfiedByReviewID pgtype.Int8
1045 }
1046
1047 type PullRequest struct {
1048 IssueID int64
1049 BaseRef string
1050 HeadRef string
1051 HeadRepoID int64
1052 BaseOid string
1053 HeadOid string
1054 Draft bool
1055 Mergeable pgtype.Bool
1056 MergeableState PrMergeableState
1057 MergeCommitSha pgtype.Text
1058 MergedAt pgtype.Timestamptz
1059 MergedByUserID pgtype.Int8
1060 MergeMethod NullPrMergeMethod
1061 BaseOidAtMerge pgtype.Text
1062 HeadOidAtMerge pgtype.Text
1063 LastSynchronizedAt pgtype.Timestamptz
1064 }
1065
1066 type PullRequestCommit struct {
1067 PrID int64
1068 Sha string
1069 Position int32
1070 AuthorName string
1071 AuthorEmail string
1072 CommitterName string
1073 CommitterEmail string
1074 Subject string
1075 Body string
1076 AuthoredAt pgtype.Timestamptz
1077 CommittedAt pgtype.Timestamptz
1078 }
1079
1080 type PullRequestFile struct {
1081 PrID int64
1082 Path string
1083 Status PrFileStatus
1084 OldPath pgtype.Text
1085 Additions int32
1086 Deletions int32
1087 Changes int32
1088 }
1089
1090 type PushEvent struct {
1091 ID int64
1092 RepoID int64
1093 PusherUserID pgtype.Int8
1094 BeforeSha string
1095 AfterSha string
1096 Ref string
1097 Protocol string
1098 RequestID string
1099 ProcessedAt pgtype.Timestamptz
1100 CreatedAt pgtype.Timestamptz
1101 }
1102
1103 type Repo struct {
1104 ID int64
1105 OwnerUserID pgtype.Int8
1106 OwnerOrgID pgtype.Int8
1107 Name string
1108 Description string
1109 Visibility RepoVisibility
1110 DefaultBranch string
1111 IsArchived bool
1112 ArchivedAt pgtype.Timestamptz
1113 DeletedAt pgtype.Timestamptz
1114 DiskUsedBytes int64
1115 ForkOfRepoID pgtype.Int8
1116 LicenseKey pgtype.Text
1117 PrimaryLanguage pgtype.Text
1118 HasIssues bool
1119 HasPulls bool
1120 CreatedAt pgtype.Timestamptz
1121 UpdatedAt pgtype.Timestamptz
1122 DefaultBranchOid pgtype.Text
1123 AllowSquashMerge bool
1124 AllowRebaseMerge bool
1125 AllowMergeCommit bool
1126 DefaultMergeMethod PrMergeMethod
1127 StarCount int64
1128 WatcherCount int64
1129 ForkCount int64
1130 InitStatus RepoInitStatus
1131 }
1132
1133 type RepoCollaborator struct {
1134 RepoID int64
1135 UserID int64
1136 Role CollabRole
1137 AddedAt pgtype.Timestamptz
1138 AddedByUserID pgtype.Int8
1139 }
1140
1141 type RepoIssueCounter struct {
1142 RepoID int64
1143 NextNumber int64
1144 }
1145
1146 type RepoRedirect struct {
1147 OldOwnerUserID pgtype.Int8
1148 OldOwnerOrgID pgtype.Int8
1149 OldName string
1150 RepoID int64
1151 RedirectedAt pgtype.Timestamptz
1152 }
1153
1154 type RepoTransferRequest struct {
1155 ID int64
1156 RepoID int64
1157 FromUserID int64
1158 ToPrincipalKind TransferPrincipalKind
1159 ToPrincipalID int64
1160 CreatedBy int64
1161 CreatedAt pgtype.Timestamptz
1162 ExpiresAt pgtype.Timestamptz
1163 Status TransferStatus
1164 AcceptedAt pgtype.Timestamptz
1165 DeclinedAt pgtype.Timestamptz
1166 CanceledAt pgtype.Timestamptz
1167 }
1168
1169 type Star struct {
1170 UserID int64
1171 RepoID int64
1172 StarredAt pgtype.Timestamptz
1173 }
1174
1175 type User struct {
1176 ID int64
1177 Username string
1178 DisplayName string
1179 PrimaryEmailID pgtype.Int8
1180 PasswordHash string
1181 PasswordAlgo string
1182 PasswordUpdatedAt pgtype.Timestamptz
1183 EmailVerified bool
1184 LastLoginAt pgtype.Timestamptz
1185 SuspendedAt pgtype.Timestamptz
1186 SuspendedReason pgtype.Text
1187 DeletedAt pgtype.Timestamptz
1188 CreatedAt pgtype.Timestamptz
1189 UpdatedAt pgtype.Timestamptz
1190 Bio string
1191 Location string
1192 Website string
1193 Company string
1194 Pronouns string
1195 AvatarObjectKey pgtype.Text
1196 Theme string
1197 SessionEpoch int32
1198 }
1199
1200 type UserEmail struct {
1201 ID int64
1202 UserID int64
1203 Email string
1204 IsPrimary bool
1205 Verified bool
1206 VerificationTokenHash []byte
1207 VerificationSentAt pgtype.Timestamptz
1208 VerifiedAt pgtype.Timestamptz
1209 CreatedAt pgtype.Timestamptz
1210 }
1211
1212 type UserNotificationPref struct {
1213 UserID int64
1214 Key string
1215 Value []byte
1216 UpdatedAt pgtype.Timestamptz
1217 }
1218
1219 type UserRecoveryCode struct {
1220 ID int64
1221 UserID int64
1222 CodeHash []byte
1223 UsedAt pgtype.Timestamptz
1224 GeneratedAt pgtype.Timestamptz
1225 CreatedAt pgtype.Timestamptz
1226 }
1227
1228 type UserSshKey struct {
1229 ID int64
1230 UserID int64
1231 Title string
1232 FingerprintSha256 string
1233 KeyType string
1234 KeyBits int32
1235 PublicKey string
1236 LastUsedAt pgtype.Timestamptz
1237 LastUsedIp *netip.Addr
1238 CreatedAt pgtype.Timestamptz
1239 }
1240
1241 type UserToken struct {
1242 ID int64
1243 UserID int64
1244 Name string
1245 TokenHash []byte
1246 TokenPrefix string
1247 Scopes []string
1248 ExpiresAt pgtype.Timestamptz
1249 LastUsedAt pgtype.Timestamptz
1250 LastUsedIp *netip.Addr
1251 RevokedAt pgtype.Timestamptz
1252 CreatedAt pgtype.Timestamptz
1253 }
1254
1255 type UserTotp struct {
1256 ID int64
1257 UserID int64
1258 SecretEncrypted []byte
1259 SecretNonce []byte
1260 ConfirmedAt pgtype.Timestamptz
1261 LastUsedCounter int64
1262 CreatedAt pgtype.Timestamptz
1263 UpdatedAt pgtype.Timestamptz
1264 }
1265
1266 type UsernameRedirect struct {
1267 OldUsername string
1268 UserID int64
1269 ChangedAt pgtype.Timestamptz
1270 }
1271
1272 type Watch struct {
1273 UserID int64
1274 RepoID int64
1275 Level WatchLevel
1276 UpdatedAt pgtype.Timestamptz
1277 }
1278
1279 type WebhookEventsPending struct {
1280 ID int64
1281 RepoID int64
1282 EventKind string
1283 Payload []byte
1284 CreatedAt pgtype.Timestamptz
1285 }
1286