List Account Codes

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

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>