Skip to content
Permalink
master
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
title order
Retrieve a Ledger's Transactions
30

import { Endpoint } from "components/Endpoint"; import { ExampleResponse } from "components/ExampleResponse"; import { CodeExample } from "components/CodeExample"; import { AttributeTable } from "components/AttributeTable";

This endpoint represents successful transactions in a given ledger.

GET /ledgers/:ledger_sequence/transactions?cursor={paging_token}&order={asc,desc}&limit={1-200}&include_failed{true,false}
  • ARGUMENT
    • REQUIRED
    • DESCRIPTION
  • sequence
    • required
    • The sequence number of a specific ledger.
  • cursor
    • optional
    • A number that points to a specific location in a collection of responses and is pulled from the paging_token value of a record.
  • order
    • optional
    • A designation of the order in which records should appear. Options include asc(ascending) or desc (descending). If this argument isn’t set, it defaults to asc.
  • limit
    • optional
    • The maximum number of records returned. The limit can range from 1 to 200 - an upper limit that is hardcoded in Horizon for performance reasons. If this argument isn’t designated, it defaults to 10.
  • include_failed
    • optional
    • Set to true to include failed transactions in results. Options include true and false.
curl "https://horizon.stellar.org/ledgers/27147222/transactions?limit=2"
var StellarSdk = require("stellar-sdk");
var server = new StellarSdk.Server("https://horizon.stellar.org");

server
  .transactions()
  .forLedger("27147222")
  .call()
  .then(function (resp) {
    console.log(resp);
  })
  .catch(function (err) {
    console.error(err);
  });
from stellar_sdk import Server
server = Server("https://horizon.stellar.org")

try:
    print(server.transactions().for_ledger("27147222").call())
