1+ import 'graphql-import-node' ; // Needed so you can import *.graphql files
2+
3+ import { makeBindingClass , Options } from 'graphql-binding'
4+ import { GraphQLResolveInfo , GraphQLSchema } from 'graphql'
5+ import { IResolvers } from 'graphql-tools/dist/Interfaces'
6+ import * as schema from './schema.graphql'
7+
8+ export interface Query {
9+ users : < T = Array < User > > ( args : { offset ?: Int | null , limit ?: Int | null , where ?: UserWhereInput | null , orderBy ?: UserOrderByInput | null } , info ?: GraphQLResolveInfo | string , options ?: Options ) => Promise < T > ,
10+ user : < T = User > ( args : { where : UserWhereUniqueInput } , info ?: GraphQLResolveInfo | string , options ?: Options ) => Promise < T >
11+ }
12+
13+ export interface Mutation {
14+ createUser : < T = User > ( args : { data : UserCreateInput } , info ?: GraphQLResolveInfo | string , options ?: Options ) => Promise < T > ,
15+ updateUser : < T = User > ( args : { data : UserUpdateInput , where : UserWhereUniqueInput } , info ?: GraphQLResolveInfo | string , options ?: Options ) => Promise < T > ,
16+ deleteUser : < T = StandardDeleteResponse > ( args : { where : UserWhereUniqueInput } , info ?: GraphQLResolveInfo | string , options ?: Options ) => Promise < T >
17+ }
18+
19+ export interface Subscription { }
20+
21+ export interface Binding {
22+ query : Query
23+ mutation : Mutation
24+ subscription : Subscription
25+ request : < T = any > ( query : string , variables ?: { [ key : string ] : any } ) => Promise < T >
26+ delegate ( operation : 'query' | 'mutation' , fieldName : string , args : {
27+ [ key : string ] : any ;
28+ } , infoOrQuery ?: GraphQLResolveInfo | string , options ?: Options ) : Promise < any > ;
29+ delegateSubscription ( fieldName : string , args ?: {
30+ [ key : string ] : any ;
31+ } , infoOrQuery ?: GraphQLResolveInfo | string , options ?: Options ) : Promise < AsyncIterator < any > > ;
32+ getAbstractResolvers ( filterSchema ?: GraphQLSchema | string ) : IResolvers ;
33+ }
34+
35+ export interface BindingConstructor < T > {
36+ new ( ...args : any [ ] ) : T
37+ }
38+
39+ export const Binding = makeBindingClass < BindingConstructor < Binding > > ( { schema : schema as any } )
40+
41+ /**
42+ * Types
43+ */
44+
45+ export type UserOrderByInput = 'createdAt_ASC' |
46+ 'createdAt_DESC' |
47+ 'updatedAt_ASC' |
48+ 'updatedAt_DESC' |
49+ 'deletedAt_ASC' |
50+ 'deletedAt_DESC' |
51+ 'firstName_ASC' |
52+ 'firstName_DESC' |
53+ 'lastName_ASC' |
54+ 'lastName_DESC'
55+
56+ export interface BaseWhereInput {
57+ id_eq ?: String | null
58+ id_in ?: String [ ] | String | null
59+ createdAt_eq ?: String | null
60+ createdAt_lt ?: String | null
61+ createdAt_lte ?: String | null
62+ createdAt_gt ?: String | null
63+ createdAt_gte ?: String | null
64+ createdById_eq ?: String | null
65+ updatedAt_eq ?: String | null
66+ updatedAt_lt ?: String | null
67+ updatedAt_lte ?: String | null
68+ updatedAt_gt ?: String | null
69+ updatedAt_gte ?: String | null
70+ updatedById_eq ?: String | null
71+ deletedAt_all ?: Boolean | null
72+ deletedAt_eq ?: String | null
73+ deletedAt_lt ?: String | null
74+ deletedAt_lte ?: String | null
75+ deletedAt_gt ?: String | null
76+ deletedAt_gte ?: String | null
77+ deletedById_eq ?: String | null
78+ }
79+
80+ export interface UserCreateInput {
81+ firstName : String
82+ lastName : String
83+ }
84+
85+ export interface UserUpdateInput {
86+ firstName ?: String | null
87+ lastName ?: String | null
88+ }
89+
90+ export interface UserWhereInput {
91+ id_eq ?: ID_Input | null
92+ id_in ?: ID_Output [ ] | ID_Output | null
93+ createdAt_eq ?: DateTime | null
94+ createdAt_lt ?: DateTime | null
95+ createdAt_lte ?: DateTime | null
96+ createdAt_gt ?: DateTime | null
97+ createdAt_gte ?: DateTime | null
98+ createdById_eq ?: ID_Input | null
99+ createdById_in ?: ID_Output [ ] | ID_Output | null
100+ updatedAt_eq ?: DateTime | null
101+ updatedAt_lt ?: DateTime | null
102+ updatedAt_lte ?: DateTime | null
103+ updatedAt_gt ?: DateTime | null
104+ updatedAt_gte ?: DateTime | null
105+ updatedById_eq ?: ID_Input | null
106+ updatedById_in ?: ID_Output [ ] | ID_Output | null
107+ deletedAt_all ?: Boolean | null
108+ deletedAt_eq ?: DateTime | null
109+ deletedAt_lt ?: DateTime | null
110+ deletedAt_lte ?: DateTime | null
111+ deletedAt_gt ?: DateTime | null
112+ deletedAt_gte ?: DateTime | null
113+ deletedById_eq ?: ID_Input | null
114+ deletedById_in ?: ID_Output [ ] | ID_Output | null
115+ firstName_eq ?: String | null
116+ firstName_contains ?: String | null
117+ firstName_startsWith ?: String | null
118+ firstName_endsWith ?: String | null
119+ firstName_in ?: String [ ] | String | null
120+ lastName_eq ?: String | null
121+ lastName_contains ?: String | null
122+ lastName_startsWith ?: String | null
123+ lastName_endsWith ?: String | null
124+ lastName_in ?: String [ ] | String | null
125+ }
126+
127+ export interface UserWhereUniqueInput {
128+ id : ID_Output
129+ }
130+
131+ export interface BaseGraphQLObject {
132+ id : ID_Output
133+ createdAt : DateTime
134+ createdById : String
135+ updatedAt ?: DateTime | null
136+ updatedById ?: String | null
137+ deletedAt ?: DateTime | null
138+ deletedById ?: String | null
139+ version : Int
140+ }
141+
142+ export interface DeleteResponse {
143+ id : ID_Output
144+ }
145+
146+ export interface BaseModel extends BaseGraphQLObject {
147+ id : ID_Output
148+ createdAt : DateTime
149+ createdById : String
150+ updatedAt ?: DateTime | null
151+ updatedById ?: String | null
152+ deletedAt ?: DateTime | null
153+ deletedById ?: String | null
154+ version : Int
155+ }
156+
157+ export interface BaseModelUUID extends BaseGraphQLObject {
158+ id : ID_Output
159+ createdAt : DateTime
160+ createdById : String
161+ updatedAt ?: DateTime | null
162+ updatedById ?: String | null
163+ deletedAt ?: DateTime | null
164+ deletedById ?: String | null
165+ version : Int
166+ }
167+
168+ export interface PageInfo {
169+ hasNextPage : Boolean
170+ hasPreviousPage : Boolean
171+ startCursor ?: String | null
172+ endCursor ?: String | null
173+ }
174+
175+ export interface StandardDeleteResponse {
176+ id : ID_Output
177+ }
178+
179+ export interface User extends BaseGraphQLObject {
180+ id : ID_Output
181+ createdAt : DateTime
182+ createdById : String
183+ updatedAt ?: DateTime | null
184+ updatedById ?: String | null
185+ deletedAt ?: DateTime | null
186+ deletedById ?: String | null
187+ version : Int
188+ firstName : String
189+ lastName : String
190+ }
191+
192+ /*
193+ The `Boolean` scalar type represents `true` or `false`.
194+ */
195+ export type Boolean = boolean
196+
197+ /*
198+ The javascript `Date` as string. Type represents date and time as the ISO Date string.
199+ */
200+ export type DateTime = Date | string
201+
202+ /*
203+ The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.
204+ */
205+ export type ID_Input = string | number
206+ export type ID_Output = string
207+
208+ /*
209+ The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.
210+ */
211+ export type Int = number
212+
213+ /*
214+ The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.
215+ */
216+ export type String = string
0 commit comments