Cambrian Pool Transaction Feed (Time Bounded) API

By Cambrian Network solana

GET /api/v1/solana/pool-transactions-time-bounded

Pool Transactions (Time-Bounded)

This endpoint retrieves historical pool transactions within a specified time range for Solana pools. It provides comprehensive transaction data for pools during specific time periods, allowing analysis of trading activity and volume patterns.

Business Value

  • Trading Analysis: Track pool trading activity and volume patterns over specific time periods
  • Performance Monitoring: Monitor pool performance and liquidity changes during chosen intervals
  • Historical Research: Access detailed transaction history for backtesting and market analysis
  • Risk Assessment: Analyze transaction patterns to understand pool behavior during market events
  • Strategy Development: Use historical data to develop and validate trading strategies

Endpoint Details

URL:

https://opabinia.cambrian.network/api/v1/solana/pool-transactions-time-bounded

Method: GET
Authentication: Required via X-API-Key header

Query Parameters

Parameter Type Required Default Description
pool_address string Yes - Pool address (base58-44 string)
after_time integer Yes - Unix timestamp - start time for data range
before_time integer Yes - Unix timestamp - end time for data range
limit integer No - Limit the number of results
offset integer No - Offset the results, allows you to skip a number of rows before starting to return rows

Response Field Descriptions

Response Field Type Description
columns array Column metadata defining the structure of returned data
data array Array of data rows containing transaction information
rows integer Number of rows returned in the response

Note: When transactions are found, the columns array will define specific fields such as transaction signature, timestamp, amounts, and other transaction details. The data array contains the actual transaction records.

Examples

1. Query Pool Transactions for Time Range

This example demonstrates how to retrieve pool transactions for a specific time period.

curl -X GET "https://opabinia.cambrian.network/api/v1/solana/pool-transactions-time-bounded?pool_address=2AQdpHJ2JpcEgPiATUXjQxA8QmafFegfQwSLWSprPicm&after_time=1735689600&before_time=1735776000&limit=5" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

Response:

[{"columns":[],"data":[],"rows":0}]

The response shows no transactions were found for the specified pool and time range. When transactions exist, the columns array will contain metadata about each field, and the data array will contain the transaction records.

2. Query with Pagination

This example shows how to use offset and limit parameters for paginated results.

curl -X GET "https://opabinia.cambrian.network/api/v1/solana/pool-transactions-time-bounded?pool_address=HJPjoWUrhoZzkNfRpHuieeFk9WcZWjwy6PBjZ81ngndJ&after_time=1700000000&before_time=1700086400&limit=10&offset=0" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

Response:

[{"columns":[],"data":[],"rows":0}]

This query includes pagination parameters to limit results to 10 transactions and start from the first record (offset=0).

x402 Payment Option

This endpoint supports pay-per-use access via the x402 payment protocol (v2) — pay $0.05 USDC per request using blockchain micropayments. No API key required.

Quick Start (TypeScript)

npm install @x402/fetch @x402/evm viem
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { wrapFetchWithPayment } from "@x402/fetch";
import { privateKeyToAccount } from "viem/accounts";

const signer = privateKeyToAccount(process.env.EVM_PRIVATE_KEY as `0x${string}`);
const client = new x402Client();
client.register("eip155:*", new ExactEvmScheme(signer));

const fetchWithPayment = wrapFetchWithPayment(fetch, client);
const response = await fetchWithPayment(
  "https://deep42.cambrian.network/api/v1/solana/pool-transactions-time-bounded"
);
const data = await response.json();

Quick Start (Python)

pip install "x402[httpx]"
import asyncio, os
from eth_account import Account
from x402 import x402Client
from x402.http.clients import x402HttpxClient
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client

async def main():
    client = x402Client()
    account = Account.from_key(os.getenv("EVM_PRIVATE_KEY"))
    register_exact_evm_client(client, EthAccountSigner(account))

    async with x402HttpxClient(client) as http:
        response = await http.get("https://deep42.cambrian.network/api/v1/solana/pool-transactions-time-bounded")
        print(response.json())

asyncio.run(main())

Payment Flow

  1. Send a normal request to the endpoint (no API key needed)
  2. Server returns 402 Payment Required with payment details
  3. The x402 SDK automatically signs a payment authorization with your wallet
  4. The SDK resubmits the request with the signed payment
  5. Server verifies payment and returns the API response

The x402 SDK handles steps 2–5 automatically.

Network: Base (chain ID 8453) | Currency: USDC | Price: $0.05 per request


Related Endpoints

  • /api/v1/solana/pool-transactions - Retrieve general pool transaction data without time constraints
  • /api/v1/solana/ohlcv/pool - Get OHLCV (Open, High, Low, Close, Volume) data for pools
  • /api/v1/solana/orca/pools - Access comprehensive Orca pool information and metrics
  • /api/v1/solana/orca/pool - Get detailed information for specific Orca pools