Skip to content

Commit

Permalink
Adding a few more predefined queries into the constants
Browse files Browse the repository at this point in the history
  • Loading branch information
heslegrave committed Jul 20, 2020
1 parent 89a3bd2 commit 29dca7b
Showing 1 changed file with 77 additions and 0 deletions.
77 changes: 77 additions & 0 deletions connectedcars/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,83 @@

HEADER_NAMESPACE = "x-organization-namespace"

QUERY_COMPLETE = """
query User {
viewer {
id
firstname
lastname
email
vehicles {
vehicle {
id
vin
class
brand
make
model
name
licensePlate
fuelType
fuelLevel {
liter
}
fuelPercentage {
percent
}
odometer {
odometer
}
position {
latitude
longitude
}
refuelEvents {
litersDifference
time
}
latestBatteryVoltage {
voltage
}
health {
ok
recommendation
}
trips (last:3) {
items {
duration
fuelUsed
mileage
startLongitude
startLatitude
endLongitude
endLatitude
}
}
}
}
}
}"""
QUERY_USER = """
query User {
viewer {
id
firstname
lastname
email
}
}"""
QUERY_VEHICLE_VIN = """
query User {
viewer {
vehicles {
vehicle {
id
vin
}
}
}
}"""
QUERY_VEHICLE_OVERVIEW = """
query User {
viewer {
Expand Down

0 comments on commit 29dca7b

Please sign in to comment.