Go · 72274 bytes Raw Blame History
1 // Code generated by sqlc. DO NOT EDIT.
2 // versions:
3 // sqlc v1.31.1
4
5 package actionsdb
6
7 import (
8 "database/sql/driver"
9 "fmt"
10 "net/netip"
11
12 "github.com/jackc/pgx/v5/pgtype"
13 )
14
15 type ActionsPolicyState string
16
17 const (
18 ActionsPolicyStateInherit ActionsPolicyState = "inherit"
19 ActionsPolicyStateEnabled ActionsPolicyState = "enabled"
20 ActionsPolicyStateDisabled ActionsPolicyState = "disabled"
21 )
22
23 func (e *ActionsPolicyState) Scan(src interface{}) error {
24 switch s := src.(type) {
25 case []byte:
26 *e = ActionsPolicyState(s)
27 case string:
28 *e = ActionsPolicyState(s)
29 default:
30 return fmt.Errorf("unsupported scan type for ActionsPolicyState: %T", src)
31 }
32 return nil
33 }
34
35 type NullActionsPolicyState struct {
36 ActionsPolicyState ActionsPolicyState
37 Valid bool // Valid is true if ActionsPolicyState is not NULL
38 }
39
40 // Scan implements the Scanner interface.
41 func (ns *NullActionsPolicyState) Scan(value interface{}) error {
42 if value == nil {
43 ns.ActionsPolicyState, ns.Valid = "", false
44 return nil
45 }
46 ns.Valid = true
47 return ns.ActionsPolicyState.Scan(value)
48 }
49
50 // Value implements the driver Valuer interface.
51 func (ns NullActionsPolicyState) Value() (driver.Value, error) {
52 if !ns.Valid {
53 return nil, nil
54 }
55 return string(ns.ActionsPolicyState), nil
56 }
57
58 type BillingInvoiceStatus string
59
60 const (
61 BillingInvoiceStatusDraft BillingInvoiceStatus = "draft"
62 BillingInvoiceStatusOpen BillingInvoiceStatus = "open"
63 BillingInvoiceStatusPaid BillingInvoiceStatus = "paid"
64 BillingInvoiceStatusVoid BillingInvoiceStatus = "void"
65 BillingInvoiceStatusUncollectible BillingInvoiceStatus = "uncollectible"
66 )
67
68 func (e *BillingInvoiceStatus) Scan(src interface{}) error {
69 switch s := src.(type) {
70 case []byte:
71 *e = BillingInvoiceStatus(s)
72 case string:
73 *e = BillingInvoiceStatus(s)
74 default:
75 return fmt.Errorf("unsupported scan type for BillingInvoiceStatus: %T", src)
76 }
77 return nil
78 }
79
80 type NullBillingInvoiceStatus struct {
81 BillingInvoiceStatus BillingInvoiceStatus
82 Valid bool // Valid is true if BillingInvoiceStatus is not NULL
83 }
84
85 // Scan implements the Scanner interface.
86 func (ns *NullBillingInvoiceStatus) Scan(value interface{}) error {
87 if value == nil {
88 ns.BillingInvoiceStatus, ns.Valid = "", false
89 return nil
90 }
91 ns.Valid = true
92 return ns.BillingInvoiceStatus.Scan(value)
93 }
94
95 // Value implements the driver Valuer interface.
96 func (ns NullBillingInvoiceStatus) Value() (driver.Value, error) {
97 if !ns.Valid {
98 return nil, nil
99 }
100 return string(ns.BillingInvoiceStatus), nil
101 }
102
103 type BillingLockReason string
104
105 const (
106 BillingLockReasonPastDue BillingLockReason = "past_due"
107 BillingLockReasonCanceled BillingLockReason = "canceled"
108 BillingLockReasonUnpaid BillingLockReason = "unpaid"
109 BillingLockReasonManual BillingLockReason = "manual"
110 )
111
112 func (e *BillingLockReason) Scan(src interface{}) error {
113 switch s := src.(type) {
114 case []byte:
115 *e = BillingLockReason(s)
116 case string:
117 *e = BillingLockReason(s)
118 default:
119 return fmt.Errorf("unsupported scan type for BillingLockReason: %T", src)
120 }
121 return nil
122 }
123
124 type NullBillingLockReason struct {
125 BillingLockReason BillingLockReason
126 Valid bool // Valid is true if BillingLockReason is not NULL
127 }
128
129 // Scan implements the Scanner interface.
130 func (ns *NullBillingLockReason) Scan(value interface{}) error {
131 if value == nil {
132 ns.BillingLockReason, ns.Valid = "", false
133 return nil
134 }
135 ns.Valid = true
136 return ns.BillingLockReason.Scan(value)
137 }
138
139 // Value implements the driver Valuer interface.
140 func (ns NullBillingLockReason) Value() (driver.Value, error) {
141 if !ns.Valid {
142 return nil, nil
143 }
144 return string(ns.BillingLockReason), nil
145 }
146
147 type BillingProvider string
148
149 const (
150 BillingProviderStripe BillingProvider = "stripe"
151 )
152
153 func (e *BillingProvider) Scan(src interface{}) error {
154 switch s := src.(type) {
155 case []byte:
156 *e = BillingProvider(s)
157 case string:
158 *e = BillingProvider(s)
159 default:
160 return fmt.Errorf("unsupported scan type for BillingProvider: %T", src)
161 }
162 return nil
163 }
164
165 type NullBillingProvider struct {
166 BillingProvider BillingProvider
167 Valid bool // Valid is true if BillingProvider is not NULL
168 }
169
170 // Scan implements the Scanner interface.
171 func (ns *NullBillingProvider) Scan(value interface{}) error {
172 if value == nil {
173 ns.BillingProvider, ns.Valid = "", false
174 return nil
175 }
176 ns.Valid = true
177 return ns.BillingProvider.Scan(value)
178 }
179
180 // Value implements the driver Valuer interface.
181 func (ns NullBillingProvider) Value() (driver.Value, error) {
182 if !ns.Valid {
183 return nil, nil
184 }
185 return string(ns.BillingProvider), nil
186 }
187
188 type BillingSubscriptionStatus string
189
190 const (
191 BillingSubscriptionStatusNone BillingSubscriptionStatus = "none"
192 BillingSubscriptionStatusIncomplete BillingSubscriptionStatus = "incomplete"
193 BillingSubscriptionStatusTrialing BillingSubscriptionStatus = "trialing"
194 BillingSubscriptionStatusActive BillingSubscriptionStatus = "active"
195 BillingSubscriptionStatusPastDue BillingSubscriptionStatus = "past_due"
196 BillingSubscriptionStatusCanceled BillingSubscriptionStatus = "canceled"
197 BillingSubscriptionStatusUnpaid BillingSubscriptionStatus = "unpaid"
198 BillingSubscriptionStatusPaused BillingSubscriptionStatus = "paused"
199 )
200
201 func (e *BillingSubscriptionStatus) Scan(src interface{}) error {
202 switch s := src.(type) {
203 case []byte:
204 *e = BillingSubscriptionStatus(s)
205 case string:
206 *e = BillingSubscriptionStatus(s)
207 default:
208 return fmt.Errorf("unsupported scan type for BillingSubscriptionStatus: %T", src)
209 }
210 return nil
211 }
212
213 type NullBillingSubscriptionStatus struct {
214 BillingSubscriptionStatus BillingSubscriptionStatus
215 Valid bool // Valid is true if BillingSubscriptionStatus is not NULL
216 }
217
218 // Scan implements the Scanner interface.
219 func (ns *NullBillingSubscriptionStatus) Scan(value interface{}) error {
220 if value == nil {
221 ns.BillingSubscriptionStatus, ns.Valid = "", false
222 return nil
223 }
224 ns.Valid = true
225 return ns.BillingSubscriptionStatus.Scan(value)
226 }
227
228 // Value implements the driver Valuer interface.
229 func (ns NullBillingSubscriptionStatus) Value() (driver.Value, error) {
230 if !ns.Valid {
231 return nil, nil
232 }
233 return string(ns.BillingSubscriptionStatus), nil
234 }
235
236 type CheckConclusion string
237
238 const (
239 CheckConclusionSuccess CheckConclusion = "success"
240 CheckConclusionFailure CheckConclusion = "failure"
241 CheckConclusionNeutral CheckConclusion = "neutral"
242 CheckConclusionCancelled CheckConclusion = "cancelled"
243 CheckConclusionSkipped CheckConclusion = "skipped"
244 CheckConclusionTimedOut CheckConclusion = "timed_out"
245 CheckConclusionActionRequired CheckConclusion = "action_required"
246 CheckConclusionStale CheckConclusion = "stale"
247 )
248
249 func (e *CheckConclusion) Scan(src interface{}) error {
250 switch s := src.(type) {
251 case []byte:
252 *e = CheckConclusion(s)
253 case string:
254 *e = CheckConclusion(s)
255 default:
256 return fmt.Errorf("unsupported scan type for CheckConclusion: %T", src)
257 }
258 return nil
259 }
260
261 type NullCheckConclusion struct {
262 CheckConclusion CheckConclusion
263 Valid bool // Valid is true if CheckConclusion is not NULL
264 }
265
266 // Scan implements the Scanner interface.
267 func (ns *NullCheckConclusion) Scan(value interface{}) error {
268 if value == nil {
269 ns.CheckConclusion, ns.Valid = "", false
270 return nil
271 }
272 ns.Valid = true
273 return ns.CheckConclusion.Scan(value)
274 }
275
276 // Value implements the driver Valuer interface.
277 func (ns NullCheckConclusion) Value() (driver.Value, error) {
278 if !ns.Valid {
279 return nil, nil
280 }
281 return string(ns.CheckConclusion), nil
282 }
283
284 type CheckStatus string
285
286 const (
287 CheckStatusQueued CheckStatus = "queued"
288 CheckStatusInProgress CheckStatus = "in_progress"
289 CheckStatusCompleted CheckStatus = "completed"
290 CheckStatusPending CheckStatus = "pending"
291 )
292
293 func (e *CheckStatus) Scan(src interface{}) error {
294 switch s := src.(type) {
295 case []byte:
296 *e = CheckStatus(s)
297 case string:
298 *e = CheckStatus(s)
299 default:
300 return fmt.Errorf("unsupported scan type for CheckStatus: %T", src)
301 }
302 return nil
303 }
304
305 type NullCheckStatus struct {
306 CheckStatus CheckStatus
307 Valid bool // Valid is true if CheckStatus is not NULL
308 }
309
310 // Scan implements the Scanner interface.
311 func (ns *NullCheckStatus) Scan(value interface{}) error {
312 if value == nil {
313 ns.CheckStatus, ns.Valid = "", false
314 return nil
315 }
316 ns.Valid = true
317 return ns.CheckStatus.Scan(value)
318 }
319
320 // Value implements the driver Valuer interface.
321 func (ns NullCheckStatus) Value() (driver.Value, error) {
322 if !ns.Valid {
323 return nil, nil
324 }
325 return string(ns.CheckStatus), nil
326 }
327
328 type CollabRole string
329
330 const (
331 CollabRoleRead CollabRole = "read"
332 CollabRoleTriage CollabRole = "triage"
333 CollabRoleWrite CollabRole = "write"
334 CollabRoleMaintain CollabRole = "maintain"
335 CollabRoleAdmin CollabRole = "admin"
336 )
337
338 func (e *CollabRole) Scan(src interface{}) error {
339 switch s := src.(type) {
340 case []byte:
341 *e = CollabRole(s)
342 case string:
343 *e = CollabRole(s)
344 default:
345 return fmt.Errorf("unsupported scan type for CollabRole: %T", src)
346 }
347 return nil
348 }
349
350 type NullCollabRole struct {
351 CollabRole CollabRole
352 Valid bool // Valid is true if CollabRole is not NULL
353 }
354
355 // Scan implements the Scanner interface.
356 func (ns *NullCollabRole) Scan(value interface{}) error {
357 if value == nil {
358 ns.CollabRole, ns.Valid = "", false
359 return nil
360 }
361 ns.Valid = true
362 return ns.CollabRole.Scan(value)
363 }
364
365 // Value implements the driver Valuer interface.
366 func (ns NullCollabRole) Value() (driver.Value, error) {
367 if !ns.Valid {
368 return nil, nil
369 }
370 return string(ns.CollabRole), nil
371 }
372
373 type IssueKind string
374
375 const (
376 IssueKindIssue IssueKind = "issue"
377 IssueKindPr IssueKind = "pr"
378 )
379
380 func (e *IssueKind) Scan(src interface{}) error {
381 switch s := src.(type) {
382 case []byte:
383 *e = IssueKind(s)
384 case string:
385 *e = IssueKind(s)
386 default:
387 return fmt.Errorf("unsupported scan type for IssueKind: %T", src)
388 }
389 return nil
390 }
391
392 type NullIssueKind struct {
393 IssueKind IssueKind
394 Valid bool // Valid is true if IssueKind is not NULL
395 }
396
397 // Scan implements the Scanner interface.
398 func (ns *NullIssueKind) Scan(value interface{}) error {
399 if value == nil {
400 ns.IssueKind, ns.Valid = "", false
401 return nil
402 }
403 ns.Valid = true
404 return ns.IssueKind.Scan(value)
405 }
406
407 // Value implements the driver Valuer interface.
408 func (ns NullIssueKind) Value() (driver.Value, error) {
409 if !ns.Valid {
410 return nil, nil
411 }
412 return string(ns.IssueKind), nil
413 }
414
415 type IssueRefSource string
416
417 const (
418 IssueRefSourceCommentBody IssueRefSource = "comment_body"
419 IssueRefSourceIssueBody IssueRefSource = "issue_body"
420 IssueRefSourceCommitMessage IssueRefSource = "commit_message"
421 )
422
423 func (e *IssueRefSource) Scan(src interface{}) error {
424 switch s := src.(type) {
425 case []byte:
426 *e = IssueRefSource(s)
427 case string:
428 *e = IssueRefSource(s)
429 default:
430 return fmt.Errorf("unsupported scan type for IssueRefSource: %T", src)
431 }
432 return nil
433 }
434
435 type NullIssueRefSource struct {
436 IssueRefSource IssueRefSource
437 Valid bool // Valid is true if IssueRefSource is not NULL
438 }
439
440 // Scan implements the Scanner interface.
441 func (ns *NullIssueRefSource) Scan(value interface{}) error {
442 if value == nil {
443 ns.IssueRefSource, ns.Valid = "", false
444 return nil
445 }
446 ns.Valid = true
447 return ns.IssueRefSource.Scan(value)
448 }
449
450 // Value implements the driver Valuer interface.
451 func (ns NullIssueRefSource) Value() (driver.Value, error) {
452 if !ns.Valid {
453 return nil, nil
454 }
455 return string(ns.IssueRefSource), nil
456 }
457
458 type IssueState string
459
460 const (
461 IssueStateOpen IssueState = "open"
462 IssueStateClosed IssueState = "closed"
463 )
464
465 func (e *IssueState) Scan(src interface{}) error {
466 switch s := src.(type) {
467 case []byte:
468 *e = IssueState(s)
469 case string:
470 *e = IssueState(s)
471 default:
472 return fmt.Errorf("unsupported scan type for IssueState: %T", src)
473 }
474 return nil
475 }
476
477 type NullIssueState struct {
478 IssueState IssueState
479 Valid bool // Valid is true if IssueState is not NULL
480 }
481
482 // Scan implements the Scanner interface.
483 func (ns *NullIssueState) Scan(value interface{}) error {
484 if value == nil {
485 ns.IssueState, ns.Valid = "", false
486 return nil
487 }
488 ns.Valid = true
489 return ns.IssueState.Scan(value)
490 }
491
492 // Value implements the driver Valuer interface.
493 func (ns NullIssueState) Value() (driver.Value, error) {
494 if !ns.Valid {
495 return nil, nil
496 }
497 return string(ns.IssueState), nil
498 }
499
500 type IssueStateReason string
501
502 const (
503 IssueStateReasonCompleted IssueStateReason = "completed"
504 IssueStateReasonNotPlanned IssueStateReason = "not_planned"
505 IssueStateReasonReopened IssueStateReason = "reopened"
506 IssueStateReasonDuplicate IssueStateReason = "duplicate"
507 )
508
509 func (e *IssueStateReason) Scan(src interface{}) error {
510 switch s := src.(type) {
511 case []byte:
512 *e = IssueStateReason(s)
513 case string:
514 *e = IssueStateReason(s)
515 default:
516 return fmt.Errorf("unsupported scan type for IssueStateReason: %T", src)
517 }
518 return nil
519 }
520
521 type NullIssueStateReason struct {
522 IssueStateReason IssueStateReason
523 Valid bool // Valid is true if IssueStateReason is not NULL
524 }
525
526 // Scan implements the Scanner interface.
527 func (ns *NullIssueStateReason) Scan(value interface{}) error {
528 if value == nil {
529 ns.IssueStateReason, ns.Valid = "", false
530 return nil
531 }
532 ns.Valid = true
533 return ns.IssueStateReason.Scan(value)
534 }
535
536 // Value implements the driver Valuer interface.
537 func (ns NullIssueStateReason) Value() (driver.Value, error) {
538 if !ns.Valid {
539 return nil, nil
540 }
541 return string(ns.IssueStateReason), nil
542 }
543
544 type MilestoneState string
545
546 const (
547 MilestoneStateOpen MilestoneState = "open"
548 MilestoneStateClosed MilestoneState = "closed"
549 )
550
551 func (e *MilestoneState) Scan(src interface{}) error {
552 switch s := src.(type) {
553 case []byte:
554 *e = MilestoneState(s)
555 case string:
556 *e = MilestoneState(s)
557 default:
558 return fmt.Errorf("unsupported scan type for MilestoneState: %T", src)
559 }
560 return nil
561 }
562
563 type NullMilestoneState struct {
564 MilestoneState MilestoneState
565 Valid bool // Valid is true if MilestoneState is not NULL
566 }
567
568 // Scan implements the Scanner interface.
569 func (ns *NullMilestoneState) Scan(value interface{}) error {
570 if value == nil {
571 ns.MilestoneState, ns.Valid = "", false
572 return nil
573 }
574 ns.Valid = true
575 return ns.MilestoneState.Scan(value)
576 }
577
578 // Value implements the driver Valuer interface.
579 func (ns NullMilestoneState) Value() (driver.Value, error) {
580 if !ns.Valid {
581 return nil, nil
582 }
583 return string(ns.MilestoneState), nil
584 }
585
586 type NotificationThreadKind string
587
588 const (
589 NotificationThreadKindIssue NotificationThreadKind = "issue"
590 NotificationThreadKindPr NotificationThreadKind = "pr"
591 )
592
593 func (e *NotificationThreadKind) Scan(src interface{}) error {
594 switch s := src.(type) {
595 case []byte:
596 *e = NotificationThreadKind(s)
597 case string:
598 *e = NotificationThreadKind(s)
599 default:
600 return fmt.Errorf("unsupported scan type for NotificationThreadKind: %T", src)
601 }
602 return nil
603 }
604
605 type NullNotificationThreadKind struct {
606 NotificationThreadKind NotificationThreadKind
607 Valid bool // Valid is true if NotificationThreadKind is not NULL
608 }
609
610 // Scan implements the Scanner interface.
611 func (ns *NullNotificationThreadKind) Scan(value interface{}) error {
612 if value == nil {
613 ns.NotificationThreadKind, ns.Valid = "", false
614 return nil
615 }
616 ns.Valid = true
617 return ns.NotificationThreadKind.Scan(value)
618 }
619
620 // Value implements the driver Valuer interface.
621 func (ns NullNotificationThreadKind) Value() (driver.Value, error) {
622 if !ns.Valid {
623 return nil, nil
624 }
625 return string(ns.NotificationThreadKind), nil
626 }
627
628 type OrgPlan string
629
630 const (
631 OrgPlanFree OrgPlan = "free"
632 OrgPlanTeam OrgPlan = "team"
633 OrgPlanEnterprise OrgPlan = "enterprise"
634 )
635
636 func (e *OrgPlan) Scan(src interface{}) error {
637 switch s := src.(type) {
638 case []byte:
639 *e = OrgPlan(s)
640 case string:
641 *e = OrgPlan(s)
642 default:
643 return fmt.Errorf("unsupported scan type for OrgPlan: %T", src)
644 }
645 return nil
646 }
647
648 type NullOrgPlan struct {
649 OrgPlan OrgPlan
650 Valid bool // Valid is true if OrgPlan is not NULL
651 }
652
653 // Scan implements the Scanner interface.
654 func (ns *NullOrgPlan) Scan(value interface{}) error {
655 if value == nil {
656 ns.OrgPlan, ns.Valid = "", false
657 return nil
658 }
659 ns.Valid = true
660 return ns.OrgPlan.Scan(value)
661 }
662
663 // Value implements the driver Valuer interface.
664 func (ns NullOrgPlan) Value() (driver.Value, error) {
665 if !ns.Valid {
666 return nil, nil
667 }
668 return string(ns.OrgPlan), nil
669 }
670
671 type OrgRole string
672
673 const (
674 OrgRoleOwner OrgRole = "owner"
675 OrgRoleMember OrgRole = "member"
676 )
677
678 func (e *OrgRole) Scan(src interface{}) error {
679 switch s := src.(type) {
680 case []byte:
681 *e = OrgRole(s)
682 case string:
683 *e = OrgRole(s)
684 default:
685 return fmt.Errorf("unsupported scan type for OrgRole: %T", src)
686 }
687 return nil
688 }
689
690 type NullOrgRole struct {
691 OrgRole OrgRole
692 Valid bool // Valid is true if OrgRole is not NULL
693 }
694
695 // Scan implements the Scanner interface.
696 func (ns *NullOrgRole) Scan(value interface{}) error {
697 if value == nil {
698 ns.OrgRole, ns.Valid = "", false
699 return nil
700 }
701 ns.Valid = true
702 return ns.OrgRole.Scan(value)
703 }
704
705 // Value implements the driver Valuer interface.
706 func (ns NullOrgRole) Value() (driver.Value, error) {
707 if !ns.Valid {
708 return nil, nil
709 }
710 return string(ns.OrgRole), nil
711 }
712
713 type PrFileStatus string
714
715 const (
716 PrFileStatusAdded PrFileStatus = "added"
717 PrFileStatusModified PrFileStatus = "modified"
718 PrFileStatusDeleted PrFileStatus = "deleted"
719 PrFileStatusRenamed PrFileStatus = "renamed"
720 PrFileStatusCopied PrFileStatus = "copied"
721 )
722
723 func (e *PrFileStatus) Scan(src interface{}) error {
724 switch s := src.(type) {
725 case []byte:
726 *e = PrFileStatus(s)
727 case string:
728 *e = PrFileStatus(s)
729 default:
730 return fmt.Errorf("unsupported scan type for PrFileStatus: %T", src)
731 }
732 return nil
733 }
734
735 type NullPrFileStatus struct {
736 PrFileStatus PrFileStatus
737 Valid bool // Valid is true if PrFileStatus is not NULL
738 }
739
740 // Scan implements the Scanner interface.
741 func (ns *NullPrFileStatus) Scan(value interface{}) error {
742 if value == nil {
743 ns.PrFileStatus, ns.Valid = "", false
744 return nil
745 }
746 ns.Valid = true
747 return ns.PrFileStatus.Scan(value)
748 }
749
750 // Value implements the driver Valuer interface.
751 func (ns NullPrFileStatus) Value() (driver.Value, error) {
752 if !ns.Valid {
753 return nil, nil
754 }
755 return string(ns.PrFileStatus), nil
756 }
757
758 type PrMergeMethod string
759
760 const (
761 PrMergeMethodMerge PrMergeMethod = "merge"
762 PrMergeMethodSquash PrMergeMethod = "squash"
763 PrMergeMethodRebase PrMergeMethod = "rebase"
764 )
765
766 func (e *PrMergeMethod) Scan(src interface{}) error {
767 switch s := src.(type) {
768 case []byte:
769 *e = PrMergeMethod(s)
770 case string:
771 *e = PrMergeMethod(s)
772 default:
773 return fmt.Errorf("unsupported scan type for PrMergeMethod: %T", src)
774 }
775 return nil
776 }
777
778 type NullPrMergeMethod struct {
779 PrMergeMethod PrMergeMethod
780 Valid bool // Valid is true if PrMergeMethod is not NULL
781 }
782
783 // Scan implements the Scanner interface.
784 func (ns *NullPrMergeMethod) Scan(value interface{}) error {
785 if value == nil {
786 ns.PrMergeMethod, ns.Valid = "", false
787 return nil
788 }
789 ns.Valid = true
790 return ns.PrMergeMethod.Scan(value)
791 }
792
793 // Value implements the driver Valuer interface.
794 func (ns NullPrMergeMethod) Value() (driver.Value, error) {
795 if !ns.Valid {
796 return nil, nil
797 }
798 return string(ns.PrMergeMethod), nil
799 }
800
801 type PrMergeableState string
802
803 const (
804 PrMergeableStateUnknown PrMergeableState = "unknown"
805 PrMergeableStateClean PrMergeableState = "clean"
806 PrMergeableStateDirty PrMergeableState = "dirty"
807 PrMergeableStateBlocked PrMergeableState = "blocked"
808 PrMergeableStateBehind PrMergeableState = "behind"
809 )
810
811 func (e *PrMergeableState) Scan(src interface{}) error {
812 switch s := src.(type) {
813 case []byte:
814 *e = PrMergeableState(s)
815 case string:
816 *e = PrMergeableState(s)
817 default:
818 return fmt.Errorf("unsupported scan type for PrMergeableState: %T", src)
819 }
820 return nil
821 }
822
823 type NullPrMergeableState struct {
824 PrMergeableState PrMergeableState
825 Valid bool // Valid is true if PrMergeableState is not NULL
826 }
827
828 // Scan implements the Scanner interface.
829 func (ns *NullPrMergeableState) Scan(value interface{}) error {
830 if value == nil {
831 ns.PrMergeableState, ns.Valid = "", false
832 return nil
833 }
834 ns.Valid = true
835 return ns.PrMergeableState.Scan(value)
836 }
837
838 // Value implements the driver Valuer interface.
839 func (ns NullPrMergeableState) Value() (driver.Value, error) {
840 if !ns.Valid {
841 return nil, nil
842 }
843 return string(ns.PrMergeableState), nil
844 }
845
846 type PrReviewSide string
847
848 const (
849 PrReviewSideLeft PrReviewSide = "left"
850 PrReviewSideRight PrReviewSide = "right"
851 )
852
853 func (e *PrReviewSide) Scan(src interface{}) error {
854 switch s := src.(type) {
855 case []byte:
856 *e = PrReviewSide(s)
857 case string:
858 *e = PrReviewSide(s)
859 default:
860 return fmt.Errorf("unsupported scan type for PrReviewSide: %T", src)
861 }
862 return nil
863 }
864
865 type NullPrReviewSide struct {
866 PrReviewSide PrReviewSide
867 Valid bool // Valid is true if PrReviewSide is not NULL
868 }
869
870 // Scan implements the Scanner interface.
871 func (ns *NullPrReviewSide) Scan(value interface{}) error {
872 if value == nil {
873 ns.PrReviewSide, ns.Valid = "", false
874 return nil
875 }
876 ns.Valid = true
877 return ns.PrReviewSide.Scan(value)
878 }
879
880 // Value implements the driver Valuer interface.
881 func (ns NullPrReviewSide) Value() (driver.Value, error) {
882 if !ns.Valid {
883 return nil, nil
884 }
885 return string(ns.PrReviewSide), nil
886 }
887
888 type PrReviewState string
889
890 const (
891 PrReviewStateComment PrReviewState = "comment"
892 PrReviewStateApprove PrReviewState = "approve"
893 PrReviewStateRequestChanges PrReviewState = "request_changes"
894 )
895
896 func (e *PrReviewState) Scan(src interface{}) error {
897 switch s := src.(type) {
898 case []byte:
899 *e = PrReviewState(s)
900 case string:
901 *e = PrReviewState(s)
902 default:
903 return fmt.Errorf("unsupported scan type for PrReviewState: %T", src)
904 }
905 return nil
906 }
907
908 type NullPrReviewState struct {
909 PrReviewState PrReviewState
910 Valid bool // Valid is true if PrReviewState is not NULL
911 }
912
913 // Scan implements the Scanner interface.
914 func (ns *NullPrReviewState) Scan(value interface{}) error {
915 if value == nil {
916 ns.PrReviewState, ns.Valid = "", false
917 return nil
918 }
919 ns.Valid = true
920 return ns.PrReviewState.Scan(value)
921 }
922
923 // Value implements the driver Valuer interface.
924 func (ns NullPrReviewState) Value() (driver.Value, error) {
925 if !ns.Valid {
926 return nil, nil
927 }
928 return string(ns.PrReviewState), nil
929 }
930
931 type PrincipalKind string
932
933 const (
934 PrincipalKindUser PrincipalKind = "user"
935 PrincipalKindOrg PrincipalKind = "org"
936 )
937
938 func (e *PrincipalKind) Scan(src interface{}) error {
939 switch s := src.(type) {
940 case []byte:
941 *e = PrincipalKind(s)
942 case string:
943 *e = PrincipalKind(s)
944 default:
945 return fmt.Errorf("unsupported scan type for PrincipalKind: %T", src)
946 }
947 return nil
948 }
949
950 type NullPrincipalKind struct {
951 PrincipalKind PrincipalKind
952 Valid bool // Valid is true if PrincipalKind is not NULL
953 }
954
955 // Scan implements the Scanner interface.
956 func (ns *NullPrincipalKind) Scan(value interface{}) error {
957 if value == nil {
958 ns.PrincipalKind, ns.Valid = "", false
959 return nil
960 }
961 ns.Valid = true
962 return ns.PrincipalKind.Scan(value)
963 }
964
965 // Value implements the driver Valuer interface.
966 func (ns NullPrincipalKind) Value() (driver.Value, error) {
967 if !ns.Valid {
968 return nil, nil
969 }
970 return string(ns.PrincipalKind), nil
971 }
972
973 type RepoInitStatus string
974
975 const (
976 RepoInitStatusInitialized RepoInitStatus = "initialized"
977 RepoInitStatusInitPending RepoInitStatus = "init_pending"
978 RepoInitStatusInitFailed RepoInitStatus = "init_failed"
979 )
980
981 func (e *RepoInitStatus) Scan(src interface{}) error {
982 switch s := src.(type) {
983 case []byte:
984 *e = RepoInitStatus(s)
985 case string:
986 *e = RepoInitStatus(s)
987 default:
988 return fmt.Errorf("unsupported scan type for RepoInitStatus: %T", src)
989 }
990 return nil
991 }
992
993 type NullRepoInitStatus struct {
994 RepoInitStatus RepoInitStatus
995 Valid bool // Valid is true if RepoInitStatus is not NULL
996 }
997
998 // Scan implements the Scanner interface.
999 func (ns *NullRepoInitStatus) Scan(value interface{}) error {
1000 if value == nil {
1001 ns.RepoInitStatus, ns.Valid = "", false
1002 return nil
1003 }
1004 ns.Valid = true
1005 return ns.RepoInitStatus.Scan(value)
1006 }
1007
1008 // Value implements the driver Valuer interface.
1009 func (ns NullRepoInitStatus) Value() (driver.Value, error) {
1010 if !ns.Valid {
1011 return nil, nil
1012 }
1013 return string(ns.RepoInitStatus), nil
1014 }
1015
1016 type RepoVisibility string
1017
1018 const (
1019 RepoVisibilityPublic RepoVisibility = "public"
1020 RepoVisibilityPrivate RepoVisibility = "private"
1021 )
1022
1023 func (e *RepoVisibility) Scan(src interface{}) error {
1024 switch s := src.(type) {
1025 case []byte:
1026 *e = RepoVisibility(s)
1027 case string:
1028 *e = RepoVisibility(s)
1029 default:
1030 return fmt.Errorf("unsupported scan type for RepoVisibility: %T", src)
1031 }
1032 return nil
1033 }
1034
1035 type NullRepoVisibility struct {
1036 RepoVisibility RepoVisibility
1037 Valid bool // Valid is true if RepoVisibility is not NULL
1038 }
1039
1040 // Scan implements the Scanner interface.
1041 func (ns *NullRepoVisibility) Scan(value interface{}) error {
1042 if value == nil {
1043 ns.RepoVisibility, ns.Valid = "", false
1044 return nil
1045 }
1046 ns.Valid = true
1047 return ns.RepoVisibility.Scan(value)
1048 }
1049
1050 // Value implements the driver Valuer interface.
1051 func (ns NullRepoVisibility) Value() (driver.Value, error) {
1052 if !ns.Valid {
1053 return nil, nil
1054 }
1055 return string(ns.RepoVisibility), nil
1056 }
1057
1058 type TeamPrivacy string
1059
1060 const (
1061 TeamPrivacyVisible TeamPrivacy = "visible"
1062 TeamPrivacySecret TeamPrivacy = "secret"
1063 )
1064
1065 func (e *TeamPrivacy) Scan(src interface{}) error {
1066 switch s := src.(type) {
1067 case []byte:
1068 *e = TeamPrivacy(s)
1069 case string:
1070 *e = TeamPrivacy(s)
1071 default:
1072 return fmt.Errorf("unsupported scan type for TeamPrivacy: %T", src)
1073 }
1074 return nil
1075 }
1076
1077 type NullTeamPrivacy struct {
1078 TeamPrivacy TeamPrivacy
1079 Valid bool // Valid is true if TeamPrivacy is not NULL
1080 }
1081
1082 // Scan implements the Scanner interface.
1083 func (ns *NullTeamPrivacy) Scan(value interface{}) error {
1084 if value == nil {
1085 ns.TeamPrivacy, ns.Valid = "", false
1086 return nil
1087 }
1088 ns.Valid = true
1089 return ns.TeamPrivacy.Scan(value)
1090 }
1091
1092 // Value implements the driver Valuer interface.
1093 func (ns NullTeamPrivacy) Value() (driver.Value, error) {
1094 if !ns.Valid {
1095 return nil, nil
1096 }
1097 return string(ns.TeamPrivacy), nil
1098 }
1099
1100 type TeamRepoRole string
1101
1102 const (
1103 TeamRepoRoleRead TeamRepoRole = "read"
1104 TeamRepoRoleTriage TeamRepoRole = "triage"
1105 TeamRepoRoleWrite TeamRepoRole = "write"
1106 TeamRepoRoleMaintain TeamRepoRole = "maintain"
1107 TeamRepoRoleAdmin TeamRepoRole = "admin"
1108 )
1109
1110 func (e *TeamRepoRole) Scan(src interface{}) error {
1111 switch s := src.(type) {
1112 case []byte:
1113 *e = TeamRepoRole(s)
1114 case string:
1115 *e = TeamRepoRole(s)
1116 default:
1117 return fmt.Errorf("unsupported scan type for TeamRepoRole: %T", src)
1118 }
1119 return nil
1120 }
1121
1122 type NullTeamRepoRole struct {
1123 TeamRepoRole TeamRepoRole
1124 Valid bool // Valid is true if TeamRepoRole is not NULL
1125 }
1126
1127 // Scan implements the Scanner interface.
1128 func (ns *NullTeamRepoRole) Scan(value interface{}) error {
1129 if value == nil {
1130 ns.TeamRepoRole, ns.Valid = "", false
1131 return nil
1132 }
1133 ns.Valid = true
1134 return ns.TeamRepoRole.Scan(value)
1135 }
1136
1137 // Value implements the driver Valuer interface.
1138 func (ns NullTeamRepoRole) Value() (driver.Value, error) {
1139 if !ns.Valid {
1140 return nil, nil
1141 }
1142 return string(ns.TeamRepoRole), nil
1143 }
1144
1145 type TeamRole string
1146
1147 const (
1148 TeamRoleMember TeamRole = "member"
1149 TeamRoleMaintainer TeamRole = "maintainer"
1150 )
1151
1152 func (e *TeamRole) Scan(src interface{}) error {
1153 switch s := src.(type) {
1154 case []byte:
1155 *e = TeamRole(s)
1156 case string:
1157 *e = TeamRole(s)
1158 default:
1159 return fmt.Errorf("unsupported scan type for TeamRole: %T", src)
1160 }
1161 return nil
1162 }
1163
1164 type NullTeamRole struct {
1165 TeamRole TeamRole
1166 Valid bool // Valid is true if TeamRole is not NULL
1167 }
1168
1169 // Scan implements the Scanner interface.
1170 func (ns *NullTeamRole) Scan(value interface{}) error {
1171 if value == nil {
1172 ns.TeamRole, ns.Valid = "", false
1173 return nil
1174 }
1175 ns.Valid = true
1176 return ns.TeamRole.Scan(value)
1177 }
1178
1179 // Value implements the driver Valuer interface.
1180 func (ns NullTeamRole) Value() (driver.Value, error) {
1181 if !ns.Valid {
1182 return nil, nil
1183 }
1184 return string(ns.TeamRole), nil
1185 }
1186
1187 type TransactionalEmailStatus string
1188
1189 const (
1190 TransactionalEmailStatusQueued TransactionalEmailStatus = "queued"
1191 TransactionalEmailStatusSent TransactionalEmailStatus = "sent"
1192 TransactionalEmailStatusSoftBounced TransactionalEmailStatus = "soft_bounced"
1193 TransactionalEmailStatusHardBounced TransactionalEmailStatus = "hard_bounced"
1194 TransactionalEmailStatusDropped TransactionalEmailStatus = "dropped"
1195 )
1196
1197 func (e *TransactionalEmailStatus) Scan(src interface{}) error {
1198 switch s := src.(type) {
1199 case []byte:
1200 *e = TransactionalEmailStatus(s)
1201 case string:
1202 *e = TransactionalEmailStatus(s)
1203 default:
1204 return fmt.Errorf("unsupported scan type for TransactionalEmailStatus: %T", src)
1205 }
1206 return nil
1207 }
1208
1209 type NullTransactionalEmailStatus struct {
1210 TransactionalEmailStatus TransactionalEmailStatus
1211 Valid bool // Valid is true if TransactionalEmailStatus is not NULL
1212 }
1213
1214 // Scan implements the Scanner interface.
1215 func (ns *NullTransactionalEmailStatus) Scan(value interface{}) error {
1216 if value == nil {
1217 ns.TransactionalEmailStatus, ns.Valid = "", false
1218 return nil
1219 }
1220 ns.Valid = true
1221 return ns.TransactionalEmailStatus.Scan(value)
1222 }
1223
1224 // Value implements the driver Valuer interface.
1225 func (ns NullTransactionalEmailStatus) Value() (driver.Value, error) {
1226 if !ns.Valid {
1227 return nil, nil
1228 }
1229 return string(ns.TransactionalEmailStatus), nil
1230 }
1231
1232 type TransferPrincipalKind string
1233
1234 const (
1235 TransferPrincipalKindUser TransferPrincipalKind = "user"
1236 TransferPrincipalKindOrg TransferPrincipalKind = "org"
1237 )
1238
1239 func (e *TransferPrincipalKind) Scan(src interface{}) error {
1240 switch s := src.(type) {
1241 case []byte:
1242 *e = TransferPrincipalKind(s)
1243 case string:
1244 *e = TransferPrincipalKind(s)
1245 default:
1246 return fmt.Errorf("unsupported scan type for TransferPrincipalKind: %T", src)
1247 }
1248 return nil
1249 }
1250
1251 type NullTransferPrincipalKind struct {
1252 TransferPrincipalKind TransferPrincipalKind
1253 Valid bool // Valid is true if TransferPrincipalKind is not NULL
1254 }
1255
1256 // Scan implements the Scanner interface.
1257 func (ns *NullTransferPrincipalKind) Scan(value interface{}) error {
1258 if value == nil {
1259 ns.TransferPrincipalKind, ns.Valid = "", false
1260 return nil
1261 }
1262 ns.Valid = true
1263 return ns.TransferPrincipalKind.Scan(value)
1264 }
1265
1266 // Value implements the driver Valuer interface.
1267 func (ns NullTransferPrincipalKind) Value() (driver.Value, error) {
1268 if !ns.Valid {
1269 return nil, nil
1270 }
1271 return string(ns.TransferPrincipalKind), nil
1272 }
1273
1274 type TransferStatus string
1275
1276 const (
1277 TransferStatusPending TransferStatus = "pending"
1278 TransferStatusAccepted TransferStatus = "accepted"
1279 TransferStatusDeclined TransferStatus = "declined"
1280 TransferStatusCanceled TransferStatus = "canceled"
1281 TransferStatusExpired TransferStatus = "expired"
1282 )
1283
1284 func (e *TransferStatus) Scan(src interface{}) error {
1285 switch s := src.(type) {
1286 case []byte:
1287 *e = TransferStatus(s)
1288 case string:
1289 *e = TransferStatus(s)
1290 default:
1291 return fmt.Errorf("unsupported scan type for TransferStatus: %T", src)
1292 }
1293 return nil
1294 }
1295
1296 type NullTransferStatus struct {
1297 TransferStatus TransferStatus
1298 Valid bool // Valid is true if TransferStatus is not NULL
1299 }
1300
1301 // Scan implements the Scanner interface.
1302 func (ns *NullTransferStatus) Scan(value interface{}) error {
1303 if value == nil {
1304 ns.TransferStatus, ns.Valid = "", false
1305 return nil
1306 }
1307 ns.Valid = true
1308 return ns.TransferStatus.Scan(value)
1309 }
1310
1311 // Value implements the driver Valuer interface.
1312 func (ns NullTransferStatus) Value() (driver.Value, error) {
1313 if !ns.Valid {
1314 return nil, nil
1315 }
1316 return string(ns.TransferStatus), nil
1317 }
1318
1319 type TrendingKind string
1320
1321 const (
1322 TrendingKindRepos TrendingKind = "repos"
1323 TrendingKindUsers TrendingKind = "users"
1324 )
1325
1326 func (e *TrendingKind) Scan(src interface{}) error {
1327 switch s := src.(type) {
1328 case []byte:
1329 *e = TrendingKind(s)
1330 case string:
1331 *e = TrendingKind(s)
1332 default:
1333 return fmt.Errorf("unsupported scan type for TrendingKind: %T", src)
1334 }
1335 return nil
1336 }
1337
1338 type NullTrendingKind struct {
1339 TrendingKind TrendingKind
1340 Valid bool // Valid is true if TrendingKind is not NULL
1341 }
1342
1343 // Scan implements the Scanner interface.
1344 func (ns *NullTrendingKind) Scan(value interface{}) error {
1345 if value == nil {
1346 ns.TrendingKind, ns.Valid = "", false
1347 return nil
1348 }
1349 ns.Valid = true
1350 return ns.TrendingKind.Scan(value)
1351 }
1352
1353 // Value implements the driver Valuer interface.
1354 func (ns NullTrendingKind) Value() (driver.Value, error) {
1355 if !ns.Valid {
1356 return nil, nil
1357 }
1358 return string(ns.TrendingKind), nil
1359 }
1360
1361 type TrendingScope string
1362
1363 const (
1364 TrendingScopeDay TrendingScope = "day"
1365 TrendingScopeWeek TrendingScope = "week"
1366 TrendingScopeMonth TrendingScope = "month"
1367 )
1368
1369 func (e *TrendingScope) Scan(src interface{}) error {
1370 switch s := src.(type) {
1371 case []byte:
1372 *e = TrendingScope(s)
1373 case string:
1374 *e = TrendingScope(s)
1375 default:
1376 return fmt.Errorf("unsupported scan type for TrendingScope: %T", src)
1377 }
1378 return nil
1379 }
1380
1381 type NullTrendingScope struct {
1382 TrendingScope TrendingScope
1383 Valid bool // Valid is true if TrendingScope is not NULL
1384 }
1385
1386 // Scan implements the Scanner interface.
1387 func (ns *NullTrendingScope) Scan(value interface{}) error {
1388 if value == nil {
1389 ns.TrendingScope, ns.Valid = "", false
1390 return nil
1391 }
1392 ns.Valid = true
1393 return ns.TrendingScope.Scan(value)
1394 }
1395
1396 // Value implements the driver Valuer interface.
1397 func (ns NullTrendingScope) Value() (driver.Value, error) {
1398 if !ns.Valid {
1399 return nil, nil
1400 }
1401 return string(ns.TrendingScope), nil
1402 }
1403
1404 type WatchLevel string
1405
1406 const (
1407 WatchLevelAll WatchLevel = "all"
1408 WatchLevelParticipating WatchLevel = "participating"
1409 WatchLevelIgnore WatchLevel = "ignore"
1410 )
1411
1412 func (e *WatchLevel) Scan(src interface{}) error {
1413 switch s := src.(type) {
1414 case []byte:
1415 *e = WatchLevel(s)
1416 case string:
1417 *e = WatchLevel(s)
1418 default:
1419 return fmt.Errorf("unsupported scan type for WatchLevel: %T", src)
1420 }
1421 return nil
1422 }
1423
1424 type NullWatchLevel struct {
1425 WatchLevel WatchLevel
1426 Valid bool // Valid is true if WatchLevel is not NULL
1427 }
1428
1429 // Scan implements the Scanner interface.
1430 func (ns *NullWatchLevel) Scan(value interface{}) error {
1431 if value == nil {
1432 ns.WatchLevel, ns.Valid = "", false
1433 return nil
1434 }
1435 ns.Valid = true
1436 return ns.WatchLevel.Scan(value)
1437 }
1438
1439 // Value implements the driver Valuer interface.
1440 func (ns NullWatchLevel) Value() (driver.Value, error) {
1441 if !ns.Valid {
1442 return nil, nil
1443 }
1444 return string(ns.WatchLevel), nil
1445 }
1446
1447 type WebhookContentType string
1448
1449 const (
1450 WebhookContentTypeJson WebhookContentType = "json"
1451 WebhookContentTypeForm WebhookContentType = "form"
1452 )
1453
1454 func (e *WebhookContentType) Scan(src interface{}) error {
1455 switch s := src.(type) {
1456 case []byte:
1457 *e = WebhookContentType(s)
1458 case string:
1459 *e = WebhookContentType(s)
1460 default:
1461 return fmt.Errorf("unsupported scan type for WebhookContentType: %T", src)
1462 }
1463 return nil
1464 }
1465
1466 type NullWebhookContentType struct {
1467 WebhookContentType WebhookContentType
1468 Valid bool // Valid is true if WebhookContentType is not NULL
1469 }
1470
1471 // Scan implements the Scanner interface.
1472 func (ns *NullWebhookContentType) Scan(value interface{}) error {
1473 if value == nil {
1474 ns.WebhookContentType, ns.Valid = "", false
1475 return nil
1476 }
1477 ns.Valid = true
1478 return ns.WebhookContentType.Scan(value)
1479 }
1480
1481 // Value implements the driver Valuer interface.
1482 func (ns NullWebhookContentType) Value() (driver.Value, error) {
1483 if !ns.Valid {
1484 return nil, nil
1485 }
1486 return string(ns.WebhookContentType), nil
1487 }
1488
1489 type WebhookDeliveryStatus string
1490
1491 const (
1492 WebhookDeliveryStatusPending WebhookDeliveryStatus = "pending"
1493 WebhookDeliveryStatusSucceeded WebhookDeliveryStatus = "succeeded"
1494 WebhookDeliveryStatusFailedRetry WebhookDeliveryStatus = "failed_retry"
1495 WebhookDeliveryStatusFailedPermanent WebhookDeliveryStatus = "failed_permanent"
1496 )
1497
1498 func (e *WebhookDeliveryStatus) Scan(src interface{}) error {
1499 switch s := src.(type) {
1500 case []byte:
1501 *e = WebhookDeliveryStatus(s)
1502 case string:
1503 *e = WebhookDeliveryStatus(s)
1504 default:
1505 return fmt.Errorf("unsupported scan type for WebhookDeliveryStatus: %T", src)
1506 }
1507 return nil
1508 }
1509
1510 type NullWebhookDeliveryStatus struct {
1511 WebhookDeliveryStatus WebhookDeliveryStatus
1512 Valid bool // Valid is true if WebhookDeliveryStatus is not NULL
1513 }
1514
1515 // Scan implements the Scanner interface.
1516 func (ns *NullWebhookDeliveryStatus) Scan(value interface{}) error {
1517 if value == nil {
1518 ns.WebhookDeliveryStatus, ns.Valid = "", false
1519 return nil
1520 }
1521 ns.Valid = true
1522 return ns.WebhookDeliveryStatus.Scan(value)
1523 }
1524
1525 // Value implements the driver Valuer interface.
1526 func (ns NullWebhookDeliveryStatus) Value() (driver.Value, error) {
1527 if !ns.Valid {
1528 return nil, nil
1529 }
1530 return string(ns.WebhookDeliveryStatus), nil
1531 }
1532
1533 type WebhookOwnerKind string
1534
1535 const (
1536 WebhookOwnerKindRepo WebhookOwnerKind = "repo"
1537 WebhookOwnerKindOrg WebhookOwnerKind = "org"
1538 )
1539
1540 func (e *WebhookOwnerKind) Scan(src interface{}) error {
1541 switch s := src.(type) {
1542 case []byte:
1543 *e = WebhookOwnerKind(s)
1544 case string:
1545 *e = WebhookOwnerKind(s)
1546 default:
1547 return fmt.Errorf("unsupported scan type for WebhookOwnerKind: %T", src)
1548 }
1549 return nil
1550 }
1551
1552 type NullWebhookOwnerKind struct {
1553 WebhookOwnerKind WebhookOwnerKind
1554 Valid bool // Valid is true if WebhookOwnerKind is not NULL
1555 }
1556
1557 // Scan implements the Scanner interface.
1558 func (ns *NullWebhookOwnerKind) Scan(value interface{}) error {
1559 if value == nil {
1560 ns.WebhookOwnerKind, ns.Valid = "", false
1561 return nil
1562 }
1563 ns.Valid = true
1564 return ns.WebhookOwnerKind.Scan(value)
1565 }
1566
1567 // Value implements the driver Valuer interface.
1568 func (ns NullWebhookOwnerKind) Value() (driver.Value, error) {
1569 if !ns.Valid {
1570 return nil, nil
1571 }
1572 return string(ns.WebhookOwnerKind), nil
1573 }
1574
1575 type WorkflowJobStatus string
1576
1577 const (
1578 WorkflowJobStatusQueued WorkflowJobStatus = "queued"
1579 WorkflowJobStatusRunning WorkflowJobStatus = "running"
1580 WorkflowJobStatusCompleted WorkflowJobStatus = "completed"
1581 WorkflowJobStatusCancelled WorkflowJobStatus = "cancelled"
1582 WorkflowJobStatusSkipped WorkflowJobStatus = "skipped"
1583 )
1584
1585 func (e *WorkflowJobStatus) Scan(src interface{}) error {
1586 switch s := src.(type) {
1587 case []byte:
1588 *e = WorkflowJobStatus(s)
1589 case string:
1590 *e = WorkflowJobStatus(s)
1591 default:
1592 return fmt.Errorf("unsupported scan type for WorkflowJobStatus: %T", src)
1593 }
1594 return nil
1595 }
1596
1597 type NullWorkflowJobStatus struct {
1598 WorkflowJobStatus WorkflowJobStatus
1599 Valid bool // Valid is true if WorkflowJobStatus is not NULL
1600 }
1601
1602 // Scan implements the Scanner interface.
1603 func (ns *NullWorkflowJobStatus) Scan(value interface{}) error {
1604 if value == nil {
1605 ns.WorkflowJobStatus, ns.Valid = "", false
1606 return nil
1607 }
1608 ns.Valid = true
1609 return ns.WorkflowJobStatus.Scan(value)
1610 }
1611
1612 // Value implements the driver Valuer interface.
1613 func (ns NullWorkflowJobStatus) Value() (driver.Value, error) {
1614 if !ns.Valid {
1615 return nil, nil
1616 }
1617 return string(ns.WorkflowJobStatus), nil
1618 }
1619
1620 type WorkflowRunEvent string
1621
1622 const (
1623 WorkflowRunEventPush WorkflowRunEvent = "push"
1624 WorkflowRunEventPullRequest WorkflowRunEvent = "pull_request"
1625 WorkflowRunEventSchedule WorkflowRunEvent = "schedule"
1626 WorkflowRunEventWorkflowDispatch WorkflowRunEvent = "workflow_dispatch"
1627 )
1628
1629 func (e *WorkflowRunEvent) Scan(src interface{}) error {
1630 switch s := src.(type) {
1631 case []byte:
1632 *e = WorkflowRunEvent(s)
1633 case string:
1634 *e = WorkflowRunEvent(s)
1635 default:
1636 return fmt.Errorf("unsupported scan type for WorkflowRunEvent: %T", src)
1637 }
1638 return nil
1639 }
1640
1641 type NullWorkflowRunEvent struct {
1642 WorkflowRunEvent WorkflowRunEvent
1643 Valid bool // Valid is true if WorkflowRunEvent is not NULL
1644 }
1645
1646 // Scan implements the Scanner interface.
1647 func (ns *NullWorkflowRunEvent) Scan(value interface{}) error {
1648 if value == nil {
1649 ns.WorkflowRunEvent, ns.Valid = "", false
1650 return nil
1651 }
1652 ns.Valid = true
1653 return ns.WorkflowRunEvent.Scan(value)
1654 }
1655
1656 // Value implements the driver Valuer interface.
1657 func (ns NullWorkflowRunEvent) Value() (driver.Value, error) {
1658 if !ns.Valid {
1659 return nil, nil
1660 }
1661 return string(ns.WorkflowRunEvent), nil
1662 }
1663
1664 type WorkflowRunStatus string
1665
1666 const (
1667 WorkflowRunStatusQueued WorkflowRunStatus = "queued"
1668 WorkflowRunStatusRunning WorkflowRunStatus = "running"
1669 WorkflowRunStatusCompleted WorkflowRunStatus = "completed"
1670 WorkflowRunStatusCancelled WorkflowRunStatus = "cancelled"
1671 )
1672
1673 func (e *WorkflowRunStatus) Scan(src interface{}) error {
1674 switch s := src.(type) {
1675 case []byte:
1676 *e = WorkflowRunStatus(s)
1677 case string:
1678 *e = WorkflowRunStatus(s)
1679 default:
1680 return fmt.Errorf("unsupported scan type for WorkflowRunStatus: %T", src)
1681 }
1682 return nil
1683 }
1684
1685 type NullWorkflowRunStatus struct {
1686 WorkflowRunStatus WorkflowRunStatus
1687 Valid bool // Valid is true if WorkflowRunStatus is not NULL
1688 }
1689
1690 // Scan implements the Scanner interface.
1691 func (ns *NullWorkflowRunStatus) Scan(value interface{}) error {
1692 if value == nil {
1693 ns.WorkflowRunStatus, ns.Valid = "", false
1694 return nil
1695 }
1696 ns.Valid = true
1697 return ns.WorkflowRunStatus.Scan(value)
1698 }
1699
1700 // Value implements the driver Valuer interface.
1701 func (ns NullWorkflowRunStatus) Value() (driver.Value, error) {
1702 if !ns.Valid {
1703 return nil, nil
1704 }
1705 return string(ns.WorkflowRunStatus), nil
1706 }
1707
1708 type WorkflowRunnerStatus string
1709
1710 const (
1711 WorkflowRunnerStatusIdle WorkflowRunnerStatus = "idle"
1712 WorkflowRunnerStatusBusy WorkflowRunnerStatus = "busy"
1713 WorkflowRunnerStatusOffline WorkflowRunnerStatus = "offline"
1714 )
1715
1716 func (e *WorkflowRunnerStatus) Scan(src interface{}) error {
1717 switch s := src.(type) {
1718 case []byte:
1719 *e = WorkflowRunnerStatus(s)
1720 case string:
1721 *e = WorkflowRunnerStatus(s)
1722 default:
1723 return fmt.Errorf("unsupported scan type for WorkflowRunnerStatus: %T", src)
1724 }
1725 return nil
1726 }
1727
1728 type NullWorkflowRunnerStatus struct {
1729 WorkflowRunnerStatus WorkflowRunnerStatus
1730 Valid bool // Valid is true if WorkflowRunnerStatus is not NULL
1731 }
1732
1733 // Scan implements the Scanner interface.
1734 func (ns *NullWorkflowRunnerStatus) Scan(value interface{}) error {
1735 if value == nil {
1736 ns.WorkflowRunnerStatus, ns.Valid = "", false
1737 return nil
1738 }
1739 ns.Valid = true
1740 return ns.WorkflowRunnerStatus.Scan(value)
1741 }
1742
1743 // Value implements the driver Valuer interface.
1744 func (ns NullWorkflowRunnerStatus) Value() (driver.Value, error) {
1745 if !ns.Valid {
1746 return nil, nil
1747 }
1748 return string(ns.WorkflowRunnerStatus), nil
1749 }
1750
1751 type WorkflowStepStatus string
1752
1753 const (
1754 WorkflowStepStatusQueued WorkflowStepStatus = "queued"
1755 WorkflowStepStatusRunning WorkflowStepStatus = "running"
1756 WorkflowStepStatusCompleted WorkflowStepStatus = "completed"
1757 WorkflowStepStatusCancelled WorkflowStepStatus = "cancelled"
1758 WorkflowStepStatusSkipped WorkflowStepStatus = "skipped"
1759 )
1760
1761 func (e *WorkflowStepStatus) Scan(src interface{}) error {
1762 switch s := src.(type) {
1763 case []byte:
1764 *e = WorkflowStepStatus(s)
1765 case string:
1766 *e = WorkflowStepStatus(s)
1767 default:
1768 return fmt.Errorf("unsupported scan type for WorkflowStepStatus: %T", src)
1769 }
1770 return nil
1771 }
1772
1773 type NullWorkflowStepStatus struct {
1774 WorkflowStepStatus WorkflowStepStatus
1775 Valid bool // Valid is true if WorkflowStepStatus is not NULL
1776 }
1777
1778 // Scan implements the Scanner interface.
1779 func (ns *NullWorkflowStepStatus) Scan(value interface{}) error {
1780 if value == nil {
1781 ns.WorkflowStepStatus, ns.Valid = "", false
1782 return nil
1783 }
1784 ns.Valid = true
1785 return ns.WorkflowStepStatus.Scan(value)
1786 }
1787
1788 // Value implements the driver Valuer interface.
1789 func (ns NullWorkflowStepStatus) Value() (driver.Value, error) {
1790 if !ns.Valid {
1791 return nil, nil
1792 }
1793 return string(ns.WorkflowStepStatus), nil
1794 }
1795
1796 type ActionsOrgPolicy struct {
1797 OrgID int64
1798 ActionsEnabled ActionsPolicyState
1799 RequirePrApproval pgtype.Bool
1800 MaxRepoQueuedRuns pgtype.Int4
1801 MaxRepoConcurrentJobs pgtype.Int4
1802 MaxOwnerConcurrentJobs pgtype.Int4
1803 ActorTriggerLimitPerHour pgtype.Int4
1804 UpdatedByUserID pgtype.Int8
1805 CreatedAt pgtype.Timestamptz
1806 UpdatedAt pgtype.Timestamptz
1807 }
1808
1809 type ActionsRepoPolicy struct {
1810 RepoID int64
1811 ActionsEnabled ActionsPolicyState
1812 RequirePrApproval pgtype.Bool
1813 MaxRepoQueuedRuns pgtype.Int4
1814 MaxRepoConcurrentJobs pgtype.Int4
1815 MaxOwnerConcurrentJobs pgtype.Int4
1816 ActorTriggerLimitPerHour pgtype.Int4
1817 UpdatedByUserID pgtype.Int8
1818 CreatedAt pgtype.Timestamptz
1819 UpdatedAt pgtype.Timestamptz
1820 }
1821
1822 type ActionsSitePolicy struct {
1823 ID bool
1824 ActionsEnabled bool
1825 RequirePrApproval bool
1826 MaxRepoQueuedRuns int32
1827 MaxRepoConcurrentJobs int32
1828 MaxOwnerConcurrentJobs int32
1829 ActorTriggerLimitPerHour int32
1830 UpdatedByUserID pgtype.Int8
1831 CreatedAt pgtype.Timestamptz
1832 UpdatedAt pgtype.Timestamptz
1833 }
1834
1835 type ActionsVariable struct {
1836 ID int64
1837 RepoID pgtype.Int8
1838 OrgID pgtype.Int8
1839 Name string
1840 Value string
1841 CreatedByUserID pgtype.Int8
1842 CreatedAt pgtype.Timestamptz
1843 UpdatedAt pgtype.Timestamptz
1844 }
1845
1846 type AuthAuditLog struct {
1847 ID int64
1848 ActorID pgtype.Int8
1849 Action string
1850 TargetType string
1851 TargetID pgtype.Int8
1852 Meta []byte
1853 CreatedAt pgtype.Timestamptz
1854 }
1855
1856 type AuthThrottle struct {
1857 ID int64
1858 Scope string
1859 Identifier string
1860 Hits int32
1861 WindowStartedAt pgtype.Timestamptz
1862 }
1863
1864 type BillingInvoice struct {
1865 ID int64
1866 OrgID int64
1867 Provider BillingProvider
1868 StripeInvoiceID string
1869 StripeCustomerID string
1870 StripeSubscriptionID pgtype.Text
1871 Status BillingInvoiceStatus
1872 Number string
1873 Currency string
1874 AmountDueCents int64
1875 AmountPaidCents int64
1876 AmountRemainingCents int64
1877 HostedInvoiceUrl string
1878 InvoicePdfUrl string
1879 PeriodStart pgtype.Timestamptz
1880 PeriodEnd pgtype.Timestamptz
1881 DueAt pgtype.Timestamptz
1882 PaidAt pgtype.Timestamptz
1883 VoidedAt pgtype.Timestamptz
1884 CreatedAt pgtype.Timestamptz
1885 UpdatedAt pgtype.Timestamptz
1886 }
1887
1888 type BillingSeatSnapshot struct {
1889 ID int64
1890 OrgID int64
1891 Provider BillingProvider
1892 StripeSubscriptionID pgtype.Text
1893 ActiveMembers int32
1894 BillableSeats int32
1895 Source string
1896 CapturedAt pgtype.Timestamptz
1897 }
1898
1899 type BillingWebhookEvent struct {
1900 ID int64
1901 Provider BillingProvider
1902 ProviderEventID string
1903 EventType string
1904 ApiVersion string
1905 Payload []byte
1906 ReceivedAt pgtype.Timestamptz
1907 ProcessedAt pgtype.Timestamptz
1908 ProcessError string
1909 ProcessingAttempts int32
1910 }
1911
1912 type BranchProtectionRule struct {
1913 ID int64
1914 RepoID int64
1915 Pattern string
1916 PreventForcePush bool
1917 PreventDeletion bool
1918 RequirePrForPush bool
1919 AllowedPusherUserIds []int64
1920 RequireSignedCommits bool
1921 StatusChecksRequired []string
1922 CreatedAt pgtype.Timestamptz
1923 UpdatedAt pgtype.Timestamptz
1924 CreatedByUserID pgtype.Int8
1925 RequiredReviewCount int32
1926 DismissStaleReviewsOnPush bool
1927 RequireCodeOwnerReview bool
1928 DismissStaleStatusChecksOnPush bool
1929 }
1930
1931 type CheckRun struct {
1932 ID int64
1933 SuiteID int64
1934 RepoID int64
1935 HeadSha string
1936 Name string
1937 Status CheckStatus
1938 Conclusion NullCheckConclusion
1939 StartedAt pgtype.Timestamptz
1940 CompletedAt pgtype.Timestamptz
1941 DetailsUrl string
1942 Output []byte
1943 ExternalID pgtype.Text
1944 CreatedAt pgtype.Timestamptz
1945 UpdatedAt pgtype.Timestamptz
1946 }
1947
1948 type CheckSuite struct {
1949 ID int64
1950 RepoID int64
1951 HeadSha string
1952 AppSlug string
1953 Status CheckStatus
1954 Conclusion NullCheckConclusion
1955 CreatedAt pgtype.Timestamptz
1956 UpdatedAt pgtype.Timestamptz
1957 }
1958
1959 type CodeSearchContent struct {
1960 RepoID int64
1961 RefName string
1962 Path string
1963 ContentTsv interface{}
1964 ContentTrgm string
1965 }
1966
1967 type CodeSearchPath struct {
1968 RepoID int64
1969 RefName string
1970 Path string
1971 Tsv interface{}
1972 }
1973
1974 type CommitVerificationCache struct {
1975 RepoID int64
1976 CommitOid string
1977 Reason string
1978 Verified bool
1979 SignerUserID pgtype.Int8
1980 SignerSubkeyID pgtype.Int8
1981 Kind string
1982 SignatureArmored pgtype.Text
1983 Payload []byte
1984 VerifiedAt pgtype.Timestamptz
1985 InvalidatedAt pgtype.Timestamptz
1986 }
1987
1988 type DeviceAuthorization struct {
1989 ID int64
1990 DeviceCodeHash []byte
1991 UserCode string
1992 ClientID string
1993 Scopes []string
1994 UserID pgtype.Int8
1995 ApprovedAt pgtype.Timestamptz
1996 DeniedAt pgtype.Timestamptz
1997 IssuedTokenID pgtype.Int8
1998 IntervalSeconds int32
1999 ExpiresAt pgtype.Timestamptz
2000 LastPolledAt pgtype.Timestamptz
2001 CreatedAt pgtype.Timestamptz
2002 }
2003
2004 type DomainEvent struct {
2005 ID int64
2006 ActorUserID pgtype.Int8
2007 Kind string
2008 RepoID pgtype.Int8
2009 SourceKind string
2010 SourceID int64
2011 Public bool
2012 Payload []byte
2013 CreatedAt pgtype.Timestamptz
2014 }
2015
2016 type DomainEventsProcessed struct {
2017 Consumer string
2018 LastEventID int64
2019 UpdatedAt pgtype.Timestamptz
2020 }
2021
2022 type EmailVerification struct {
2023 ID int64
2024 UserEmailID int64
2025 TokenHash []byte
2026 ExpiresAt pgtype.Timestamptz
2027 UsedAt pgtype.Timestamptz
2028 CreatedAt pgtype.Timestamptz
2029 }
2030
2031 type Follow struct {
2032 ID int64
2033 FollowerUserID int64
2034 FolloweeUserID pgtype.Int8
2035 FolloweeOrgID pgtype.Int8
2036 FollowedAt pgtype.Timestamptz
2037 }
2038
2039 type Issue struct {
2040 ID int64
2041 RepoID int64
2042 Number int64
2043 Kind IssueKind
2044 Title string
2045 Body string
2046 BodyHtmlCached pgtype.Text
2047 MdPipelineVersion int32
2048 AuthorUserID pgtype.Int8
2049 State IssueState
2050 StateReason NullIssueStateReason
2051 Locked bool
2052 LockReason pgtype.Text
2053 MilestoneID pgtype.Int8
2054 CreatedAt pgtype.Timestamptz
2055 UpdatedAt pgtype.Timestamptz
2056 EditedAt pgtype.Timestamptz
2057 ClosedAt pgtype.Timestamptz
2058 ClosedByUserID pgtype.Int8
2059 }
2060
2061 type IssueAssignee struct {
2062 IssueID int64
2063 UserID int64
2064 AssignedAt pgtype.Timestamptz
2065 AssignedByUserID pgtype.Int8
2066 }
2067
2068 type IssueComment struct {
2069 ID int64
2070 IssueID int64
2071 AuthorUserID pgtype.Int8
2072 Body string
2073 BodyHtmlCached pgtype.Text
2074 MdPipelineVersion int32
2075 CreatedAt pgtype.Timestamptz
2076 UpdatedAt pgtype.Timestamptz
2077 EditedAt pgtype.Timestamptz
2078 }
2079
2080 type IssueEvent struct {
2081 ID int64
2082 IssueID int64
2083 ActorUserID pgtype.Int8
2084 Kind string
2085 Meta []byte
2086 RefTargetID pgtype.Int8
2087 CreatedAt pgtype.Timestamptz
2088 }
2089
2090 type IssueLabel struct {
2091 IssueID int64
2092 LabelID int64
2093 AppliedAt pgtype.Timestamptz
2094 AppliedByUserID pgtype.Int8
2095 }
2096
2097 type IssueReference struct {
2098 ID int64
2099 SourceIssueID pgtype.Int8
2100 TargetIssueID int64
2101 SourceKind IssueRefSource
2102 SourceObjectID pgtype.Int8
2103 CreatedAt pgtype.Timestamptz
2104 }
2105
2106 type IssuesSearch struct {
2107 IssueID int64
2108 RepoID int64
2109 Kind IssueKind
2110 State IssueState
2111 AuthorUserID pgtype.Int8
2112 Tsv interface{}
2113 }
2114
2115 type Job struct {
2116 ID int64
2117 Kind string
2118 Payload []byte
2119 RunAt pgtype.Timestamptz
2120 Attempts int32
2121 MaxAttempts int32
2122 LastError pgtype.Text
2123 LockedBy pgtype.Text
2124 LockedAt pgtype.Timestamptz
2125 CompletedAt pgtype.Timestamptz
2126 FailedAt pgtype.Timestamptz
2127 CreatedAt pgtype.Timestamptz
2128 }
2129
2130 type Label struct {
2131 ID int64
2132 RepoID int64
2133 Name string
2134 Color string
2135 Description string
2136 CreatedAt pgtype.Timestamptz
2137 }
2138
2139 type Meta struct {
2140 Key string
2141 Value []byte
2142 UpdatedAt pgtype.Timestamptz
2143 }
2144
2145 type Milestone struct {
2146 ID int64
2147 RepoID int64
2148 Title string
2149 Description string
2150 State MilestoneState
2151 DueOn pgtype.Timestamptz
2152 CreatedAt pgtype.Timestamptz
2153 ClosedAt pgtype.Timestamptz
2154 }
2155
2156 type Notification struct {
2157 ID int64
2158 RecipientUserID int64
2159 Kind string
2160 Reason string
2161 RepoID pgtype.Int8
2162 ThreadKind NullNotificationThreadKind
2163 ThreadID pgtype.Int8
2164 SourceEventID pgtype.Int8
2165 Unread bool
2166 LastEventAt pgtype.Timestamptz
2167 LastActorUserID pgtype.Int8
2168 Summary []byte
2169 CreatedAt pgtype.Timestamptz
2170 UpdatedAt pgtype.Timestamptz
2171 }
2172
2173 type NotificationEmailLog struct {
2174 ID int64
2175 RecipientUserID int64
2176 NotificationID pgtype.Int8
2177 ThreadKind NullNotificationThreadKind
2178 ThreadID pgtype.Int8
2179 SentAt pgtype.Timestamptz
2180 MessageID pgtype.Text
2181 }
2182
2183 type NotificationThread struct {
2184 RecipientUserID int64
2185 ThreadKind NotificationThreadKind
2186 ThreadID int64
2187 Subscribed bool
2188 Reason string
2189 UpdatedAt pgtype.Timestamptz
2190 }
2191
2192 type Org struct {
2193 ID int64
2194 Slug string
2195 DisplayName string
2196 Description string
2197 AvatarObjectKey pgtype.Text
2198 Location string
2199 Website string
2200 BillingEmail string
2201 Plan OrgPlan
2202 AllowMemberRepoCreate bool
2203 CreatedByUserID pgtype.Int8
2204 SuspendedAt pgtype.Timestamptz
2205 SuspendedReason pgtype.Text
2206 DeletedAt pgtype.Timestamptz
2207 CreatedAt pgtype.Timestamptz
2208 UpdatedAt pgtype.Timestamptz
2209 }
2210
2211 type OrgBillingState struct {
2212 OrgID int64
2213 Provider BillingProvider
2214 StripeCustomerID pgtype.Text
2215 StripeSubscriptionID pgtype.Text
2216 StripeSubscriptionItemID pgtype.Text
2217 Plan OrgPlan
2218 SubscriptionStatus BillingSubscriptionStatus
2219 BillableSeats int32
2220 SeatSnapshotAt pgtype.Timestamptz
2221 CurrentPeriodStart pgtype.Timestamptz
2222 CurrentPeriodEnd pgtype.Timestamptz
2223 CancelAtPeriodEnd bool
2224 TrialEnd pgtype.Timestamptz
2225 PastDueAt pgtype.Timestamptz
2226 CanceledAt pgtype.Timestamptz
2227 LockedAt pgtype.Timestamptz
2228 LockReason NullBillingLockReason
2229 GraceUntil pgtype.Timestamptz
2230 LastWebhookEventID string
2231 CreatedAt pgtype.Timestamptz
2232 UpdatedAt pgtype.Timestamptz
2233 }
2234
2235 type OrgGithubImport struct {
2236 ID int64
2237 OrgID int64
2238 SourceHost string
2239 SourceOrg string
2240 RequestedByUserID pgtype.Int8
2241 Status string
2242 IncludePrivate bool
2243 TokenPresent bool
2244 TokenCiphertext []byte
2245 TokenNonce []byte
2246 TotalCount int32
2247 LastError pgtype.Text
2248 StartedAt pgtype.Timestamptz
2249 CompletedAt pgtype.Timestamptz
2250 CreatedAt pgtype.Timestamptz
2251 UpdatedAt pgtype.Timestamptz
2252 }
2253
2254 type OrgGithubImportRepo struct {
2255 ID int64
2256 ImportID int64
2257 GithubID pgtype.Int8
2258 SourceFullName string
2259 SourceName string
2260 TargetName string
2261 CloneUrl string
2262 Description string
2263 DefaultBranch string
2264 TargetVisibility RepoVisibility
2265 IsPrivate bool
2266 IsFork bool
2267 Status string
2268 RepoID pgtype.Int8
2269 LastError pgtype.Text
2270 StartedAt pgtype.Timestamptz
2271 CompletedAt pgtype.Timestamptz
2272 CreatedAt pgtype.Timestamptz
2273 UpdatedAt pgtype.Timestamptz
2274 }
2275
2276 type OrgInvitation struct {
2277 ID int64
2278 OrgID int64
2279 InvitedByUserID pgtype.Int8
2280 TargetUserID pgtype.Int8
2281 TargetEmail pgtype.Text
2282 Role OrgRole
2283 TokenHash []byte
2284 ExpiresAt pgtype.Timestamptz
2285 AcceptedAt pgtype.Timestamptz
2286 DeclinedAt pgtype.Timestamptz
2287 CanceledAt pgtype.Timestamptz
2288 CreatedAt pgtype.Timestamptz
2289 }
2290
2291 type OrgMember struct {
2292 OrgID int64
2293 UserID int64
2294 Role OrgRole
2295 InvitedByUserID pgtype.Int8
2296 JoinedAt pgtype.Timestamptz
2297 }
2298
2299 type PasswordReset struct {
2300 ID int64
2301 UserID int64
2302 TokenHash []byte
2303 ExpiresAt pgtype.Timestamptz
2304 UsedAt pgtype.Timestamptz
2305 CreatedAt pgtype.Timestamptz
2306 }
2307
2308 type PrReview struct {
2309 ID int64
2310 PrIssueID int64
2311 AuthorUserID pgtype.Int8
2312 State PrReviewState
2313 Body string
2314 BodyHtmlCached pgtype.Text
2315 SubmittedAt pgtype.Timestamptz
2316 DismissedAt pgtype.Timestamptz
2317 DismissedByUserID pgtype.Int8
2318 DismissalReason string
2319 }
2320
2321 type PrReviewComment struct {
2322 ID int64
2323 PrIssueID int64
2324 ReviewID pgtype.Int8
2325 AuthorUserID pgtype.Int8
2326 FilePath string
2327 Side PrReviewSide
2328 OriginalCommitSha string
2329 OriginalLine int32
2330 OriginalPosition int32
2331 CurrentPosition pgtype.Int4
2332 Body string
2333 BodyHtmlCached pgtype.Text
2334 InReplyToID pgtype.Int8
2335 Pending bool
2336 ResolvedAt pgtype.Timestamptz
2337 ResolvedByUserID pgtype.Int8
2338 CreatedAt pgtype.Timestamptz
2339 UpdatedAt pgtype.Timestamptz
2340 EditedAt pgtype.Timestamptz
2341 }
2342
2343 type PrReviewRequest struct {
2344 ID int64
2345 PrIssueID int64
2346 RequestedUserID pgtype.Int8
2347 RequestedTeamID pgtype.Int8
2348 RequestedByUserID pgtype.Int8
2349 RequestedAt pgtype.Timestamptz
2350 DismissedAt pgtype.Timestamptz
2351 SatisfiedByReviewID pgtype.Int8
2352 }
2353
2354 type Principal struct {
2355 Slug string
2356 Kind PrincipalKind
2357 ID int64
2358 }
2359
2360 type ProfilePin struct {
2361 SetID int64
2362 RepoID int64
2363 Position int32
2364 PinnedAt pgtype.Timestamptz
2365 }
2366
2367 type ProfilePinSet struct {
2368 ID int64
2369 OwnerUserID pgtype.Int8
2370 OwnerOrgID pgtype.Int8
2371 UpdatedAt pgtype.Timestamptz
2372 }
2373
2374 type PullRequest struct {
2375 IssueID int64
2376 BaseRef string
2377 HeadRef string
2378 HeadRepoID int64
2379 BaseOid string
2380 HeadOid string
2381 Draft bool
2382 Mergeable pgtype.Bool
2383 MergeableState PrMergeableState
2384 MergeCommitSha pgtype.Text
2385 MergedAt pgtype.Timestamptz
2386 MergedByUserID pgtype.Int8
2387 MergeMethod NullPrMergeMethod
2388 BaseOidAtMerge pgtype.Text
2389 HeadOidAtMerge pgtype.Text
2390 LastSynchronizedAt pgtype.Timestamptz
2391 }
2392
2393 type PullRequestCommit struct {
2394 PrID int64
2395 Sha string
2396 Position int32
2397 AuthorName string
2398 AuthorEmail string
2399 CommitterName string
2400 CommitterEmail string
2401 Subject string
2402 Body string
2403 AuthoredAt pgtype.Timestamptz
2404 CommittedAt pgtype.Timestamptz
2405 }
2406
2407 type PullRequestFile struct {
2408 PrID int64
2409 Path string
2410 Status PrFileStatus
2411 OldPath pgtype.Text
2412 Additions int32
2413 Deletions int32
2414 Changes int32
2415 }
2416
2417 type PushEvent struct {
2418 ID int64
2419 RepoID int64
2420 PusherUserID pgtype.Int8
2421 BeforeSha string
2422 AfterSha string
2423 Ref string
2424 Protocol string
2425 RequestID string
2426 ProcessedAt pgtype.Timestamptz
2427 CreatedAt pgtype.Timestamptz
2428 }
2429
2430 type RateLimit struct {
2431 Scope string
2432 Key string
2433 Hits int32
2434 WindowStartedAt pgtype.Timestamptz
2435 }
2436
2437 type Repo struct {
2438 ID int64
2439 OwnerUserID pgtype.Int8
2440 OwnerOrgID pgtype.Int8
2441 Name string
2442 Description string
2443 Visibility RepoVisibility
2444 DefaultBranch string
2445 IsArchived bool
2446 ArchivedAt pgtype.Timestamptz
2447 DeletedAt pgtype.Timestamptz
2448 DiskUsedBytes int64
2449 ForkOfRepoID pgtype.Int8
2450 LicenseKey pgtype.Text
2451 PrimaryLanguage pgtype.Text
2452 HasIssues bool
2453 HasPulls bool
2454 CreatedAt pgtype.Timestamptz
2455 UpdatedAt pgtype.Timestamptz
2456 DefaultBranchOid pgtype.Text
2457 AllowSquashMerge bool
2458 AllowRebaseMerge bool
2459 AllowMergeCommit bool
2460 DefaultMergeMethod PrMergeMethod
2461 StarCount int64
2462 WatcherCount int64
2463 ForkCount int64
2464 InitStatus RepoInitStatus
2465 LastIndexedOid pgtype.Text
2466 }
2467
2468 type RepoCollaborator struct {
2469 RepoID int64
2470 UserID int64
2471 Role CollabRole
2472 AddedAt pgtype.Timestamptz
2473 AddedByUserID pgtype.Int8
2474 }
2475
2476 type RepoIssueCounter struct {
2477 RepoID int64
2478 NextNumber int64
2479 }
2480
2481 type RepoRedirect struct {
2482 OldOwnerUserID pgtype.Int8
2483 OldOwnerOrgID pgtype.Int8
2484 OldName string
2485 RepoID int64
2486 RedirectedAt pgtype.Timestamptz
2487 }
2488
2489 type RepoSourceRemote struct {
2490 RepoID int64
2491 RemoteUrl string
2492 LastFetchedAt pgtype.Timestamptz
2493 LastError pgtype.Text
2494 CreatedAt pgtype.Timestamptz
2495 UpdatedAt pgtype.Timestamptz
2496 }
2497
2498 type RepoTopic struct {
2499 RepoID int64
2500 Topic string
2501 CreatedAt pgtype.Timestamptz
2502 }
2503
2504 type RepoTransferRequest struct {
2505 ID int64
2506 RepoID int64
2507 FromUserID int64
2508 ToPrincipalKind TransferPrincipalKind
2509 ToPrincipalID int64
2510 CreatedBy int64
2511 CreatedAt pgtype.Timestamptz
2512 ExpiresAt pgtype.Timestamptz
2513 Status TransferStatus
2514 AcceptedAt pgtype.Timestamptz
2515 DeclinedAt pgtype.Timestamptz
2516 CanceledAt pgtype.Timestamptz
2517 }
2518
2519 type ReposSearch struct {
2520 RepoID int64
2521 Tsv interface{}
2522 }
2523
2524 type RunnerJwtUsed struct {
2525 Jti string
2526 RunnerID int64
2527 JobID int64
2528 RunID int64
2529 RepoID int64
2530 ExpiresAt pgtype.Timestamptz
2531 UsedAt pgtype.Timestamptz
2532 }
2533
2534 type RunnerToken struct {
2535 ID int64
2536 RunnerID int64
2537 TokenHash []byte
2538 ExpiresAt pgtype.Timestamptz
2539 RevokedAt pgtype.Timestamptz
2540 CreatedAt pgtype.Timestamptz
2541 }
2542
2543 type SignupIpThrottle struct {
2544 Cidr netip.Addr
2545 Hits int32
2546 WindowStartedAt pgtype.Timestamptz
2547 }
2548
2549 type Star struct {
2550 UserID int64
2551 RepoID int64
2552 StarredAt pgtype.Timestamptz
2553 }
2554
2555 type Team struct {
2556 ID int64
2557 OrgID int64
2558 Slug string
2559 DisplayName string
2560 Description string
2561 ParentTeamID pgtype.Int8
2562 Privacy TeamPrivacy
2563 CreatedByUserID pgtype.Int8
2564 CreatedAt pgtype.Timestamptz
2565 UpdatedAt pgtype.Timestamptz
2566 }
2567
2568 type TeamMember struct {
2569 TeamID int64
2570 UserID int64
2571 Role TeamRole
2572 AddedByUserID pgtype.Int8
2573 AddedAt pgtype.Timestamptz
2574 }
2575
2576 type TeamRepoAccess struct {
2577 TeamID int64
2578 RepoID int64
2579 Role TeamRepoRole
2580 AddedByUserID pgtype.Int8
2581 AddedAt pgtype.Timestamptz
2582 }
2583
2584 type TransactionalEmailLog struct {
2585 ID int64
2586 RecipientUserID pgtype.Int8
2587 RecipientEmail string
2588 Kind string
2589 Subject string
2590 ProviderID string
2591 Status TransactionalEmailStatus
2592 ErrorSummary pgtype.Text
2593 SentAt pgtype.Timestamptz
2594 DeliveredAt pgtype.Timestamptz
2595 }
2596
2597 type TrendingSnapshot struct {
2598 ID int64
2599 Scope TrendingScope
2600 Kind TrendingKind
2601 CapturedAt pgtype.Timestamptz
2602 Payload []byte
2603 }
2604
2605 type User struct {
2606 ID int64
2607 Username string
2608 DisplayName string
2609 PrimaryEmailID pgtype.Int8
2610 PasswordHash string
2611 PasswordAlgo string
2612 PasswordUpdatedAt pgtype.Timestamptz
2613 EmailVerified bool
2614 LastLoginAt pgtype.Timestamptz
2615 SuspendedAt pgtype.Timestamptz
2616 SuspendedReason pgtype.Text
2617 DeletedAt pgtype.Timestamptz
2618 CreatedAt pgtype.Timestamptz
2619 UpdatedAt pgtype.Timestamptz
2620 Bio string
2621 Location string
2622 Website string
2623 Company string
2624 Pronouns string
2625 AvatarObjectKey pgtype.Text
2626 Theme string
2627 SessionEpoch int32
2628 IsSiteAdmin bool
2629 IncludePrivateContributions bool
2630 }
2631
2632 type UserEmail struct {
2633 ID int64
2634 UserID int64
2635 Email string
2636 IsPrimary bool
2637 Verified bool
2638 VerificationTokenHash []byte
2639 VerificationSentAt pgtype.Timestamptz
2640 VerifiedAt pgtype.Timestamptz
2641 CreatedAt pgtype.Timestamptz
2642 }
2643
2644 type UserGpgKey struct {
2645 ID int64
2646 UserID int64
2647 Name string
2648 Fingerprint string
2649 KeyID string
2650 Armored string
2651 CanSign bool
2652 CanEncryptComms bool
2653 CanEncryptStorage bool
2654 CanCertify bool
2655 CanAuthenticate bool
2656 Uids []string
2657 Subkeys []byte
2658 PrimaryAlgo string
2659 CreatedAt pgtype.Timestamptz
2660 LastUsedAt pgtype.Timestamptz
2661 RevokedAt pgtype.Timestamptz
2662 ExpiresAt pgtype.Timestamptz
2663 }
2664
2665 type UserGpgSubkey struct {
2666 ID int64
2667 GpgKeyID int64
2668 Fingerprint string
2669 KeyID string
2670 CanSign bool
2671 CanEncryptComms bool
2672 CanEncryptStorage bool
2673 CanCertify bool
2674 ExpiresAt pgtype.Timestamptz
2675 RevokedAt pgtype.Timestamptz
2676 CreatedAt pgtype.Timestamptz
2677 }
2678
2679 type UserNotificationPref struct {
2680 UserID int64
2681 Key string
2682 Value []byte
2683 UpdatedAt pgtype.Timestamptz
2684 }
2685
2686 type UserRecoveryCode struct {
2687 ID int64
2688 UserID int64
2689 CodeHash []byte
2690 UsedAt pgtype.Timestamptz
2691 GeneratedAt pgtype.Timestamptz
2692 CreatedAt pgtype.Timestamptz
2693 }
2694
2695 type UserSshKey struct {
2696 ID int64
2697 UserID int64
2698 Title string
2699 FingerprintSha256 string
2700 KeyType string
2701 KeyBits int32
2702 PublicKey string
2703 LastUsedAt pgtype.Timestamptz
2704 LastUsedIp *netip.Addr
2705 CreatedAt pgtype.Timestamptz
2706 Kind string
2707 }
2708
2709 type UserToken struct {
2710 ID int64
2711 UserID int64
2712 Name string
2713 TokenHash []byte
2714 TokenPrefix string
2715 Scopes []string
2716 ExpiresAt pgtype.Timestamptz
2717 LastUsedAt pgtype.Timestamptz
2718 LastUsedIp *netip.Addr
2719 RevokedAt pgtype.Timestamptz
2720 CreatedAt pgtype.Timestamptz
2721 }
2722
2723 type UserTotp struct {
2724 ID int64
2725 UserID int64
2726 SecretEncrypted []byte
2727 SecretNonce []byte
2728 ConfirmedAt pgtype.Timestamptz
2729 LastUsedCounter int64
2730 CreatedAt pgtype.Timestamptz
2731 UpdatedAt pgtype.Timestamptz
2732 }
2733
2734 type UsernameRedirect struct {
2735 OldUsername string
2736 UserID int64
2737 ChangedAt pgtype.Timestamptz
2738 }
2739
2740 type UsersSearch struct {
2741 UserID int64
2742 Tsv interface{}
2743 }
2744
2745 type Watch struct {
2746 UserID int64
2747 RepoID int64
2748 Level WatchLevel
2749 UpdatedAt pgtype.Timestamptz
2750 }
2751
2752 type Webhook struct {
2753 ID int64
2754 OwnerKind WebhookOwnerKind
2755 OwnerID int64
2756 Url string
2757 ContentType WebhookContentType
2758 Events []string
2759 SecretCiphertext []byte
2760 SecretNonce []byte
2761 Active bool
2762 SslVerification bool
2763 ConsecutiveFailures int32
2764 AutoDisableThreshold int32
2765 DisabledAt pgtype.Timestamptz
2766 DisabledReason pgtype.Text
2767 LastSuccessAt pgtype.Timestamptz
2768 LastFailureAt pgtype.Timestamptz
2769 CreatedByUserID pgtype.Int8
2770 CreatedAt pgtype.Timestamptz
2771 UpdatedAt pgtype.Timestamptz
2772 }
2773
2774 type WebhookDelivery struct {
2775 ID int64
2776 WebhookID int64
2777 EventKind string
2778 EventID pgtype.Int8
2779 DeliveryUuid pgtype.UUID
2780 Payload []byte
2781 RequestHeaders []byte
2782 RequestBody []byte
2783 ResponseStatus pgtype.Int4
2784 ResponseHeaders []byte
2785 ResponseBody []byte
2786 ResponseTruncated bool
2787 StartedAt pgtype.Timestamptz
2788 CompletedAt pgtype.Timestamptz
2789 Attempt int32
2790 MaxAttempts int32
2791 NextRetryAt pgtype.Timestamptz
2792 Status WebhookDeliveryStatus
2793 IdempotencyKey string
2794 ErrorSummary pgtype.Text
2795 RedeliverOf pgtype.Int8
2796 }
2797
2798 type WebhookEventsPending struct {
2799 ID int64
2800 RepoID int64
2801 EventKind string
2802 Payload []byte
2803 CreatedAt pgtype.Timestamptz
2804 }
2805
2806 type WorkflowArtifact struct {
2807 ID int64
2808 RunID int64
2809 Name string
2810 ObjectKey string
2811 ByteCount int64
2812 ExpiresAt pgtype.Timestamptz
2813 CreatedAt pgtype.Timestamptz
2814 }
2815
2816 type WorkflowCache struct {
2817 ID int64
2818 RepoID int64
2819 CacheKey string
2820 CacheVersion string
2821 GitRef string
2822 ObjectKey string
2823 SizeBytes int64
2824 LastAccessedAt pgtype.Timestamptz
2825 CreatedAt pgtype.Timestamptz
2826 }
2827
2828 type WorkflowDisabled struct {
2829 RepoID int64
2830 WorkflowFile string
2831 DisabledByUserID pgtype.Int8
2832 DisabledAt pgtype.Timestamptz
2833 }
2834
2835 type WorkflowJob struct {
2836 ID int64
2837 RunID int64
2838 JobIndex int32
2839 JobKey string
2840 JobName string
2841 RunsOn string
2842 RunnerID pgtype.Int8
2843 NeedsJobs []string
2844 IfExpr string
2845 TimeoutMinutes int32
2846 Permissions []byte
2847 JobEnv []byte
2848 Status WorkflowJobStatus
2849 Conclusion NullCheckConclusion
2850 CancelRequested bool
2851 StartedAt pgtype.Timestamptz
2852 CompletedAt pgtype.Timestamptz
2853 Version int32
2854 CreatedAt pgtype.Timestamptz
2855 UpdatedAt pgtype.Timestamptz
2856 }
2857
2858 type WorkflowJobSecretMask struct {
2859 JobID int64
2860 Ciphertext []byte
2861 Nonce []byte
2862 CreatedAt pgtype.Timestamptz
2863 }
2864
2865 type WorkflowRun struct {
2866 ID int64
2867 RepoID int64
2868 RunIndex int64
2869 WorkflowFile string
2870 WorkflowName string
2871 HeadSha string
2872 HeadRef string
2873 Event WorkflowRunEvent
2874 EventPayload []byte
2875 ActorUserID pgtype.Int8
2876 ParentRunID pgtype.Int8
2877 ConcurrencyGroup string
2878 Status WorkflowRunStatus
2879 Conclusion NullCheckConclusion
2880 Pinned bool
2881 NeedApproval bool
2882 ApprovedByUserID pgtype.Int8
2883 StartedAt pgtype.Timestamptz
2884 CompletedAt pgtype.Timestamptz
2885 Version int32
2886 CreatedAt pgtype.Timestamptz
2887 UpdatedAt pgtype.Timestamptz
2888 TriggerEventID string
2889 }
2890
2891 type WorkflowRunApproval struct {
2892 RunID int64
2893 RequestedReason string
2894 RequestedAt pgtype.Timestamptz
2895 ApprovedByUserID pgtype.Int8
2896 ApprovedAt pgtype.Timestamptz
2897 RejectedByUserID pgtype.Int8
2898 RejectedAt pgtype.Timestamptz
2899 CreatedAt pgtype.Timestamptz
2900 UpdatedAt pgtype.Timestamptz
2901 }
2902
2903 type WorkflowRunner struct {
2904 ID int64
2905 Name string
2906 Labels []string
2907 Capacity int32
2908 Status WorkflowRunnerStatus
2909 LastHeartbeatAt pgtype.Timestamptz
2910 RegisteredByUserID pgtype.Int8
2911 CreatedAt pgtype.Timestamptz
2912 UpdatedAt pgtype.Timestamptz
2913 HostName string
2914 Version string
2915 DrainingAt pgtype.Timestamptz
2916 DrainReason string
2917 RevokedAt pgtype.Timestamptz
2918 RevokedReason string
2919 }
2920
2921 type WorkflowSecret struct {
2922 ID int64
2923 RepoID pgtype.Int8
2924 OrgID pgtype.Int8
2925 Name string
2926 Ciphertext []byte
2927 Nonce []byte
2928 CreatedByUserID pgtype.Int8
2929 CreatedAt pgtype.Timestamptz
2930 UpdatedAt pgtype.Timestamptz
2931 }
2932
2933 type WorkflowStep struct {
2934 ID int64
2935 JobID int64
2936 StepIndex int32
2937 StepID string
2938 StepName string
2939 IfExpr string
2940 RunCommand string
2941 UsesAlias string
2942 WorkingDirectory string
2943 StepEnv []byte
2944 ContinueOnError bool
2945 Status WorkflowStepStatus
2946 Conclusion NullCheckConclusion
2947 LogObjectKey pgtype.Text
2948 LogByteCount int64
2949 StartedAt pgtype.Timestamptz
2950 CompletedAt pgtype.Timestamptz
2951 Version int32
2952 CreatedAt pgtype.Timestamptz
2953 UpdatedAt pgtype.Timestamptz
2954 StepWith []byte
2955 }
2956
2957 type WorkflowStepLogChunk struct {
2958 ID int64
2959 StepID int64
2960 Seq int32
2961 Chunk []byte
2962 CreatedAt pgtype.Timestamptz
2963 }
2964