Log in
 

Soap API documentation

Method: listAccountCodes

List available account codes.

Request

Field Type Description  
no parameters string optional

Response

Field Type Description  
return value[] id integer The internal id of the account code optional
return value[] account_name string optional
return value[] group_name string The name of the group the account code is assigned to optional
return value[] default_vat_rate string optional
return value[] show_sales boolean Boolean value of whether the account code shows in the sales invoice form optional
return value[] show_purchases boolean Boolean value of whether the account code shows in the purchase invoice form optional
return value[] customAccountCode string The value of the custom account code field, if present. Please note that the API operates with the system default account codes, so every other endpoint where the account code is present will require and/or return the original system account codes. optional
return value[] hidden boolean The value is true, if the account code is not in use and not visible through the UI. optional

Examples

Request

<?xml version="1.0" encoding="UTF-8"?>
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"
  xmlns:cb="https://secure.clearbooks.co.uk/api/soap/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:enc="http://www.w3.org/2003/05/soap-encoding">
  <env:Header>
    <cb:authenticate apiKey="yourApiKey" />
  </env:Header>
  <env:Body>
    <env:listAccountCodes env:encodingStyle="http://www.w3.org/2003/05/soap-encoding" />
  </env:Body>
</env:Envelope>

Response

<?xml version="1.0" encoding="UTF-8"?>
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"
  xmlns:cb="https://secure.clearbooks.co.uk/api/soap/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:enc="http://www.w3.org/2003/05/soap-encoding">
  <env:Body xmlns:rpc="http://www.w3.org/2003/05/soap-rpc">
    <env:listAccountCodesResponse env:encodingStyle="http://www.w3.org/2003/05/soap-encoding">
      <accountCodes enc:itemType="cb:AccountCode" xsi:type="cb:ArrayOfAccountCodes">
        <accountCode id="4001001" account_name="Salaries"
          group_name="Administrative expenses" default_vat_rate="0.00:Out"
          show_sales="false" show_purchases="true" xsi:type="cb:AccountCode" />
      </accountCodes>
    </env:listAccountCodesResponse>
  </env:Body>
</env:Envelope>
ICB accreditation

Clear Books, accredited by The Institute of Certified Bookkeepers and registered with the Financial Conduct Authority (reg. no. 843585), delivers valued, comprehensive online accounting software for small businesses in the UK.