API Overview
API Mutation
API Query
API Subscription
Webhooks
Hardware
Cheatsheet

GraphQL Mutations

CREATE_ACCOUNT
mutation CREATE_ACCOUNT {
account {
register(
input: {
firstname: "admin"
lastname: "admin"
email: "admin@company.com"
password: "admin"
}
) {
activationLink
}
}
}
VERIFY_ACCOUNT
mutation VERIFY_ACCOUNT {
account {
verifyAccount(email: "admin@company.com", pincode: "123456") {
success
}
}
}
LOG_IN
mutation LOG_IN {
account {
login(
input: {
service: Password
params: { email: "admin@company.com", password: "admin" }
}
) {
id
}
}
}
CREATE_TENANT
mutation CREATE_TENANT {
tenant {
create(
input: { name: "Company Name", planPriceId: BASIC_FREE }
) {
id
name
normalizedName
}
}
}
CREATE_SPACE
mutation CREATE_SPACE {
space {
create(input: { name: "Space" }) {
id
name
normalizedName
}
}
}
CREATE_POINT
mutation CREATE_POINT {
point {
register(input: { spaceId: "space", name: "Point", externalId: "88" }) {
id
name
}
}
}
CREATE_SIGNALS
mutation CREATE_SIGNALS {
signal {
create(
input: {
signals: [
{
name: "Name"
value: "123"
type: Temperature
unit: Celsius
timestamp: "2021-03-23T08:44:23.351000000+0000"
}
]
pointId: "607eca6ba3e82f4977b987be"
}
) {
success
}
}
}
CREATE_ACCESS_TOKEN
mutation CREATE_ACCESS_TOKEN {
accessToken {
create(input: {name: "Data Insertion", scopes: [CREATE_SIGNAL]}) {
id
token

}
}
}

Ready to get started?