except Exception as err:
    print(err)
{
  "_links": {
    "self": {
      "href": "https://horizon.stellar.org/ledgers/27147222/transactions?cursor=\u0026limit=2\u0026order=asc"
    },
    "next": {
      "href": "https://horizon.stellar.org/ledgers/27147222/transactions?cursor=116596430667259904\u0026limit=2\u0026order=asc"
    },
    "prev": {
      "href": "https://horizon.stellar.org/ledgers/27147222/transactions?cursor=116596430667255808\u0026limit=2\u0026order=desc"
    }
  },
  "_embedded": {
    "records": [
      {
        "memo": "FadBcV0owHrsLQif/V2TxZKGA2YiX+MoifI7oB/UjJM=",
        "_links": {
          "self": {
            "href": "https://horizon.stellar.org/transactions/3a644389bbec63dd2b107a03c16711563fc549daa7b7f56f951a2e470f81f2e0"
          },
          "account": {
            "href": "https://horizon.stellar.org/accounts/GBKTEASNXABG2NC4TY6N3IA5UFC6YW53Y4KTIKY3CUEKQ2W5EIYRMYVB"
          },
          "ledger": {
            "href": "https://horizon.stellar.org/ledgers/27147222"
          },
          "operations": {
            "href": "https://horizon.stellar.org/transactions/3a644389bbec63dd2b107a03c16711563fc549daa7b7f56f951a2e470f81f2e0/operations{?cursor,limit,order}",
            "templated": true
          },
          "effects": {
            "href": "https://horizon.stellar.org/transactions/3a644389bbec63dd2b107a03c16711563fc549daa7b7f56f951a2e470f81f2e0/effects{?cursor,limit,order}",
            "templated": true
          },
          "precedes": {
            "href": "https://horizon.stellar.org/transactions?order=asc\u0026cursor=116596430667255808"
          },
          "succeeds": {
            "href": "https://horizon.stellar.org/transactions?order=desc\u0026cursor=116596430667255808"
          }
        },
        "id": "3a644389bbec63dd2b107a03c16711563fc549daa7b7f56f951a2e470f81f2e0",
        "paging_token": "116596430667255808",
        "successful": true,
        "hash": "3a644389bbec63dd2b107a03c16711563fc549daa7b7f56f951a2e470f81f2e0",
        "ledger": 27147222,
        "created_at": "2019-12-06T23:05:38Z",
        "source_account": "GBKTEASNXABG2NC4TY6N3IA5UFC6YW53Y4KTIKY3CUEKQ2W5EIYRMYVB",
        "source_account_sequence": "113943107245989112",
        "fee_charged": 100,
        "max_fee": 100,
        "operation_count": 1,
        "envelope_xdr": "AAAAAFUyAk24Am00XJ483aAdoUXsW7vHFTQrGxUIqGrdIjEWAAAAZAGUzqcAAFz4AAAAAQAAAAAAAAAAAAAAAAAAAAAAAAADFadBcV0owHrsLQif/V2TxZKGA2YiX+MoifI7oB/UjJMAAAABAAAAAQAAAADhZHiqD/Q3uSTgjYEWGVRfCCHYvFmeqJU12G9SkzJYEQAAAAEAAAAAB77j4CQxLlm5aPrq/PDwFhGNs2ldqbdCZwkSfzXhUhYAAAABTk9ETAAAAAB1jYLXrF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//////////wAAAAEAAAAAAAAAAAAAAAEBnjvWAAAAAQAAAADhZHiqD/Q3uSTgjYEWGVRfCCHYvFmeqJU12G9SkzJYEQAAAAFOT0RMAAAAAHWNgtesXM0E5YKg+dlIcjc8kCEe1zVOsJqI+5nBJ/mmAAAALEhqMkl//////////wAAAAEAAAAAAAAAAA==",
        "fee_meta_xdr": "AAAAAgAAAAMBnjvKAAAAAAAAAABVMgJNuAJtNFyePN2gHaFF7Fu7xxU0KxsVCKhq3SIxFgAAAAAHm1QEAZTOpwAAXPcAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAEBnjvWAAAAAAAAAABVMgJNuAJtNFyePN2gHaFF7Fu7xxU0KxsVCKhq3SIxFgAAAAAHm1OgAZTOpwAAXPcAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAA==",
        "memo_type": "hash",
        "signatures": [
          "tIucvddPcXp2rmbZYdnu0fccGsr976nYbseuXdZdBOhSyDEohEfpuEdP+YhbCet8tn2eVWMwIWhk+pUqsjaWAg==",
          "Ktn0huMMAHjTxWBBqo2nBfyFev85SygR7GRYaQ30+NwEbad/hspZ1uOJqodn4uu8z4N2aHG0Dcv1vOYKJ7w2AA=="
        ],
        "valid_after": "1970-01-01T00:00:00Z"
      },
      {
        "_links": {
          "self": {
            "href": "https://horizon.stellar.org/transactions/83eabfa824b57436eda49bb9ac28675285f6d945325f69db41792078a83d3479"
          },
          "account": {
            "href": "https://horizon.stellar.org/accounts/GDUHYA43LEQWXLJ5GQGNDJHZY6TZN2OK3KA4YQXQ47BRMRDRIUUC4IU5"
          },
          "ledger": {
            "href": "https://horizon.stellar.org/ledgers/27147222"
          },
          "operations": {
            "href": "https://horizon.stellar.org/transactions/83eabfa824b57436eda49bb9ac28675285f6d945325f69db41792078a83d3479/operations{?cursor,limit,order}",
            "templated": true
          },
          "effects": {
            "href": "https://horizon.stellar.org/transactions/83eabfa824b57436eda49bb9ac28675285f6d945325f69db41792078a83d3479/effects{?cursor,limit,order}",
            "templated": true
          },
          "precedes": {
            "href": "https://horizon.stellar.org/transactions?order=asc\u0026cursor=116596430667259904"
          },
          "succeeds": {
            "href": "https://horizon.stellar.org/transactions?order=desc\u0026cursor=116596430667259904"
          }
        },
        "id": "83eabfa824b57436eda49bb9ac28675285f6d945325f69db41792078a83d3479",
        "paging_token": "116596430667259904",
        "successful": true,
        "hash": "83eabfa824b57436eda49bb9ac28675285f6d945325f69db41792078a83d3479",
        "ledger": 27147222,
        "created_at": "2019-12-06T23:05:38Z",
        "source_account": "GDUHYA43LEQWXLJ5GQGNDJHZY6TZN2OK3KA4YQXQ47BRMRDRIUUC4IU5",
        "source_account_sequence": "113383696345604336",
        "fee_charged": 100,
        "max_fee": 100,
        "operation_count": 1,
        "envelope_xdr": "AAAAAOh8A5tZIWutPTQM0aT5x6eW6cragcxC8OfDFkRxRSguAAAAZAGS0d8AACDwAAAAAQAAAAAAAAAAAAAAAF3q3zYAAAAAAAAAAQAAAAEAAAAASe2g7z3OqB0F+vr+sM6vGMHgnomyJOLJeGMMjT1jgPcAAAADAAAAAVJNVAAAAAAAyGdd4j3sXGNb4PWMyeROuBvzRJJbU+On/O1oSxFvcqwAAAAAAAAAAAAAABcAB2UNAJiWgAAAAAAAAAAAAAAAAAAAAAJxRSguAAAAQG/ksOk2naI/PrA/6qes3c0IhoOpnBghd038S62rayiophPSs3HyUbgbOEpYQCkJezrf1bP+s2fFXVCEXbgveQk9Y4D3AAAAQAINPdxGV1VIeQ1OUDDlqtrSy8FrWQ/+CtRxqVHcHg98SYh5co/gd83R4IGDxukCByTbYapkrUOD0XDJKC/hcg4=",
        "result_xdr": "AAAAAAAAAGQAAAAAAAAAAQAAAAAAAAADAAAAAAAAAAAAAAACAAAAAA==",
        "result_meta_xdr": "AAAAAQAAAAIAAAADAZ471gAAAAAAAAAA6HwDm1kha609NAzRpPnHp5bpytqBzELw58MWRHFFKC4AAAAAAKovMAGS0d8AACDvAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAABAZ471gAAAAAAAAAA6HwDm1kha609NAzRpPnHp5bpytqBzELw58MWRHFFKC4AAAAAAKovMAGS0d8AACDwAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAABAAAAAA==",
        "fee_meta_xdr": "AAAAAgAAAAMBnjukAAAAAAAAAADofAObWSFrrT00DNGk+cenlunK2oHMQvDnwxZEcUUoLgAAAAAAqi+UAZLR3wAAIO8AAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAEBnjvWAAAAAAAAAADofAObWSFrrT00DNGk+cenlunK2oHMQvDnwxZEcUUoLgAAAAAAqi8wAZLR3wAAIO8AAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAA==",
        "memo_type": "none",
        "signatures": [
          "b+Sw6Tadoj8+sD/qp6zdzQiGg6mcGCF3TfxLratrKKimE9KzcfJRuBs4SlhAKQl7Ot/Vs/6zZ8VdUIRduC95CQ==",
          "Ag093EZXVUh5DU5QMOWq2tLLwWtZD/4K1HGpUdweD3xJiHlyj+B3zdHggYPG6QIHJNthqmStQ4PRcMkoL+FyDg=="
        ],
        "valid_after": "1970-01-01T00:00:00Z",
        "valid_before": "2019-12-06T23:07:34Z"
      }
    ]
  }
}