---
title: "Use SQL in a RESTful way"
method: GET
path: "/SQL"
tags: ["query"]
---

# Use SQL in a RESTful way

`GET /SQL`

API exposed for sending SQL queries directly against the chainquery database. Since this is an exposed API there are limits to its use. These limits include queries per hour, read-only, limited to 60 second timeout.

## Path parameters

- `query` string, required

## Response `200`

It will return the rows as a json array.

- object[]

## Other responses

- `400` — This is returned when the sql query has failed, either due to syntax issues with the query, nameing, priviledges etc. An error is provided with the response.

## Changes

> 4 revisions in range; 1 not diffed.

- **2018-05-06** `8d5ce2c7aa69` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/odyseeteam/apis/chain-query/changes/SQL/get.md)

---

[API](https://skmtc.dev/odyseeteam/apis/chain-query.md) · [All operations](https://skmtc.dev/odyseeteam/apis/chain-query/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/odyseeteam/chain-query/revisions/8d5ce2c7aa69/schema)
