-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathschema.graphql
More file actions
87 lines (77 loc) · 1.76 KB
/
schema.graphql
File metadata and controls
87 lines (77 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
type PaginatedEvents {
events: [Event!]
nextToken: String
}
type PaginatedEstablishments {
establishments: [Establishment!]
nextToken: String
}
type EstablishmentSearchResults {
hits: [Establishment!]
}
type EventSearchResults {
hits: [Event!]
}
type Location {
lat: String!
lon: String!
}
input LocationInput {
lat: String!
lon: String!
}
type Event {
id: ID
atEstablishmentId: String!
awayTeam: String!
awayTeamBadge: String
homeTeam: String!
homeTeamBadge: String
leagueId: String!
sportsDbId: String
startTime: String!
coverCharge: Boolean!
description: String
}
type Establishment {
id: ID!
managerUsername: String!
googlePlaceId: String!
googlePhotoReference: String
name: String
displayName: String
address: String
phone: String
location: Location
}
type Mutation {
putEvent(
id: ID,
atEstablishmentId: String!
awayTeam: String!,
awayTeamBadge: String
homeTeam: String!,
homeTeamBadge: String
leagueId: String!,
sportsDbId: String,
startTime: String!,
coverCharge: Boolean!
description: String
): Event
putEstablishment(
googlePlaceId: String!
name: String!
displayName: String!
address: String!
phone: String,
location: LocationInput!
): Establishment
}
type Query {
getEvents(limit: Int, nextToken: String, atEstablishmentId: String!): PaginatedEvents!
getEstablishmentsUserManages(limit: Int, nextToken: String): PaginatedEstablishments!
getEstablishmentById(id: String!): Establishment!
getEstablishmentsInBounds(limit: Int, topLeft: LocationInput!, bottomRight: LocationInput!): EstablishmentSearchResults!
searchEstablishments(name: String!): EstablishmentSearchResults!
searchEvents(pattern: String!): EventSearchResults!
}