stackql
Open source SQL-native query and provisioning engine for cloud and SaaS infrastructure. Ships as a single signed binary with MCP tools for provider discovery, schema exploration, queries, and lifecycle operations.
README
<!-- web assets -->
[logo]: https://stackql.io/img/stackql-logo-bold.png "stackql logo"
[homepage]: https://stackql.io/
[docs]: https://stackql.io/docs
[blog]: https://stackql.io/blog
[registry]: https://github.com/stackql/stackql-provider-registry
[variables]: https://stackql.io/docs/getting-started/variables
[macpkg]: https://storage.googleapis.com/stackql-public-releases/latest/stackql_darwin_multiarch.pkg
[winmsi]: https://releases.stackql.io/stackql/latest/stackql_windows_amd64.msi
[winzip]: https://releases.stackql.io/stackql/latest/stackql_windows_amd64.zip
[tuxzip]: https://releases.stackql.io/stackql/latest/stackql_linux_amd64.zip
<!-- docker links -->
[dockerhub]: https://hub.docker.com/u/stackql
[dockerstackql]: https://hub.docker.com/r/stackql/stackql
[dockerjupyter]: https://hub.docker.com/r/stackql/stackql-jupyter-demo
<!-- github actions links -->
[setupaction]: https://github.com/marketplace/actions/stackql-studios-setup-stackql
[execaction]: https://github.com/marketplace/actions/stackql-studios-stackql-exec
<!-- badges -->
[badge1]: https://img.shields.io/badge/platform-windows%20macos%20linux-brightgreen "Platforms"
[badge2]: https://github.com/stackql/stackql/workflows/Go/badge.svg "Go"
[badge3]: https://img.shields.io/github/license/stackql/stackql "License"
[badge4]: https://img.shields.io/tokei/lines/github/stackql/stackql "Lines"
<!-- github links -->
[issues]: https://github.com/stackql/stackql/issues/new?assignees=&labels=bug&template=bug_report.md&title=%5BBUG%5D
[features]: https://github.com/stackql/stackql/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=%5BFEATURE%5D
[developers]: /docs/developer_guide.md
[registrycont]: /docs/registry_contribution.md
[designdocs]: /docs/high-level-design.md
[contributing]: /CONTRIBUTING.md
[discussions]: https://github.com/orgs/stackql/discussions
<!-- repo assets -->
[darkmodeterm]: /docs/images/stackql-light-term.gif#gh-dark-mode-only
[lightmodeterm]: /docs/images/stackql-dark-term.gif#gh-light-mode-only
<!-- misc links -->
[twitter]: https://twitter.com/stackql
<!-- language: lang-none --> <div align="center">
[![logo]][homepage]
![badge1]
![badge2]
![badge3]
![badge4]
</div>
<div align="center">
</div> <div align="center">
Deploy, manage and query cloud resources and interact with APIs using SQL
<!-- <h3 align="center">SQL based XOps, observability and middleware framework</h3> -->
<p align="center">
[Read the docs »][docs]
[Raise an Issue][issues] ·
[Request a Feature][features] ·
[Developer Guide][developers] ·
[BYO Providers][registrycont]
</p> </div>
<details open="open"> <summary>Contents</summary> <ol> <li><a href="#about-the-project">About The Project</a></li> <li><a href="#installation">Installation</a></li> <li><a href="#usage">Usage</a></li> <!-- <li><a href="#roadmap">Roadmap</a></li> --> <li><a href="#contributing">Contributing</a></li> <li><a href="#license">License</a></li> <li><a href="#contact">Contact</a></li> <li><a href="#acknowledgements">Acknowledgements</a></li> </ol> </details>
About The Project
[StackQL][homepage] is an open-source project built with Golang that allows you to create, modify and query the state of services and resources across different local and remote interfaces, using SQL semantics. Such interfaces canonically include, but are not limited to, cloud and SaaS providers (Google, AWS, Azure, Okta, GitHub, etc.). <br /> <br />
![stackql-shell][darkmodeterm] ![stackql-shell][lightmodeterm]
How it works
StackQL is a standalone application that can be used in client mode (via exec or shell) or accessed via a Postgres wire protocol client (psycopg2, etc.) using server mode (srv).
StackQL parses SQL statements and transpiles them into API requests to the (cloud) resource provider. The API calls are then executed and the results are returned to the user.
StackQL provider interfaces are canonically defined in OpenAPI extensions to the providers' specification. These definitions are then used to generate the SQL schema and the API client. The source for the provider definitions are stored in the [StackQL Registry][registry]. The semantics of provider interactions are defined in our any-sdk library. For more detail on nuts and bolts, please see the local AGENTS.md file and that of any-sdk.
<details> <summary><b>StackQL Context Diagram</b></summary> <br /> The following context diagram describes the StackQL architecture at a high level:
<!-- -->
flowchart LR
subgraph StackQL
direction BT
subgraph ProviderDefs
Registry[Provider Registry Docs]
end
subgraph App
Proc[$ stackql exec\n$ stackql shell\n$ stackql srv]
style Proc fill:#000,stroke:#000,color:#fff,text-align:left;
%% ,font-family:'Courier New', Courier, monospace
end
end
User((User)) <--> StackQL <--> Provider[Cloud Provider API]
ProviderDefs --> App
More detailed design documentation can be found in the [here][designdocs].
</details>
Installation
StackQL is available for Windows, MacOS, Linux, Docker, GitHub Actions and more. See the installation instructions below for your platform.
<details> <summary><b>Installing on MacOS</b></summary>
- Homebrew (
amd64andarm64)brew install stackqlorbrew tap stackql/tap && brew install stackql/tap/stackql
- MacOS PKG Installer (
amd64andarm64)- download the latest [MacOS PKG installer for StackQL][macpkg]
- run the installer and follow the prompts
</details>
<details> <summary><b>Installing on Windows</b></summary>
- MSI Installer
- download the latest [MSI installer for StackQL][winmsi]
- run the installer and follow the prompts
- Chocolatey
- install Chocolatey
- run
choco install stackql
- ZIP Archive
- download the latest [Windows ZIP archive for StackQL][winzip]
- extract the archive (code signed
stackql.exefile) to a directory of your choice - add the directory to your
PATHenvironment variable (optional)
</details>
<details> <summary><b>Installing on Linux</b></summary>
- ZIP Archive
- download the latest [Linux ZIP archive for StackQL][tuxzip]
- or via
curl -L https://bit.ly/stackql-zip -O && unzip stackql-zip
- or via
- extract the archive (
stackqlfile) to a directory of your choice - add the directory to your
PATHenvironment variable (optional)
- download the latest [Linux ZIP archive for StackQL][tuxzip]
</details>
<details> <summary><b>Getting StackQL from DockerHub</b></summary>
View all available StackQL images on [DockerHub][dockerhub]. Images available include [
stackql][dockerstackql], [stackql-jupyter-demo][dockerjupyter] and more. Pull the latest StackQL base image using:
docker pull stackql/stackql
</details>
<details> <summary><b>Using StackQL with GitHub Actions</b></summary>
Use StackQL in your GitHub Actions workflows to automate cloud infrastructure provisioning, IaC assurance, or compliance/security. Available GitHub Actions include: [
setup-stackql][setupaction], [stackql-exec][execaction] and more
</details>
Usage
StackQL can be used via the interactive REPL shell, or via the exec command or ran as a server using the Postgres wire protocol.
ℹ️ StackQL does not require or install a database.
-
Interactive Shell
# run interactive stackql queries stackql shell --auth="${AUTH}" -
Execute a statement or file
stackql exec --auth="${AUTH}" -i myscript.iql --iqldata vars.jsonnet --output json # or stackql exec --auth="${AUTH}" "SELECT id, status FROM aws.ec2.instances WHERE region = 'us-east-1'"ℹ️ output options of
json,csv,tableandtextare available for theexeccommand using the--outputflagℹ️ StackQL supports passing parameters using
jsonnetorjson, see [Using Variables][variables] -
Server
# serve client requests over the Postgres wire protocol (psycopg2, etc.) stackql srv --auth="${AUTH}"
For more examples, please check our [Blog][blog]
<!-- ## Roadmap
See our roadmap to see where we are going with the project. -->
Contributing
Contributions are welcome and encouraged. For more information on how to contribute, please see our [contributing guide][contributing].
License
Distributed under the MIT License. See LICENSE for more information. Licenses for third party software we are using are included in the /docs/licenses directory.
Contact
Get in touch with us via Twitter at [@stackql][twitter], email us at info@stackql.io or start a conversation using [discussions][discussions].
Acknowledgements
Forks of the following support our work:
- vitess
- kin-openapi
- gorilla/mux
- readline
- psql-wire
- mcp-postgres
- the
golangMCP SDK - ...and more. Please excuse us for any omissions.
We gratefully acknowledge these pieces of work.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.