Developers · GraphQL
GraphQL Data Overview
Last updated 1 November 2026
The GraphQL operations that read and write records, users and constants, with a worked example.
The data operations read and write the content your site stores: records in your tables, users, and constants. They are the queries and mutations you use most when you build pages on Insites.
Use them whenever a page lists, shows, creates or changes stored data. To change the instance's own code and setup, use the admin operations.
What is in this group
| Operation | Kind | What it does |
|---|---|---|
records | Query | Reads records from a table, with filter and sort |
users | Query | Reads users |
record_create | Mutation | Creates one record |
record_update | Mutation | Changes the properties you list. Others stay as they are |
record_delete | Mutation | Soft deletes one record and keeps it for 30 days |
records_create | Mutation | Creates many records in one operation, without validations or callbacks |
records_update_all | Mutation | Updates every record that matches a filter |
records_delete_all | Mutation | Soft deletes every record that matches a filter |
user_create, user_update, user_delete | Mutation | Change one user |
constant_set, constant_unset | Mutation | Set or remove a constant |
Example: read two records by slug
Query
{
records(
per_page: 5
filter: {
table: { value: "modules/website/developers_guide" }
properties: [{ name: "slug", value_in: ["layouts", "date-format"] }]
}
) {
total_entries
results {
id
slug: property(name: "slug")
title: property(name: "title")
}
}
}Response on the docs instance
{
"data": {
"records": {
"total_entries": 2,
"results": [
{ "id": "1465", "slug": "date-format", "title": "Date Format" },
{ "id": "1485", "slug": "layouts", "title": "Layouts" }
]
}
}
}This ran read-only on the docs.insites.io instance, whose pages are records in a table. property reads one value; use property_int, property_boolean or property_array for other types.
Common mistakes
- Leaving out
per_pageonrecordsorusers. It is required and has no default. - Passing a number as
valuewhen you write.valueis always a string, and a number fails the whole mutation. Usevalue_intorvalue_floatwhen the type matters. - Calling
record_deletewith onlyid. Passtabletoo, or the delete is refused. - Sorting by a property and expecting numeric order. Property sort compares text, so 10 comes before 2.
- Using
records_createfor form input. It skips validations and callbacks.