Search…
Response Format
Horizon delivers responses as JSON objects formatted according to HAL. The HAL format makes Horizon more explorable, paginates responses, and connects parent and child resources. Consuming this format is simple using one of the many open source libraries available for most major programming languages.
HAL is just JSON with two reserved attribute names:
  • _links
  • _embedded
If a response is a single record, the _links section will provide links to any parent or child records, and there will be no _embedded property.
If a response is a collection, the _links section will provide pagination links, and the response’s list of records will be nested underneath the _embedded property.
- ATTRIBUTES - DATA TYPE - DESCRIPTION - \_links - array - Provides links for navigating to other pages or to parents and children. - \_embedded - array - Present when querying an endpoint that responds with a collection of records.
1
{
2
"_links": {
3
"self": {
4
"href": "https://horizon.stellar.org/accounts/GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ/payments?cursor=&limit=5&order=asc"
5
},
6
"next": {
7
"href": "https://horizon.stellar.org/accounts/GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ/payments?cursor=111764193027313665&limit=5&order=asc"
8
},
9
"prev": {
10
"href": "https://horizon.stellar.org/accounts/GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ/payments?cursor=111720727958269953&limit=5&order=desc"
11
}
12
},
13
"_embedded": {
14
"records": [
15
{
16
"_links": {
17
"self": {
18
"href": "https://horizon.stellar.org/operations/111720727958269953"
19
},
20
"transaction": {
21
"href": "https://horizon.stellar.org/transactions/4034838d5b47e4f8c23776faca4d9403637b1f037e436759b57fc892ae5cd96c"
22
},
23
"effects": {
24
"href": "https://horizon.stellar.org/operations/111720727958269953/effects"
25
},
26
"succeeds": {
27
"href": "https://horizon.stellar.org/effects?order=desc\u0026cursor=111720727958269953"
28
},
29
"precedes": {
30
"href": "https://horizon.stellar.org/effects?order=asc\u0026cursor=111720727958269953"
31
}
32
},
33
"id": "111720727958269953",
34
"paging_token": "111720727958269953",
35
"transaction_successful": true,
36
"source_account": "GAR4S3ASZ4HTJ6GQ2DEDLVL4YE6D64UPIOQI4I67L5VPYBGEZDGOI462",
37
"type": "create_account",
38
"type_i": 0,
39
"created_at": "2019-09-26T12:34:24Z",
40
"transaction_hash": "4034838d5b47e4f8c23776faca4d9403637b1f037e436759b57fc892ae5cd96c",
41
"starting_balance": "20.0000000",
42
"funder": "GAR4S3ASZ4HTJ6GQ2DEDLVL4YE6D64UPIOQI4I67L5VPYBGEZDGOI462",
43
"account": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ"
44
},
45
{
46
"_links": {
47
"self": {
48
"href": "https://horizon.stellar.org/operations/111721376498331649"
49
},
50
"transaction": {
51
"href": "https://horizon.stellar.org/transactions/cbf92ce9e2b75b0182597acb1e7c0b58695ec6f69e84a8625c5ab1dda8df31bc"
52
},
53
"effects": {
54
"href": "https://horizon.stellar.org/operations/111721376498331649/effects"
55
},
56
"succeeds": {
57
"href": "https://horizon.stellar.org/effects?order=desc\u0026cursor=111721376498331649"
58
},
59
"precedes": {
60
"href": "https://horizon.stellar.org/effects?order=asc\u0026cursor=111721376498331649"
61
}
62
},
63
"id": "111721376498331649",
64
"paging_token": "111721376498331649",
65
"transaction_successful": true,
66
"source_account": "GAR4S3ASZ4HTJ6GQ2DEDLVL4YE6D64UPIOQI4I67L5VPYBGEZDGOI462",
67
"type": "payment",
68
"type_i": 1,
69
"created_at": "2019-09-26T12:47:50Z",
70
"transaction_hash": "cbf92ce9e2b75b0182597acb1e7c0b58695ec6f69e84a8625c5ab1dda8df31bc",
71
"asset_type": "native",
72
"from": "GAR4S3ASZ4HTJ6GQ2DEDLVL4YE6D64UPIOQI4I67L5VPYBGEZDGOI462",
73
"to": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
74
"amount": "5000.0000000"
75
},
76
{
77
"_links": {
78
"self": {
79
"href": "https://horizon.stellar.org/operations/111722218311925761"
80
},
81
"transaction": {
82
"href": "https://horizon.stellar.org/transactions/9fcf20d23862f40cd8a59f0ad0247a7d56a1b38cb79e4953b5aad8df5f2608a7"
83
},
84
"effects": {
85
"href": "https://horizon.stellar.org/operations/111722218311925761/effects"
86
},
87
"succeeds": {
88
"href": "https://horizon.stellar.org/effects?order=desc\u0026cursor=111722218311925761"
89
},
90
"precedes": {
91
"href": "https://horizon.stellar.org/effects?order=asc\u0026cursor=111722218311925761"
92
}
93
},
94
"id": "111722218311925761",
95
"paging_token": "111722218311925761",
96
"transaction_successful": true,
97
"source_account": "GBSIPZRLSM2KMLUZYEGKU2WMA6HPEE3NGB47YY4MLK43ISLLCJKFA2F2",
98
"type": "payment",
99
"type_i": 1,
100
"created_at": "2019-09-26T13:05:12Z",
101
"transaction_hash": "9fcf20d23862f40cd8a59f0ad0247a7d56a1b38cb79e4953b5aad8df5f2608a7",
102
"asset_type": "native",
103
"from": "GBSIPZRLSM2KMLUZYEGKU2WMA6HPEE3NGB47YY4MLK43ISLLCJKFA2F2",
104
"to": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
105
"amount": "10.0000000"
106
},
107
{
108
"_links": {
109
"self": {
110
"href": "https://horizon.stellar.org/operations/111747107647434753"
111
},
112
"transaction": {
113
"href": "https://horizon.stellar.org/transactions/44af49d32061cdb352d131559560559e7be815b16c45412b7682600c71224623"
114
},
115
"effects": {
116
"href": "https://horizon.stellar.org/operations/111747107647434753/effects"
117
},
118
"succeeds": {
119
"href": "https://horizon.stellar.org/effects?order=desc\u0026cursor=111747107647434753"
120
},
121
"precedes": {
122
"href": "https://horizon.stellar.org/effects?order=asc\u0026cursor=111747107647434753"
123
}
124
},
125
"id": "111747107647434753",
126
"paging_token": "111747107647434753",
127
"transaction_successful": true,
128
"source_account": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
129
"type": "payment",
130
"type_i": 1,
131
"created_at": "2019-09-26T21:43:41Z",
132
"transaction_hash": "44af49d32061cdb352d131559560559e7be815b16c45412b7682600c71224623",
133
"asset_type": "credit_alphanum4",
134
"asset_code": "BTC",
135
"asset_issuer": "GATEMHCCKCY67ZUCKTROYN24ZYT5GK4EQZ65JJLDHKHRUZI3EUEKMTCH",
136
"from": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
137
"to": "GBSIPZRLSM2KMLUZYEGKU2WMA6HPEE3NGB47YY4MLK43ISLLCJKFA2F2",
138
"amount": "0.0000709"
139
},
140
{
141
"_links": {
142
"self": {
143
"href": "https://horizon.stellar.org/operations/111764193027313665"
144
},
145
"transaction": {
146
"href": "https://horizon.stellar.org/transactions/7bd57f8cc75ce2d9740568eade9700cd7b19491a2c938232e5b3f0768f3e588a"
147
},
148
"effects": {
149
"href": "https://horizon.stellar.org/operations/111764193027313665/effects"
150
},
151
"succeeds": {
152
"href": "https://horizon.stellar.org/effects?order=desc\u0026cursor=111764193027313665"
153
},
154
"precedes": {
155
"href": "https://horizon.stellar.org/effects?order=asc\u0026cursor=111764193027313665"
156
}
157
},
158
"id": "111764193027313665",
159
"paging_token": "111764193027313665",
160
"transaction_successful": true,
161
"source_account": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
162
"type": "payment",
163
"type_i": 1,
164
"created_at": "2019-09-27T03:37:57Z",
165
"transaction_hash": "7bd57f8cc75ce2d9740568eade9700cd7b19491a2c938232e5b3f0768f3e588a",
166
"asset_type": "credit_alphanum4",
167
"asset_code": "BTC",
168
"asset_issuer": "GATEMHCCKCY67ZUCKTROYN24ZYT5GK4EQZ65JJLDHKHRUZI3EUEKMTCH",
169
"from": "GCRGHKY6RBFVQLF2JCHB7TK7A5BIABITFKVIEOXK4BPEIDE446OEFYXZ",
170
"to": "GBSIPZRLSM2KMLUZYEGKU2WMA6HPEE3NGB47YY4MLK43ISLLCJKFA2F2",
171
"amount": "0.0107156"
172
}
173
]
174
}
175
}
Copied!
Last modified 8mo ago
Copy link