GET Accounts

Returns an AccountListResponse object which contains a list of Account Detail records.

Request Information

URI Parameters

Name Description Type Additional information
Page Specifies the page number of the result set to return. integer

None.

PageSize Specifies the number of records on each page of results. Maximum page size is 100. Defaults to 25 if not specified. integer

None.

WsAccessKey The Web Service access key for this user and file which allows access to the API for the associated file (found in File - Settings). Using OAuth authentication mechanism is the preferred method to allow API access. string

Optional. Legacy authentication method and only required if not using OAuth. OAuth is preferred.

FileId Specifies the file id of the file to perform the operation upon. integer

Required

IsActive Filter records that are either Active (IsActive=true) or Inactive (IsActive=false). boolean

None.

IsBankAccount Filter records that are either a bank account (IsBankAccount=true) or not (IsBankAccount=false). boolean

None.

AccountType Filter records account type equal to the specified value. string

None.

IncludeBuiltIn Filter records to include built in accounts (IncludeBuiltIn=true) or not (IncludeBuiltIn=false). string

None.

HeaderAccountId Filter accounts to only those which are the children of a certain header account. string

None.

AccountLevel Filter records on account level ('header' or 'detail'). string

None.

Body Parameters

None.

Response Information

Resource Description

AccountListResponse
Name Description Type Additional information
Accounts No documentation available. Collection of AccountDetail

None.

_links Hypermedia links. Contains contextual links to possible next actions related to this resource. Only present in responses. This data is not to be sent to the server. Collection of Link

None.

Response Formats

application/json, text/json

Sample:
{
  "Accounts": [
    {
      "Id": 1,
      "Name": "Test Income Account",
      "AccountLevel": "Detail",
      "AccountType": "Income",
      "IsActive": true,
      "IsBuiltIn": false,
      "LastUpdatedId": "AAAAAAA",
      "DefaultTaxCode": "G1",
      "LedgerCode": "AA",
      "Currency": "AUD",
      "HeaderAccountId": 3,
      "ExchangeAccountId": 3,
      "IsBankAccount": false,
      "CreatedDateUtc": "2024-06-03T18:00:13.4145451Z",
      "LastModifiedDateUtc": "2024-11-27T18:00:13.4145451Z",
      "IncludeInForecaster": false,
      "BSB": null,
      "Number": null,
      "BankAccountName": null,
      "BankFileCreationEnabled": null,
      "BankCode": null,
      "UserNumber": null,
      "MerchantFeeAccountId": null,
      "IncludePendingTransactions": null,
      "_links": [
        {
          "rel": "detail",
          "href": "https://api.saasu.com/Account/1?FileId=123",
          "method": "GET",
          "title": null
        },
        {
          "rel": "related",
          "href": "https://api.saasu.com/Account/3?FileId=123",
          "method": "GET",
          "title": "HeaderAccount"
        }
      ]
    },
    {
      "Id": 2,
      "Name": "Test Bank Account",
      "AccountLevel": "Detail",
      "AccountType": "Income",
      "IsActive": true,
      "IsBuiltIn": false,
      "LastUpdatedId": "AAAAAAA",
      "DefaultTaxCode": null,
      "LedgerCode": "AA",
      "Currency": "AUD",
      "HeaderAccountId": null,
      "ExchangeAccountId": null,
      "IsBankAccount": true,
      "CreatedDateUtc": "2024-06-03T18:00:13.4145451Z",
      "LastModifiedDateUtc": "2024-11-27T18:00:13.4145451Z",
      "IncludeInForecaster": true,
      "BSB": "010101",
      "Number": "11111111",
      "BankAccountName": "Test Bank Account",
      "BankFileCreationEnabled": true,
      "BankCode": "TBA",
      "UserNumber": "222",
      "MerchantFeeAccountId": 3,
      "IncludePendingTransactions": true,
      "_links": [
        {
          "rel": "detail",
          "href": "https://api.saasu.com/Account/2?FileId=123",
          "method": "GET",
          "title": null
        }
      ]
    },
    {
      "Id": 3,
      "Name": "Test Header Account",
      "AccountLevel": "Header",
      "AccountType": "Income",
      "IsActive": true,
      "IsBuiltIn": false,
      "LastUpdatedId": "AAAAAAA",
      "DefaultTaxCode": null,
      "LedgerCode": "AA",
      "Currency": null,
      "HeaderAccountId": null,
      "ExchangeAccountId": null,
      "IsBankAccount": false,
      "CreatedDateUtc": "2024-06-03T18:00:13.4145451Z",
      "LastModifiedDateUtc": "2024-11-27T18:00:13.4145451Z",
      "IncludeInForecaster": null,
      "BSB": null,
      "Number": null,
      "BankAccountName": null,
      "BankFileCreationEnabled": null,
      "BankCode": null,
      "UserNumber": null,
      "MerchantFeeAccountId": null,
      "IncludePendingTransactions": null,
      "_links": [
        {
          "rel": "detail",
          "href": "https://api.saasu.com/Account/3?FileId=123",
          "method": "GET",
          "title": null
        }
      ]
    }
  ],
  "_links": [
    {
      "rel": "self",
      "href": "https://api.saasu.com/Accounts?FileId=123",
      "method": "GET",
      "title": null
    },
    {
      "rel": "next",
      "href": "https://api.saasu.com/Accounts?FileId=123&Page=2&PageSize=25",
      "method": "GET",
      "title": null
    }
  ]
}

