Cloud Studio IoT Webhooks API
Events the platform sends to your own URL: a step of an action ("Call a webhook") and the alarms of an alert when they open, close or are acknowledged. Webhooks are off by default and are switched on per instance with the `WebhooksEnabled` add-on. Each event is a `POST` with a JSON body in UTF-8. Any 2xx response counts as delivered. A 5xx, 408 or 429, a timeout or a network error is retried: up to 3 attempts, with waits of 1 and 2 seconds, 10 seconds per attempt and never more than 25 seconds in total. Any other 4xx is not retried. The body of your response is ignored. ## Verifying the signature When the webhook has a secret, the request carries `X-Gear-Signature`: `sha256=` followed by the HMAC-SHA256 of the body, in lowercase hex, keyed with that secret. Compute it over the raw bytes you received, not over JSON you parsed and serialized again, and compare in constant time. Node: ```js const crypto = require("crypto"); const expected = "sha256=" + crypto.createHmac("sha256", secret).update(rawBody).digest("hex"); const received = req.headers["x-gear-signature"] || ""; const ok = expected.length === received.length && crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(received)); ``` Python: ```python import hashlib, hmac expected = "sha256=" + hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest() ok = hmac.compare_digest(expected, request.headers.get("X-Gear-Signature", "")) ``` Do not compare with `==`: it stops at the first different character, and the time it takes tells an attacker how much of a forged signature is right.
Every API here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for apis
7 MCP tools reach this
find_apisBrowse and filter every API in the catalog.
get_api_artifactsOne API's artifacts, grouped by type.
get_openapiThe primary OpenAPI for this API.
find_similar_apisAPIs that look like this one.
apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
resolveTurn a domain, URL or GitHub org into the provider it belongs to.
find_cohortsEvery scored population of providers in the catalog.
All 92 tools →
Call it yourself
curl for this page
This API
curl "https://apis.io/api/v1/apis/cloudstudioiot:cloudstudioiot-webhooks-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. By signing up you are subscribing to the APIs.io and API Evangelist
newsletters — you can unsubscribe from any issue. See our
Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Cloud Studio IoT Data Extraction Webhooks API
version: '2'
summary: Read alerts, alarms, endpoint data, geozones and the instance map from a Cloud Studio IoT instance.
description: 'HTTP API to extract data from the Cloud Studio IoT platform (Gear Studio):
alert definitions, the alarm history, endpoint (sensor) readings, geozones
and the client / facility / device / endpoint map of an instance.
Every list has an incremental variant driven by `SequenceNumber`, a value
that only grows: store the last one you received and ask again from there
to get what changed since.
The data extraction operations under `/api/v2` only read: none of them
changes data on the platform. The only writes are creating a persistent
access token and deleting it, and deleting it undoes the creation.
This document is written from the public documentation at
https://cloudstudioiot.com/docs/apis-de-extraccion-de-datos, which is the
reference if the two ever differ.'
contact:
name: Cloud Studio IoT
url: https://cloudstudioiot.com/contact
email: info@cloud.studio
termsOfService: https://cloudstudioiot.com/terms
servers:
- url: https://gear.cloud.studio
description: The shared Cloud Studio IoT cloud instance.
- url: https://{host}
description: A Cloud Studio IoT instance. Dedicated and on-premise instances use their own host.
variables:
host:
default: gear.cloud.studio
security:
- bearerToken: []
- accessTokenQuery: []
tags:
- name: Webhooks
description: 'Events the platform sends to your own URL: a step of an action ("Call a
webhook") and the alarms of an alert when they open, close or are
acknowledged. Webhooks are off by default and are switched on per
instance with the `WebhooksEnabled` add-on.
Each event is a `POST` with a JSON body in UTF-8. Any 2xx response
counts as delivered. A 5xx, 408 or 429, a timeout or a network error is
retried: up to 3 attempts, with waits of 1 and 2 seconds, 10 seconds per
attempt and never more than 25 seconds in total. Any other 4xx is not
retried. The body of your response is ignored.
## Verifying the signature
When the webhook has a secret, the request carries `X-Gear-Signature`:
`sha256=` followed by the HMAC-SHA256 of the body, in lowercase hex,
keyed with that secret. Compute it over the raw bytes you received, not
over JSON you parsed and serialized again, and compare in constant time.
Node:
```js
const crypto = require("crypto");
const expected = "sha256=" + crypto.createHmac("sha256", secret).update(rawBody).digest("hex");
const received = req.headers["x-gear-signature"] || "";
const ok = expected.length === received.length &&
crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(received));
```
Python:
```python
import hashlib, hmac
expected = "sha256=" + hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest()
ok = hmac.compare_digest(expected, request.headers.get("X-Gear-Signature", ""))
```
Do not compare with `==`: it stops at the first different character, and
the time it takes tells an attacker how much of a forged signature is
right.'
paths: {}
webhooks:
action.step:
post:
operationId: actionStepWebhook
tags:
- Webhooks
summary: A step of an action called the webhook
description: 'Sent by the "Call a webhook" step of an action. If no attempt gets a 2xx
the step counts as failed, and the action follows its "continue on error"
setting. `value` is the reading of the endpoint that triggered the action,
if any, and `trigger` the condition of the trigger (`null` when the action
ran by hand or on a schedule).'
security: []
parameters:
- $ref: '#/components/parameters/XGearEvent'
- $ref: '#/components/parameters/XGearSignature'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/WebhookPayload'
examples:
action_step:
value:
version: 1
event: action.step
timeUtc: '2026-10-05T10:00:02.000Z'
client:
id: 4
name: Cloud Studio
facility:
id: 184
name: Oficina Madrid
device:
id: 6789
name: Sensor sala
endpoint:
id: 98765
name: Humedad
value: 41.5
action:
id: 222
name: Avisar por webhook
trigger: Greater
alarm: null
responses:
2XX:
description: Delivered. The body of the response is ignored.
4XX:
description: Not delivered and not retried, except 408 and 429, which are retried.
5XX:
description: Not delivered. Retried up to 3 attempts in total.
alarm.opened:
post:
operationId: alarmOpenedWebhook
tags:
- Webhooks
summary: An alarm of the alert opened
description: 'Sent in the background when an alarm of the alert opens. `value` is the
reading that opened it, when the alert watches an endpoint with a numeric
value.'
security: []
parameters:
- $ref: '#/components/parameters/XGearEvent'
- $ref: '#/components/parameters/XGearSignature'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/WebhookPayload'
examples:
alarm_opened:
value:
version: 1
event: alarm.opened
timeUtc: '2026-10-05T10:00:00.000Z'
client:
id: 4
name: Cloud Studio
facility:
id: 184
name: Oficina Madrid
device:
id: 6789
name: Sensor sala
endpoint:
id: 98765
name: Humedad
value: 41.5
action: null
trigger: null
alarm:
id: 1151916
alertId: 1052
description: Humidity greater than 40%
severity: 2
test: false
responses:
2XX:
description: Delivered. The body of the response is ignored.
4XX:
description: Not delivered and not retried, except 408 and 429, which are retried.
5XX:
description: Not delivered. Retried up to 3 attempts in total.
alarm.closed:
post:
operationId: alarmClosedWebhook
tags:
- Webhooks
summary: An alarm of the alert closed
description: Sent in the background when the alarm closes. `value` is `null`.
security: []
parameters:
- $ref: '#/components/parameters/XGearEvent'
- $ref: '#/components/parameters/XGearSignature'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/WebhookPayload'
examples:
alarm_closed:
value:
version: 1
event: alarm.closed
timeUtc: '2026-10-05T10:20:00.000Z'
client:
id: 4
name: Cloud Studio
facility:
id: 184
name: Oficina Madrid
device:
id: 6789
name: Sensor sala
endpoint:
id: 98765
name: Humedad
value: null
action: null
trigger: null
alarm:
id: 1151916
alertId: 1052
description: Humidity greater than 40%
severity: 2
test: false
responses:
2XX:
description: Delivered. The body of the response is ignored.
4XX:
description: Not delivered and not retried, except 408 and 429, which are retried.
5XX:
description: Not delivered. Retried up to 3 attempts in total.
alarm.acknowledged:
post:
operationId: alarmAcknowledgedWebhook
tags:
- Webhooks
summary: An alarm of the alert was acknowledged
description: 'Sent in the background when someone acknowledges the alarm (marks it as
seen). `value` is `null`.'
security: []
parameters:
- $ref: '#/components/parameters/XGearEvent'
- $ref: '#/components/parameters/XGearSignature'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/WebhookPayload'
examples:
alarm_acknowledged:
value:
version: 1
event: alarm.acknowledged
timeUtc: '2026-10-05T10:05:00.000Z'
client:
id: 4
name: Cloud Studio
facility:
id: 184
name: Oficina Madrid
device:
id: 6789
name: Sensor sala
endpoint:
id: 98765
name: Humedad
value: null
action: null
trigger: null
alarm:
id: 1151916
alertId: 1052
description: Humidity greater than 40%
severity: 2
test: false
responses:
2XX:
description: Delivered. The body of the response is ignored.
4XX:
description: Not delivered and not retried, except 408 and 429, which are retried.
5XX:
description: Not delivered. Retried up to 3 attempts in total.
components:
schemas:
WebhookPayload:
type: object
description: 'Version 1 of the body. Both kinds of event carry the same fields; what
does not apply is always `null`. A webhook can be set up with its own
body template instead (for Teams, Slack or another format), and then
the body is whatever that template produces.
'
required:
- version
- event
- timeUtc
- client
- facility
- device
- endpoint
- value
- action
- trigger
- alarm
properties:
version:
type: integer
const: 1
event:
type: string
enum:
- action.step
- alarm.opened
- alarm.closed
- alarm.acknowledged
timeUtc:
type: string
format: date-time
client:
$ref: '#/components/schemas/WebhookEntity'
facility:
$ref: '#/components/schemas/WebhookEntity'
device:
$ref: '#/components/schemas/WebhookEntity'
endpoint:
$ref: '#/components/schemas/WebhookEntity'
value:
type:
- number
- 'null'
description: 'In `action.step`, the reading of the endpoint that triggered the
action. In `alarm.opened`, the reading that opened the alarm, when
the alert watches an endpoint with a numeric value. `null` otherwise.
'
action:
description: The action whose step sent the event. Only in `action.step`.
$ref: '#/components/schemas/WebhookEntity'
trigger:
type:
- string
- 'null'
description: 'Only in `action.step`: the condition of the action''s trigger, such as
`Equal`, `Greater`, `LowerOrEqual` or `ValueChanged`. `null` when the
action has no trigger with a condition (run by hand or on a schedule).
'
alarm:
description: The alarm. Only in the `alarm.*` events.
oneOf:
- $ref: '#/components/schemas/WebhookAlarm'
- type: 'null'
test:
type: boolean
const: true
description: 'Present only in the sample sent by a "Test" button. A real event
does not carry the field at all.
'
WebhookAlarm:
type: object
required:
- id
- alertId
- description
- severity
- test
properties:
id:
type: integer
alertId:
type: integer
description: The alert that opened the alarm.
description:
type: string
description: The text of the alert, in the language of the facility.
severity:
type: integer
test:
type: boolean
description: True for the alarms of the commissioning test window.
WebhookEntity:
type:
- object
- 'null'
required:
- id
- name
properties:
id:
type: integer
name:
type: string
parameters:
XGearSignature:
name: X-Gear-Signature
in: header
required: false
description: 'Only when the webhook has a secret: `sha256=` and the HMAC-SHA256 of the
raw body in lowercase hex, keyed with the secret. See the Webhooks tag
for how to verify it.
'
schema:
type: string
pattern: ^sha256=[0-9a-f]{64}$
XGearEvent:
name: X-Gear-Event
in: header
required: true
description: The event, the same value as `event` in the body.
schema:
type: string
enum:
- action.step
- alarm.opened
- alarm.closed
- alarm.acknowledged
securitySchemes:
bearerToken:
type: http
scheme: bearer
description: 'Persistent access token sent as `Authorization: Bearer {accessToken}`.'
accessTokenQuery:
type: apiKey
in: query
name: accessToken
description: The same access token in the query string, for clients that cannot set headers.
externalDocs:
description: Data Extraction APIs documentation
url: https://cloudstudioiot.com/docs/apis-de-extraccion-de-datos