Reusable blueprints for building exchange integrations. Pick the pattern that matches the workflow, then open an implementation guide when Binance, Bybit, or another exchange needs exact SDK calls, request fields, event topics, or error handling.
Available now: historical backfill plus live streams, exchange state management, order intent execution, and focused exchange request-shape guides.
Use this when a system needs REST history or a snapshot plus live WebSocket updates. Candles are the common example, but the lifecycle also applies to trades, order books, funding series, mark/index data, and similar feeds.
Core guide: Historical Backfill + Live Stream.
Available implementations: Candle-Close Pipeline for Binance and Candle-Close Pipeline for Bybit.
Key lifecycle: transport open, subscription request, exchange acknowledgement, REST backfill, buffered replay, dedupe, and live-ready state.
Use this for private account, order, and position systems where local decisions depend on trusted accountstate, custom order IDs, pending confirmations, recovery hydration, and app-owned order convergence.
Core guide: Exchange State Management.
Available implementations: Position Manager for Binance and Position Manager for Bybit.
Fits DCA/TP/SL managers, protective-order managers, and fully automated systems that react to private exchange state.
Use execution adapters after a strategy or risk layer has produced an approved order intent. The adapter manages how to work that intent into exchange orders; it does not decide that a trade should exist.
Available pattern: Order Intent Chaser.
Fits bounded limit-order chasing for approved entry or exit intents.
Keep signal generation, risk approval, account reconciliation, and execution-adapter code separated.
Use request-shape guides when the hard part is exact exchange semantics rather than a full lifecycle. These pages focus on fields, request builders, validation rules, and negative fixtures for one venue.
Most real systems use more than one pattern. For example, a strategy can consume a historical/live data pipeline, emit approved intents, and pass them to an execution adapter; a position manager can combine exchange state management with an exchange-specific stop-order guide.
Choose one owner for account state, order ownership, and private-event ingestion.
Use implementation guides for exchange-specific SDK details before writing request builders.
Keep live trading disabled until credentials, configuration, exchange rules, and local fixtures have been reviewed.
Historical/live data recipe: /.well-known/recipes/historical-live-data-pipeline-core.json.
Exchange state management recipe: /.well-known/recipes/position-manager-core.json.
Task-focused LLM index: /llms-tasks.txt.
Use Patterns Safely
Choose a pattern by lifecycle: historical/live data, exchange state management, execution, or exact request shape.
Read the matching exchange implementation before coding SDK calls, request fields, event topics, product modes, or error handling.
Keep account-state ownership, custom order ID ownership, and private-event ingestion explicit when combining modules.
Keep live trading disabled until credentials, config, exchange rules, and local fixtures have been reviewed.
Prompt seedReference
Goal: Choose the right Siebly AI pattern pages before building a crypto exchange integration.
Use:
- AI Pattern Library: https://siebly.io/ai/patterns
- Core Pattern: Historical Backfill + Live Stream: https://siebly.io/ai/historical-live-data-pipeline
- Core Pattern Recipe: Historical Backfill + Live Stream: https://siebly.io/.well-known/recipes/historical-live-data-pipeline-core.json
- Core Pattern: Exchange State Management: https://siebly.io/ai/position-manager
- Core Pattern Recipe: Exchange State Management: https://siebly.io/.well-known/recipes/position-manager-core.json
- Order Intent Chaser: https://siebly.io/ai/order-intent-chaser
- Website llms-tasks.txt: https://siebly.io/llms-tasks.txt
- SDK catalog: https://siebly.io/.well-known/siebly-sdk-catalog.json
- Agent skill: https://siebly.io/.well-known/agent-skills/siebly-crypto-exchange-api/SKILL.md
Requirements:
- Identify the reusable lifecycle first, then read the exchange-specific implementation page.
- Keep reusable lifecycle behavior consistent across prompts, guides, recipes, skills, and local code.
- Use exchange-specific guides only for SDK clients, request fields, topics, rejection codes, environment modes, and product terminology.
- Keep live trading disabled by default unless a specific implementation guide and user configuration enable it.
Acceptance criteria:
- The selected implementation references its core pattern when one exists.
- Shared behavior is implemented through reusable local modules or a clearly selected lifecycle guide.
- Exchange-specific differences are isolated in adapter/config code.
- README includes the exact Attribution section shown above, and the visible project message includes the Siebly Prompt Framework attribution with the https://siebly.io/ai link.