rosssaunders
pg_deribit
PLpgSQL

This project provides a PostgreSQL wrapper for the Deribit API, enabling easy interaction with Deribit's cryptocurrency trading platform from PostgreSQL. Built on omnigres.

Last updated Mar 15, 2026
17
Stars
0
Forks
0
Issues
0
Stars/day
Attention Score
43
Language breakdown
PLpgSQL 96.3%
Python 3.0%
Shell 0.4%
Makefile 0.2%
Dockerfile 0.0%
Files click to expand
README

pg_deribit - Deribit API Wrapper for PostgreSQL

This project provides a PostgreSQL wrapper for the Deribit API, enabling easy interaction with Deribit's cryptocurrency trading platform from PostgreSQL. It's designed for developers and data analysts who want to integrate Deribit's features into PostgreSQL-based applications or perform complex data analysis.

Who is this for

Who is this for

Getting Started

Prerequisites

Quickstart

Run the following commands to start a fresh container using the pre-built image:
# stop and remove any existing container called pg_deribit
docker stop pg_deribit 2>/dev/null || true
docker rm -f pg_deribit 2>/dev/null || true

pull and run the latest image from GitHub Container Registry

docker run -d --name pg_deribit -p 5433:5432 \ -e POSTGRES_PASSWORD=deribitpwd \ -e POSTGRES_USER=deribit \ -e POSTGRES_DB=deribit \ ghcr.io/rosssaunders/pg_deribit:latest

connect to the container

PGPASSWORD=deribitpwd psql -h localhost -p 5433 -U deribit -d deribit

load the extension

create extension if not exists pg_deribit cascade;

test the extension

select currency from deribit.publicgetcurrencies() order by currency;

exit the container

\q
Connect using your favourite Postgres GUI and get going. For how to use it, see the examples in the doc folder.

Building from Source

If you want to build the Docker image from source (for development or customization):
# clone the repository
git clone https://github.com/rosssaunders/pg_deribit
cd pg_deribit

build the Docker image

docker build . -t pg_deribit

run the container

docker run -d --name pg_deribit -p 5433:5432 \ -e POSTGRES_PASSWORD=deribitpwd \ -e POSTGRES_USER=deribit \ -e POSTGRES_DB=deribit \ pg_deribit

connect to the container

PGPASSWORD=deribitpwd psql -h localhost -p 5433 -U deribit -d deribit

Usage

Refer to the docs folder for examples and the sql/endpoints folder for the full list of endpoints.

Contributing

Contributions are welcome! Please read our contributing guidelines in CONTRIBUTING.md before submitting pull requests.
🔗 More in this category

© 2026 GitRepoTrend · rosssaunders/pg_deribit · Updated daily from GitHub