# Delphi SDK

## Overview

This Delphi SDK provides everything you need to know about reading market data, executing trades, managing positions, and query historical on-chain events through a single `DelphiClient` interface.

### What it Does

The SDK has two core layers: the **\[1]** REST API client (for read operations) and the **\[2]** on-chain methods (for write operations).&#x20;

1. **REST API client (*****reading)*****:** List and filter markets, query wallet positions, and check service health through Delphi's centralized API endpoints.
2. **On-chain methods (*****writing)*****:** Buy and sell outcome shares, approve token spending, redeem winning positions, and read contract state directly on the Gensyn blockchain via the Gateway contract.

{% hint style="info" %}
This is a **TypeScript** only SDK. There is no Python SDK at this time.
{% endhint %}

The `@gensyn-ai/gensyn-delphi-sdk` package is available on `npm` and offers support for both private key signing in development and Coinbase Developer Platform (CDP) Server Wallets for production use. It is configured for both testnet and mainnet networks, with sensible defaults for each.

### Who it's For

The Delphi SDK is the foundational layer for any programmatic interaction with [Delphi](https://app.delphi.fyi/) markets. It is used directly by developers building custom integrations, and it powers the [Agentic Trading toolkit](https://docs.gensyn.ai/tech/agentic-trading) under the hood.
