- Get Started
- Become an Anchor
- Stellar Attachment Convention
- Compliance Protocol
- Add Stellar to your Exchange
- Hardware Requirements
- Issuing Assets
- Build Stellar Apps
- Contribution Guide
XDR, also known as External Data Representation, is used throughout the Stellar network and protocol. The ledger, transactions, results, history, and even the messages passed between computers running stellar-core are encoded using XDR.
XDR is specified in RFC 4506 and is similar to tools like Protocol Buffers or Thrift. XDR provides a few important features:
Since XDR is a binary format and not as widely known as simpler formats like JSON, the Stellar SDKs all include tools for parsing XDR and will do so automatically when retrieving data.
In addition, the Horizon API server generally exposes the most important parts of the XDR data in JSON, so they are easier to parse if you are not using an SDK. The XDR data is still included (encoded as a base64 string) inside the JSON in case you need direct access to it.
Data structures in XDR are specified in an interface definition file (IDL). The IDL files used for the Stellar Network are available on GitHub.