Go · 27532 bytes Raw Blame History
1 // Code generated by sqlc. DO NOT EDIT.
2 // versions:
3 // sqlc v1.31.1
4
5 package issuesdb
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 RepoVisibility string
584
585 const (
586 RepoVisibilityPublic RepoVisibility = "public"
587 RepoVisibilityPrivate RepoVisibility = "private"
588 )
589
590 func (e *RepoVisibility) Scan(src interface{}) error {
591 switch s := src.(type) {
592 case []byte:
593 *e = RepoVisibility(s)
594 case string:
595 *e = RepoVisibility(s)
596 default:
597 return fmt.Errorf("unsupported scan type for RepoVisibility: %T", src)
598 }
599 return nil
600 }
601
602 type NullRepoVisibility struct {
603 RepoVisibility RepoVisibility
604 Valid bool // Valid is true if RepoVisibility is not NULL
605 }
606
607 // Scan implements the Scanner interface.
608 func (ns *NullRepoVisibility) Scan(value interface{}) error {
609 if value == nil {
610 ns.RepoVisibility, ns.Valid = "", false
611 return nil
612 }
613 ns.Valid = true
614 return ns.RepoVisibility.Scan(value)
615 }
616
617 // Value implements the driver Valuer interface.
618 func (ns NullRepoVisibility) Value() (driver.Value, error) {
619 if !ns.Valid {
620 return nil, nil
621 }
622 return string(ns.RepoVisibility), nil
623 }
624
625 type TransferPrincipalKind string
626
627 const (
628 TransferPrincipalKindUser TransferPrincipalKind = "user"
629 TransferPrincipalKindOrg TransferPrincipalKind = "org"
630 )
631
632 func (e *TransferPrincipalKind) Scan(src interface{}) error {
633 switch s := src.(type) {
634 case []byte:
635 *e = TransferPrincipalKind(s)
636 case string:
637 *e = TransferPrincipalKind(s)
638 default:
639 return fmt.Errorf("unsupported scan type for TransferPrincipalKind: %T", src)
640 }
641 return nil
642 }
643
644 type NullTransferPrincipalKind struct {
645 TransferPrincipalKind TransferPrincipalKind
646 Valid bool // Valid is true if TransferPrincipalKind is not NULL
647 }
648
649 // Scan implements the Scanner interface.
650 func (ns *NullTransferPrincipalKind) Scan(value interface{}) error {
651 if value == nil {
652 ns.TransferPrincipalKind, ns.Valid = "", false
653 return nil
654 }
655 ns.Valid = true
656 return ns.TransferPrincipalKind.Scan(value)
657 }
658
659 // Value implements the driver Valuer interface.
660 func (ns NullTransferPrincipalKind) Value() (driver.Value, error) {
661 if !ns.Valid {
662 return nil, nil
663 }
664 return string(ns.TransferPrincipalKind), nil
665 }
666
667 type TransferStatus string
668
669 const (
670 TransferStatusPending TransferStatus = "pending"
671 TransferStatusAccepted TransferStatus = "accepted"
672 TransferStatusDeclined TransferStatus = "declined"
673 TransferStatusCanceled TransferStatus = "canceled"
674 TransferStatusExpired TransferStatus = "expired"
675 )
676
677 func (e *TransferStatus) Scan(src interface{}) error {
678 switch s := src.(type) {
679 case []byte:
680 *e = TransferStatus(s)
681 case string:
682 *e = TransferStatus(s)
683 default:
684 return fmt.Errorf("unsupported scan type for TransferStatus: %T", src)
685 }
686 return nil
687 }
688
689 type NullTransferStatus struct {
690 TransferStatus TransferStatus
691 Valid bool // Valid is true if TransferStatus is not NULL
692 }
693
694 // Scan implements the Scanner interface.
695 func (ns *NullTransferStatus) Scan(value interface{}) error {
696 if value == nil {
697 ns.TransferStatus, ns.Valid = "", false
698 return nil
699 }
700 ns.Valid = true
701 return ns.TransferStatus.Scan(value)
702 }
703
704 // Value implements the driver Valuer interface.
705 func (ns NullTransferStatus) Value() (driver.Value, error) {
706 if !ns.Valid {
707 return nil, nil
708 }
709 return string(ns.TransferStatus), nil
710 }
711
712 type AuthAuditLog struct {
713 ID int64
714 ActorID pgtype.Int8
715 Action string
716 TargetType string
717 TargetID pgtype.Int8
718 Meta []byte
719 CreatedAt pgtype.Timestamptz
720 }
721
722 type AuthThrottle struct {
723 ID int64
724 Scope string
725 Identifier string
726 Hits int32
727 WindowStartedAt pgtype.Timestamptz
728 }
729
730 type BranchProtectionRule struct {
731 ID int64
732 RepoID int64
733 Pattern string
734 PreventForcePush bool
735 PreventDeletion bool
736 RequirePrForPush bool
737 AllowedPusherUserIds []int64
738 RequireSignedCommits bool
739 StatusChecksRequired []string
740 CreatedAt pgtype.Timestamptz
741 UpdatedAt pgtype.Timestamptz
742 CreatedByUserID pgtype.Int8
743 RequiredReviewCount int32
744 DismissStaleReviewsOnPush bool
745 RequireCodeOwnerReview bool
746 DismissStaleStatusChecksOnPush bool
747 }
748
749 type CheckRun struct {
750 ID int64
751 SuiteID int64
752 RepoID int64
753 HeadSha string
754 Name string
755 Status CheckStatus
756 Conclusion NullCheckConclusion
757 StartedAt pgtype.Timestamptz
758 CompletedAt pgtype.Timestamptz
759 DetailsUrl string
760 Output []byte
761 ExternalID pgtype.Text
762 CreatedAt pgtype.Timestamptz
763 UpdatedAt pgtype.Timestamptz
764 }
765
766 type CheckSuite struct {
767 ID int64
768 RepoID int64
769 HeadSha string
770 AppSlug string
771 Status CheckStatus
772 Conclusion NullCheckConclusion
773 CreatedAt pgtype.Timestamptz
774 UpdatedAt pgtype.Timestamptz
775 }
776
777 type EmailVerification struct {
778 ID int64
779 UserEmailID int64
780 TokenHash []byte
781 ExpiresAt pgtype.Timestamptz
782 UsedAt pgtype.Timestamptz
783 CreatedAt pgtype.Timestamptz
784 }
785
786 type Issue struct {
787 ID int64
788 RepoID int64
789 Number int64
790 Kind IssueKind
791 Title string
792 Body string
793 BodyHtmlCached pgtype.Text
794 MdPipelineVersion int32
795 AuthorUserID pgtype.Int8
796 State IssueState
797 StateReason NullIssueStateReason
798 Locked bool
799 LockReason pgtype.Text
800 MilestoneID pgtype.Int8
801 CreatedAt pgtype.Timestamptz
802 UpdatedAt pgtype.Timestamptz
803 EditedAt pgtype.Timestamptz
804 ClosedAt pgtype.Timestamptz
805 ClosedByUserID pgtype.Int8
806 }
807
808 type IssueAssignee struct {
809 IssueID int64
810 UserID int64
811 AssignedAt pgtype.Timestamptz
812 AssignedByUserID pgtype.Int8
813 }
814
815 type IssueComment struct {
816 ID int64
817 IssueID int64
818 AuthorUserID pgtype.Int8
819 Body string
820 BodyHtmlCached pgtype.Text
821 MdPipelineVersion int32
822 CreatedAt pgtype.Timestamptz
823 UpdatedAt pgtype.Timestamptz
824 EditedAt pgtype.Timestamptz
825 }
826
827 type IssueEvent struct {
828 ID int64
829 IssueID int64
830 ActorUserID pgtype.Int8
831 Kind string
832 Meta []byte
833 RefTargetID pgtype.Int8
834 CreatedAt pgtype.Timestamptz
835 }
836
837 type IssueLabel struct {
838 IssueID int64
839 LabelID int64
840 AppliedAt pgtype.Timestamptz
841 AppliedByUserID pgtype.Int8
842 }
843
844 type IssueReference struct {
845 ID int64
846 SourceIssueID pgtype.Int8
847 TargetIssueID int64
848 SourceKind IssueRefSource
849 SourceObjectID pgtype.Int8
850 CreatedAt pgtype.Timestamptz
851 }
852
853 type Job struct {
854 ID int64
855 Kind string
856 Payload []byte
857 RunAt pgtype.Timestamptz
858 Attempts int32
859 MaxAttempts int32
860 LastError pgtype.Text
861 LockedBy pgtype.Text
862 LockedAt pgtype.Timestamptz
863 CompletedAt pgtype.Timestamptz
864 FailedAt pgtype.Timestamptz
865 CreatedAt pgtype.Timestamptz
866 }
867
868 type Label struct {
869 ID int64
870 RepoID int64
871 Name string
872 Color string
873 Description string
874 CreatedAt pgtype.Timestamptz
875 }
876
877 type Meta struct {
878 Key string
879 Value []byte
880 UpdatedAt pgtype.Timestamptz
881 }
882
883 type Milestone struct {
884 ID int64
885 RepoID int64
886 Title string
887 Description string
888 State MilestoneState
889 DueOn pgtype.Timestamptz
890 CreatedAt pgtype.Timestamptz
891 ClosedAt pgtype.Timestamptz
892 }
893
894 type PasswordReset struct {
895 ID int64
896 UserID int64
897 TokenHash []byte
898 ExpiresAt pgtype.Timestamptz
899 UsedAt pgtype.Timestamptz
900 CreatedAt pgtype.Timestamptz
901 }
902
903 type PrReview struct {
904 ID int64
905 PrIssueID int64
906 AuthorUserID pgtype.Int8
907 State PrReviewState
908 Body string
909 BodyHtmlCached pgtype.Text
910 SubmittedAt pgtype.Timestamptz
911 DismissedAt pgtype.Timestamptz
912 DismissedByUserID pgtype.Int8
913 DismissalReason string
914 }
915
916 type PrReviewComment struct {
917 ID int64
918 PrIssueID int64
919 ReviewID pgtype.Int8
920 AuthorUserID pgtype.Int8
921 FilePath string
922 Side PrReviewSide
923 OriginalCommitSha string
924 OriginalLine int32
925 OriginalPosition int32
926 CurrentPosition pgtype.Int4
927 Body string
928 BodyHtmlCached pgtype.Text
929 InReplyToID pgtype.Int8
930 Pending bool
931 ResolvedAt pgtype.Timestamptz
932 ResolvedByUserID pgtype.Int8
933 CreatedAt pgtype.Timestamptz
934 UpdatedAt pgtype.Timestamptz
935 EditedAt pgtype.Timestamptz
936 }
937
938 type PrReviewRequest struct {
939 ID int64
940 PrIssueID int64
941 RequestedUserID pgtype.Int8
942 RequestedTeamID pgtype.Int8
943 RequestedByUserID pgtype.Int8
944 RequestedAt pgtype.Timestamptz
945 DismissedAt pgtype.Timestamptz
946 SatisfiedByReviewID pgtype.Int8
947 }
948
949 type PullRequest struct {
950 IssueID int64
951 BaseRef string
952 HeadRef string
953 HeadRepoID int64
954 BaseOid string
955 HeadOid string
956 Draft bool
957 Mergeable pgtype.Bool
958 MergeableState PrMergeableState
959 MergeCommitSha pgtype.Text
960 MergedAt pgtype.Timestamptz
961 MergedByUserID pgtype.Int8
962 MergeMethod NullPrMergeMethod
963 BaseOidAtMerge pgtype.Text
964 HeadOidAtMerge pgtype.Text
965 LastSynchronizedAt pgtype.Timestamptz
966 }
967
968 type PullRequestCommit struct {
969 PrID int64
970 Sha string
971 Position int32
972 AuthorName string
973 AuthorEmail string
974 CommitterName string
975 CommitterEmail string
976 Subject string
977 Body string
978 AuthoredAt pgtype.Timestamptz
979 CommittedAt pgtype.Timestamptz
980 }
981
982 type PullRequestFile struct {
983 PrID int64
984 Path string
985 Status PrFileStatus
986 OldPath pgtype.Text
987 Additions int32
988 Deletions int32
989 Changes int32
990 }
991
992 type PushEvent struct {
993 ID int64
994 RepoID int64
995 PusherUserID pgtype.Int8
996 BeforeSha string
997 AfterSha string
998 Ref string
999 Protocol string
1000 RequestID string
1001 ProcessedAt pgtype.Timestamptz
1002 CreatedAt pgtype.Timestamptz
1003 }
1004
1005 type Repo struct {
1006 ID int64
1007 OwnerUserID pgtype.Int8
1008 OwnerOrgID pgtype.Int8
1009 Name string
1010 Description string
1011 Visibility RepoVisibility
1012 DefaultBranch string
1013 IsArchived bool
1014 ArchivedAt pgtype.Timestamptz
1015 DeletedAt pgtype.Timestamptz
1016 DiskUsedBytes int64
1017 ForkOfRepoID pgtype.Int8
1018 LicenseKey pgtype.Text
1019 PrimaryLanguage pgtype.Text
1020 HasIssues bool
1021 HasPulls bool
1022 CreatedAt pgtype.Timestamptz
1023 UpdatedAt pgtype.Timestamptz
1024 DefaultBranchOid pgtype.Text
1025 AllowSquashMerge bool
1026 AllowRebaseMerge bool
1027 AllowMergeCommit bool
1028 DefaultMergeMethod PrMergeMethod
1029 }
1030
1031 type RepoCollaborator struct {
1032 RepoID int64
1033 UserID int64
1034 Role CollabRole
1035 AddedAt pgtype.Timestamptz
1036 AddedByUserID pgtype.Int8
1037 }
1038
1039 type RepoIssueCounter struct {
1040 RepoID int64
1041 NextNumber int64
1042 }
1043
1044 type RepoRedirect struct {
1045 OldOwnerUserID pgtype.Int8
1046 OldOwnerOrgID pgtype.Int8
1047 OldName string
1048 RepoID int64
1049 RedirectedAt pgtype.Timestamptz
1050 }
1051
1052 type RepoTransferRequest struct {
1053 ID int64
1054 RepoID int64
1055 FromUserID int64
1056 ToPrincipalKind TransferPrincipalKind
1057 ToPrincipalID int64
1058 CreatedBy int64
1059 CreatedAt pgtype.Timestamptz
1060 ExpiresAt pgtype.Timestamptz
1061 Status TransferStatus
1062 AcceptedAt pgtype.Timestamptz
1063 DeclinedAt pgtype.Timestamptz
1064 CanceledAt pgtype.Timestamptz
1065 }
1066
1067 type User struct {
1068 ID int64
1069 Username string
1070 DisplayName string
1071 PrimaryEmailID pgtype.Int8
1072 PasswordHash string
1073 PasswordAlgo string
1074 PasswordUpdatedAt pgtype.Timestamptz
1075 EmailVerified bool
1076 LastLoginAt pgtype.Timestamptz
1077 SuspendedAt pgtype.Timestamptz
1078 SuspendedReason pgtype.Text
1079 DeletedAt pgtype.Timestamptz
1080 CreatedAt pgtype.Timestamptz
1081 UpdatedAt pgtype.Timestamptz
1082 Bio string
1083 Location string
1084 Website string
1085 Company string
1086 Pronouns string
1087 AvatarObjectKey pgtype.Text
1088 Theme string
1089 SessionEpoch int32
1090 }
1091
1092 type UserEmail struct {
1093 ID int64
1094 UserID int64
1095 Email string
1096 IsPrimary bool
1097 Verified bool
1098 VerificationTokenHash []byte
1099 VerificationSentAt pgtype.Timestamptz
1100 VerifiedAt pgtype.Timestamptz
1101 CreatedAt pgtype.Timestamptz
1102 }
1103
1104 type UserNotificationPref struct {
1105 UserID int64
1106 Key string
1107 Value []byte
1108 UpdatedAt pgtype.Timestamptz
1109 }
1110
1111 type UserRecoveryCode struct {
1112 ID int64
1113 UserID int64
1114 CodeHash []byte
1115 UsedAt pgtype.Timestamptz
1116 GeneratedAt pgtype.Timestamptz
1117 CreatedAt pgtype.Timestamptz
1118 }
1119
1120 type UserSshKey struct {
1121 ID int64
1122 UserID int64
1123 Title string
1124 FingerprintSha256 string
1125 KeyType string
1126 KeyBits int32
1127 PublicKey string
1128 LastUsedAt pgtype.Timestamptz
1129 LastUsedIp *netip.Addr
1130 CreatedAt pgtype.Timestamptz
1131 }
1132
1133 type UserToken struct {
1134 ID int64
1135 UserID int64
1136 Name string
1137 TokenHash []byte
1138 TokenPrefix string
1139 Scopes []string
1140 ExpiresAt pgtype.Timestamptz
1141 LastUsedAt pgtype.Timestamptz
1142 LastUsedIp *netip.Addr
1143 RevokedAt pgtype.Timestamptz
1144 CreatedAt pgtype.Timestamptz
1145 }
1146
1147 type UserTotp struct {
1148 ID int64
1149 UserID int64
1150 SecretEncrypted []byte
1151 SecretNonce []byte
1152 ConfirmedAt pgtype.Timestamptz
1153 LastUsedCounter int64
1154 CreatedAt pgtype.Timestamptz
1155 UpdatedAt pgtype.Timestamptz
1156 }
1157
1158 type UsernameRedirect struct {
1159 OldUsername string
1160 UserID int64
1161 ChangedAt pgtype.Timestamptz
1162 }
1163
1164 type WebhookEventsPending struct {
1165 ID int64
1166 RepoID int64
1167 EventKind string
1168 Payload []byte
1169 CreatedAt pgtype.Timestamptz
1170 }
1171