Overview
The Meter API provides programmatic access to the Dashboard via GraphQL. It complements the Dashboard by enabling custom scripts, internal integrations, and automated workflows where API access is the better fit.
GraphQL basics
The API uses GraphQL, a query language that lets you request exactly the data you need.
- Schema: the schema defines every type, field, and query available in the API. Introspection is disabled, so use the schema reference to explore what's available.
- Query: a read operation that fetches data. You specify which fields you want and the response matches that shape.
- Field: a unit of data on a type. Every query must select fields down to scalar values (like
StringorUUID). - Argument: a key-value pair passed to a query or field to filter or configure the result. For example,
networkUUIDtells the API which network to query. - Type: a named object with its own set of fields. For example,
VirtualDevicehas fields likelabel,deviceModel, andisOnline.
The GraphQL endpoint
The endpoint remains constant no matter what operation you perform. All requests must be HTTP POST with a JSON body containing a query field.
https://api.meter.com/api/v1/graphql
Create an API key
Navigate to Settings > Integrations > API keys in the Dashboard to create a new API key. Copy and securely store the key—it is only shown once.
Make your first query
You can use any HTTP client to send queries to the API. The example below uses curl to fetch all devices on a network.
curl -X POST https://api.meter.com/api/v1/graphql \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"query": "{
virtualDevicesForNetwork(networkUUID: \"YOUR_NETWORK_UUID\") {
UUID
label
deviceType
deviceModel
isOnline
}
}"
}'Related resources
Need help?
If you run into any issues or have questions, please reach out to our Support Engineering team by opening a ticket via the Dashboard: https://dashboard.meter.com/support