application/xml, text/xml

Sample:
<AccountListResponse xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <_links>
    <Link>
      <rel>self</rel>
      <href>https://api.saasu.com/Accounts?FileId=123</href>
      <method>GET</method>
    </Link>
    <Link>
      <rel>next</rel>
      <href>https://api.saasu.com/Accounts?FileId=123&amp;Page=2&amp;PageSize=25</href>
      <method>GET</method>
    </Link>
  </_links>
  <Accounts>
    <AccountDetail>
      <_links>
        <Link>
          <rel>detail</rel>
          <href>https://api.saasu.com/Account/1?FileId=123</href>
          <method>GET</method>
        </Link>
        <Link>
          <rel>related</rel>
          <href>https://api.saasu.com/Account/3?FileId=123</href>
          <method>GET</method>
          <title>HeaderAccount</title>
        </Link>
      </_links>
      <Id>1</Id>
      <Name>Test Income Account</Name>
      <AccountLevel>Detail</AccountLevel>
      <AccountType>Income</AccountType>
      <IsActive>true</IsActive>
      <IsBuiltIn>false</IsBuiltIn>
      <LastUpdatedId>AAAAAAA</LastUpdatedId>
      <DefaultTaxCode>G1</DefaultTaxCode>
      <LedgerCode>AA</LedgerCode>
      <Currency>AUD</Currency>
      <HeaderAccountId>3</HeaderAccountId>
      <ExchangeAccountId>3</ExchangeAccountId>
      <IsBankAccount>false</IsBankAccount>
      <CreatedDateUtc>2024-06-03T18:00:13.4145451Z</CreatedDateUtc>
      <LastModifiedDateUtc>2024-11-27T18:00:13.4145451Z</LastModifiedDateUtc>
      <IncludeInForecaster>false</IncludeInForecaster>
      <BSB xsi:nil="true" />
      <Number xsi:nil="true" />
      <BankAccountName xsi:nil="true" />
      <BankFileCreationEnabled xsi:nil="true" />
      <BankCode xsi:nil="true" />
      <UserNumber xsi:nil="true" />
      <MerchantFeeAccountId xsi:nil="true" />
      <IncludePendingTransactions xsi:nil="true" />
    </AccountDetail>
    <AccountDetail>
      <_links>
        <Link>
          <rel>detail</rel>
          <href>https://api.saasu.com/Account/2?FileId=123</href>
          <method>GET</method>
        </Link>
      </_links>
      <Id>2</Id>
      <Name>Test Bank Account</Name>
      <AccountLevel>Detail</AccountLevel>
      <AccountType>Income</AccountType>
      <IsActive>true</IsActive>
      <IsBuiltIn>false</IsBuiltIn>
      <LastUpdatedId>AAAAAAA</LastUpdatedId>
      <DefaultTaxCode xsi:nil="true" />
      <LedgerCode>AA</LedgerCode>
      <Currency>AUD</Currency>
      <HeaderAccountId xsi:nil="true" />
      <ExchangeAccountId xsi:nil="true" />
      <IsBankAccount>true</IsBankAccount>
      <CreatedDateUtc>2024-06-03T18:00:13.4145451Z</CreatedDateUtc>
      <LastModifiedDateUtc>2024-11-27T18:00:13.4145451Z</LastModifiedDateUtc>
      <IncludeInForecaster>true</IncludeInForecaster>
      <BSB>010101</BSB>
      <Number>11111111</Number>
      <BankAccountName>Test Bank Account</BankAccountName>
      <BankFileCreationEnabled>true</BankFileCreationEnabled>
      <BankCode>TBA</BankCode>
      <UserNumber>222</UserNumber>
      <MerchantFeeAccountId>3</MerchantFeeAccountId>
      <IncludePendingTransactions>true</IncludePendingTransactions>
    </AccountDetail>
    <AccountDetail>
      <_links>
        <Link>
          <rel>detail</rel>
          <href>https://api.saasu.com/Account/3?FileId=123</href>
          <method>GET</method>
        </Link>
      </_links>
      <Id>3</Id>
      <Name>Test Header Account</Name>
      <AccountLevel>Header</AccountLevel>
      <AccountType>Income</AccountType>
      <IsActive>true</IsActive>
      <IsBuiltIn>false</IsBuiltIn>
      <LastUpdatedId>AAAAAAA</LastUpdatedId>
      <DefaultTaxCode xsi:nil="true" />
      <LedgerCode>AA</LedgerCode>
      <Currency xsi:nil="true" />
      <HeaderAccountId xsi:nil="true" />
      <ExchangeAccountId xsi:nil="true" />
      <IsBankAccount>false</IsBankAccount>
      <CreatedDateUtc>2024-06-03T18:00:13.4145451Z</CreatedDateUtc>
      <LastModifiedDateUtc>2024-11-27T18:00:13.4145451Z</LastModifiedDateUtc>
      <IncludeInForecaster xsi:nil="true" />
      <BSB xsi:nil="true" />
      <Number xsi:nil="true" />
      <BankAccountName xsi:nil="true" />
      <BankFileCreationEnabled xsi:nil="true" />
      <BankCode xsi:nil="true" />
      <UserNumber xsi:nil="true" />
      <MerchantFeeAccountId xsi:nil="true" />
      <IncludePendingTransactions xsi:nil="true" />
    </AccountDetail>
  </Accounts>
</AccountListResponse>