SShortSingh.
Back to feed

How to Query Stellar's Horizon API Using Python and JavaScript

0
·1 views

Developer André Dias Moreira Prol has shared a practical guide on querying the Stellar blockchain's Horizon REST API using Python and JavaScript, drawing on his experience with tokenization and digital forensics projects. Horizon exposes account, transaction, asset, and operation data in JSON format, with built-in HAL-standard pagination that simplifies large-scale data retrieval. In Python, the requests library or the official stellar-sdk can be used to fetch balances and asset records, while JavaScript developers can leverage fetch and Server-Sent Events for real-time payment streaming. Prol notes that SSE-based streaming eliminated the need for constant polling in a digital wallet project, cutting infrastructure costs by around 30%. He emphasizes that Horizon handles read operations only, and transaction submission still requires local signing via an SDK before posting to the /transactions endpoint.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Study: 84% of AI-authored Pull Requests Lack Meaningful Human Review

A peer-reviewed study presented at EASE 2026 analyzed over 33,500 AI-generated pull requests on GitHub and found that 84% showed no meaningful human review activity when bot interactions were included. Researchers also found that only 65.5% of human comments on AI pull requests contained genuine review content, with roughly a quarter being instructions directing the agent rather than evaluating the code. Industry data from 8.1 million pull requests across 4,800 organizations showed that while developers felt 20% faster, actual delivery performance slowed by 19%, and review time surged 91%. The core issue identified is not which branching model teams use, but a widening gap where generating code has become cheap while verifying it has not. Experts argue the priority should be strengthening review gates and oversight practices, not redesigning Git workflows to accommodate AI agents.

0
ProgrammingDEV Community ·

Two AI Agents Built a Slovenian Folk-Hero Browser Game in Four Days

A developer used Claude Code and OpenAI's Codex over four days to build a playable browser demo of a point-and-click adventure based on Martin Krpan, a Slovenian folk hero known for smuggling salt. The project produced 108 commits, 92 tests, and 111 voiced lines of dialogue, running on the Godot 4.7.2 engine. The two AI agents divided responsibilities — Claude handled game code and orchestration while Codex generated artwork and independent code reviews — with the developer approving key design decisions throughout. A persistent challenge was rendering the 300-pixel protagonist correctly, as the character's arms and head repeatedly appeared misaligned in the animated rig. The released Act I demo is described as a rough but functional first chapter, with four additional acts planned once this segment is polished.

0
ProgrammingDEV Community ·

How to Query Stellar Horizon API Using Python and JavaScript

Developer André Dias Moreira Prol has published a practical guide on querying the Stellar blockchain network using the Horizon REST API in both Python and JavaScript. The article explains how to retrieve account balances, transaction histories, and asset data through clean HTTP endpoints without requiring deep blockchain protocol knowledge. Prol highlights the Horizon API's streaming capability via Server-Sent Events, which enables real-time transaction monitoring without constant polling, reducing infrastructure costs. The guide also covers querying tokenized assets like USDC, including how to retrieve the number of wallets holding a given asset's trustlines. Code samples using the official stellar-sdk library are provided for both languages and are ready to run against the live Stellar network.

0
ProgrammingDEV Community ·

Why .NET and MAUI Developers Need to Think Beyond Code to System Design

System design is not just for architects — every .NET and .NET MAUI developer makes architectural decisions, whether they recognize it or not. The article outlines a progression from basic client-server and REST API understanding to advanced concerns like scalability, fault tolerance, and cloud architecture. Mobile applications add unique challenges such as offline support, data sync conflicts, and background processing restrictions that require deliberate design strategies. Techniques like circuit breakers, retries, idempotency, and message queues are highlighted as essential tools for building resilient production systems. The piece argues that thoughtful, incremental system design — rather than jumping to microservices — leads to more maintainable and reliable applications as they grow.