TextQL Sandcastles API

Manage Python sandbox environments for code execution

Operations 14

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /v2/sandcastles List my organization's sandcastles · List Sandcastles #
Ask an LLM
“Which Python sandcastles are running in my TextQL organization?”
“Can I list only stopped sandboxes?”
Tell an agent
List sandcastles with status {status}.
Show the next {limit} sandcastles after cursor {cursor}.
POST /v2/sandcastles Start or restart a sandcastle · Start Sandcastle #
Ask an LLM
“How do I spin up a fresh Python sandbox for running code?”
“Can I restart an existing sandcastle instead of creating a new one?”
Tell an agent
Start a new sandcastle.
Restart sandcastle {sandbox_id}.
GET /v2/sandcastles/{id} Check a sandcastle's status and memory · Get Sandcastle Status #
Ask an LLM
“How much memory is my sandbox using right now?”
“Which dataframes are loaded in a sandcastle?”
Tell an agent
Get the status of sandcastle {id}.
Show memory usage and loaded dataframes for sandbox {id}.
DELETE /v2/sandcastles/{id} Stop and destroy a sandcastle · Stop Sandcastle #
Ask an LLM
“How do I shut down a sandcastle I'm done with?”
“Can I still read a sandbox's execution history after it is stopped?”
Tell an agent destructive · confirm first
Stop sandcastle {id}.
Destroy the running sandbox {id}.
GET /v2/sandcastles/{id}/executions List executions run in a sandcastle · List Executions #
Ask an LLM
“What code has been run in my sandcastle so far?”
“Does the execution log include SQL and bash runs as well as Python?”
Tell an agent
List executions in sandcastle {id}.
Show the latest {limit} runs in sandbox {id}.
POST /v2/sandcastles/{id}/execute Run Python code in a sandcastle · Execute Code #
Ask an LLM
“How do I run Python in a sandcastle and get stdout back?”
“Does Python run in a persistent kernel so variables survive between calls?”
Tell an agent
Run Python {code} in sandcastle {id}.
Execute this Python snippet in sandbox {id}: {code}
POST /v2/sandcastles/{id}/query Load connector data into a sandcastle dataframe · Load Connector Data #
Ask an LLM
“How do I pull query results from a connector into a sandbox dataframe?”
“Can I run a saved .tql file instead of inline SQL when loading data?”
Tell an agent
Load {query} from connector {connector_id} into sandcastle {id}.
Run saved TQL {tql_path} on connector {connector_id} into dataframe {dataframe_name} in sandbox {id}.
GET /v2/sandcastles/{id}/files List files in a sandcastle directory · List Files #
Ask an LLM
“What files are in my sandbox's working directory?”
“Can I browse a subfolder of the sandcastle, like the mounted library?”
Tell an agent
List files in sandcastle {id}.
List the {path} directory inside sandbox {id}.
POST /v2/sandcastles/{id}/files Upload a file to a sandcastle · Upload File #
Ask an LLM
“How do I put a CSV into my sandbox so Python can read it?”
“Can I upload a file directly into a sandcastle's working directory?”
Tell an agent
Upload {file} to sandcastle {id}.
Send file {file} into sandbox {id}'s working directory.
GET /v2/sandcastles/{id}/files/{path} Download a file from a sandcastle · Download File #
Ask an LLM
“How do I download a chart or output file my sandbox generated?”
“Can I fetch a file from a nested folder in the sandcastle?”
Tell an agent
Download {path} from sandcastle {id}.
Fetch the bytes of file {path} in sandbox {id}.
DELETE /v2/sandcastles/{id}/files/{path} Delete a file from a sandcastle · Delete File #
Ask an LLM
“How do I remove a file from my sandbox's working directory?”
“Can I delete a whole directory in a sandcastle with one call?”
Tell an agent destructive · confirm first
Delete {path} from sandcastle {id}.
Remove file {path} in sandbox {id}.
POST /v2/sandcastles/{id}/exec Run a one-shot shell command in a sandcastle · Exec Command #
Ask an LLM
“Can I run a bash command in my sandbox as a fresh process?”
“Do shell commands share state with the Python kernel in a sandcastle?”
Tell an agent
Run command {command} in sandcastle {id}.
Exec {command} in sandbox {id} with environment {env}.
GET /v2/sandcastles/{id}/ontology/diff Preview pending Ontology edits in a sandcastle · Diff Ontology (dry run) #
Ask an LLM
“Has my sandbox changed any files in its mounted Ontology library?”
“Can I dry-run the diff before writing sandbox edits back to the Ontology?”
Tell an agent
Diff the Ontology mount in sandcastle {id}.
Show pending library changes in sandbox {id} without authoring a change.
POST /v2/sandcastles/{id}/ontology/changes Write sandcastle Ontology edits back as a change · Create Ontology Change (writeback) #
Ask an LLM
“How do I save library edits from my sandbox back to the organization's Ontology?”
“Can I open the writeback change as a draft for review?”
Tell an agent
Create an Ontology change from sandcastle {id} titled {title}.
Write back sandbox {id}'s library edits as a draft described as {description}.

Documentation

Specifications

Other Resources

Work with this as data

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/textql:textql-sandcastles-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

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. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

textql-sandcastles-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: TextQL v2 Sandcastles API
  version: '2.0'
  description: REST API for TextQL platform operations. All endpoints require Bearer token authentication.
servers:
- url: https://app.textql.com
security:
- bearerAuth: []
tags:


# --- truncated at 32 KB (37 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/textql/refs/heads/main/openapi/textql-sandcastles-api-openapi.yml