1
- // Generated by Xata Codegen 0.26.7 . Please do not edit.
2
- import { buildClient } from ' @xata.io/client' ;
1
+ // Generated by Xata Codegen 0.30.1 . Please do not edit.
2
+ import { buildClient } from " @xata.io/client" ;
3
3
import type {
4
4
BaseClientOptions ,
5
5
SchemaInference ,
6
- XataRecord
7
- } from ' @xata.io/client' ;
6
+ XataRecord ,
7
+ } from " @xata.io/client" ;
8
8
9
9
const tables = [
10
10
{
11
- name : ' reports' ,
11
+ name : " reports" ,
12
12
columns : [
13
- { name : ' repoId' , type : ' int' , unique : true } ,
14
- { name : ' repoAuthor' , type : ' string' } ,
13
+ { name : " repoId" , type : " int" , unique : true } ,
14
+ { name : " repoAuthor" , type : " string" } ,
15
15
{
16
- name : ' message' ,
17
- type : ' text' ,
16
+ name : " message" ,
17
+ type : " text" ,
18
18
notNull : true ,
19
- defaultValue : ' No Message'
19
+ defaultValue : " No Message" ,
20
20
} ,
21
- { name : ' user' , type : ' link' , link : { table : ' nextauth_users' } } ,
22
- { name : ' valid' , type : ' bool' , notNull : true , defaultValue : ' true' } ,
23
- { name : ' repoUrl' , type : ' string' , unique : true }
24
- ]
21
+ { name : " user" , type : " link" , link : { table : " nextauth_users" } } ,
22
+ { name : " valid" , type : " bool" , notNull : true , defaultValue : " true" } ,
23
+ { name : " repoUrl" , type : " string" , unique : true } ,
24
+ ] ,
25
25
} ,
26
26
{
27
- name : ' nextauth_users' ,
27
+ name : " nextauth_users" ,
28
28
columns : [
29
- { name : ' email' , type : ' email' } ,
30
- { name : ' emailVerified' , type : ' datetime' } ,
31
- { name : ' name' , type : ' string' } ,
32
- { name : ' image' , type : ' string' }
29
+ { name : " email" , type : " email" } ,
30
+ { name : " emailVerified" , type : " datetime" } ,
31
+ { name : " name" , type : " string" } ,
32
+ { name : " image" , type : " string" } ,
33
33
] ,
34
34
revLinks : [
35
- { column : 'user' , table : 'nextauth_accounts' } ,
36
- { column : 'user' , table : 'nextauth_users_accounts' } ,
37
- { column : 'user' , table : 'nextauth_users_sessions' } ,
38
- { column : 'user' , table : 'nextauth_sessions' } ,
39
- { column : 'user' , table : 'reports' }
40
- ]
35
+ { column : "user" , table : "nextauth_accounts" } ,
36
+ { column : "user" , table : "nextauth_users_accounts" } ,
37
+ { column : "user" , table : "nextauth_users_sessions" } ,
38
+ { column : "user" , table : "nextauth_sessions" } ,
39
+ { column : "user" , table : "reports" } ,
40
+ { column : "user" , table : "bookmarks" } ,
41
+ ] ,
41
42
} ,
42
43
{
43
- name : ' nextauth_accounts' ,
44
+ name : " nextauth_accounts" ,
44
45
columns : [
45
- { name : ' user' , type : ' link' , link : { table : ' nextauth_users' } } ,
46
- { name : ' type' , type : ' string' } ,
47
- { name : ' provider' , type : ' string' } ,
48
- { name : ' providerAccountId' , type : ' string' } ,
49
- { name : ' refresh_token' , type : ' string' } ,
50
- { name : ' access_token' , type : ' string' } ,
51
- { name : ' expires_at' , type : ' int' } ,
52
- { name : ' token_type' , type : ' string' } ,
53
- { name : ' scope' , type : ' string' } ,
54
- { name : ' id_token' , type : ' text' } ,
55
- { name : ' session_state' , type : ' string' }
46
+ { name : " user" , type : " link" , link : { table : " nextauth_users" } } ,
47
+ { name : " type" , type : " string" } ,
48
+ { name : " provider" , type : " string" } ,
49
+ { name : " providerAccountId" , type : " string" } ,
50
+ { name : " refresh_token" , type : " string" } ,
51
+ { name : " access_token" , type : " string" } ,
52
+ { name : " expires_at" , type : " int" } ,
53
+ { name : " token_type" , type : " string" } ,
54
+ { name : " scope" , type : " string" } ,
55
+ { name : " id_token" , type : " text" } ,
56
+ { name : " session_state" , type : " string" } ,
56
57
] ,
57
- revLinks : [ { column : ' account' , table : ' nextauth_users_accounts' } ]
58
+ revLinks : [ { column : " account" , table : " nextauth_users_accounts" } ] ,
58
59
} ,
59
60
{
60
- name : ' nextauth_verificationTokens' ,
61
+ name : " nextauth_verificationTokens" ,
61
62
columns : [
62
- { name : ' identifier' , type : ' string' } ,
63
- { name : ' token' , type : ' string' } ,
64
- { name : ' expires' , type : ' datetime' }
65
- ]
63
+ { name : " identifier" , type : " string" } ,
64
+ { name : " token" , type : " string" } ,
65
+ { name : " expires" , type : " datetime" } ,
66
+ ] ,
66
67
} ,
67
68
{
68
- name : ' nextauth_users_accounts' ,
69
+ name : " nextauth_users_accounts" ,
69
70
columns : [
70
- { name : ' user' , type : ' link' , link : { table : ' nextauth_users' } } ,
71
- { name : ' account' , type : ' link' , link : { table : ' nextauth_accounts' } }
72
- ]
71
+ { name : " user" , type : " link" , link : { table : " nextauth_users" } } ,
72
+ { name : " account" , type : " link" , link : { table : " nextauth_accounts" } } ,
73
+ ] ,
73
74
} ,
74
75
{
75
- name : ' nextauth_users_sessions' ,
76
+ name : " nextauth_users_sessions" ,
76
77
columns : [
77
- { name : ' user' , type : ' link' , link : { table : ' nextauth_users' } } ,
78
- { name : ' session' , type : ' link' , link : { table : ' nextauth_sessions' } }
79
- ]
78
+ { name : " user" , type : " link" , link : { table : " nextauth_users" } } ,
79
+ { name : " session" , type : " link" , link : { table : " nextauth_sessions" } } ,
80
+ ] ,
80
81
} ,
81
82
{
82
- name : ' nextauth_sessions' ,
83
+ name : " nextauth_sessions" ,
83
84
columns : [
84
- { name : ' sessionToken' , type : ' string' } ,
85
- { name : ' expires' , type : ' datetime' } ,
86
- { name : ' user' , type : ' link' , link : { table : ' nextauth_users' } }
85
+ { name : " sessionToken" , type : " string" } ,
86
+ { name : " expires" , type : " datetime" } ,
87
+ { name : " user" , type : " link" , link : { table : " nextauth_users" } } ,
87
88
] ,
88
- revLinks : [ { column : 'session' , table : 'nextauth_users_sessions' } ]
89
- }
89
+ revLinks : [ { column : "session" , table : "nextauth_users_sessions" } ] ,
90
+ } ,
91
+ {
92
+ name : "bookmarks" ,
93
+ columns : [
94
+ { name : "user" , type : "link" , link : { table : "nextauth_users" } } ,
95
+ ] ,
96
+ } ,
90
97
] as const ;
91
98
92
99
export type SchemaTables = typeof tables ;
93
100
export type InferredTypes = SchemaInference < SchemaTables > ;
94
101
95
- export type Reports = InferredTypes [ ' reports' ] ;
102
+ export type Reports = InferredTypes [ " reports" ] ;
96
103
export type ReportsRecord = Reports & XataRecord ;
97
104
98
- export type NextauthUsers = InferredTypes [ ' nextauth_users' ] ;
105
+ export type NextauthUsers = InferredTypes [ " nextauth_users" ] ;
99
106
export type NextauthUsersRecord = NextauthUsers & XataRecord ;
100
107
101
- export type NextauthAccounts = InferredTypes [ ' nextauth_accounts' ] ;
108
+ export type NextauthAccounts = InferredTypes [ " nextauth_accounts" ] ;
102
109
export type NextauthAccountsRecord = NextauthAccounts & XataRecord ;
103
110
104
111
export type NextauthVerificationTokens =
105
- InferredTypes [ ' nextauth_verificationTokens' ] ;
112
+ InferredTypes [ " nextauth_verificationTokens" ] ;
106
113
export type NextauthVerificationTokensRecord = NextauthVerificationTokens &
107
114
XataRecord ;
108
115
109
- export type NextauthUsersAccounts = InferredTypes [ ' nextauth_users_accounts' ] ;
116
+ export type NextauthUsersAccounts = InferredTypes [ " nextauth_users_accounts" ] ;
110
117
export type NextauthUsersAccountsRecord = NextauthUsersAccounts & XataRecord ;
111
118
112
- export type NextauthUsersSessions = InferredTypes [ ' nextauth_users_sessions' ] ;
119
+ export type NextauthUsersSessions = InferredTypes [ " nextauth_users_sessions" ] ;
113
120
export type NextauthUsersSessionsRecord = NextauthUsersSessions & XataRecord ;
114
121
115
- export type NextauthSessions = InferredTypes [ ' nextauth_sessions' ] ;
122
+ export type NextauthSessions = InferredTypes [ " nextauth_sessions" ] ;
116
123
export type NextauthSessionsRecord = NextauthSessions & XataRecord ;
117
124
125
+ export type Bookmarks = InferredTypes [ "bookmarks" ] ;
126
+ export type BookmarksRecord = Bookmarks & XataRecord ;
127
+
118
128
export type DatabaseSchema = {
119
129
reports : ReportsRecord ;
120
130
nextauth_users : NextauthUsersRecord ;
@@ -123,13 +133,14 @@ export type DatabaseSchema = {
123
133
nextauth_users_accounts : NextauthUsersAccountsRecord ;
124
134
nextauth_users_sessions : NextauthUsersSessionsRecord ;
125
135
nextauth_sessions : NextauthSessionsRecord ;
136
+ bookmarks : BookmarksRecord ;
126
137
} ;
127
138
128
139
const DatabaseClient = buildClient ( ) ;
129
140
130
141
const defaultOptions = {
131
142
databaseURL :
132
- ' https://Usman-Sabuwala-s-workspace-u2kcvd.us-east-1.xata.sh/db/project-finder-hf'
143
+ " https://Usman-Sabuwala-s-workspace-u2kcvd.us-east-1.xata.sh/db/project-finder-hf" ,
133
144
} ;
134
145
135
146
export class XataClient extends DatabaseClient < DatabaseSchema > {
0 commit comments