<?xml version="1.0"?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="https://secure.clearbooks.co.uk/api/accounting/soap/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" name="Accounting" targetNamespace="https://secure.clearbooks.co.uk/api/accounting/soap/">
  <types>
    <xsd:schema targetNamespace="https://secure.clearbooks.co.uk/api/accounting/soap/">
      <xsd:complexType name="PaymentInvoice">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
        </xsd:all>
        <xsd:attribute name="amount" type="xsd:float" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfPaymentInvoice" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:PaymentInvoice" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="AllocateQuery">
        <xsd:all>
          <xsd:element name="invoices" type="tns:ArrayOfPaymentInvoice" minOccurs="0"/>
          <xsd:element name="type" type="xsd:string"/>
          <xsd:element name="paymentId" type="xsd:int"/>
          <xsd:element name="entityId" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ResponseStatus">
        <xsd:all>
          <xsd:element name="success" type="xsd:boolean"/>
        </xsd:all>
        <xsd:attribute name="msg" type="xsd:string" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="AccountCodeRequest">
        <xsd:all>
          <xsd:element name="heading_id" type="xsd:int"/>
          <xsd:element name="name" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="default_vat_rate" type="xsd:string" use="optional"/>
        <xsd:attribute name="show_sales" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="show_purchases" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="show_budget" type="xsd:int" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="AccountCodeResult">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="Bank_BankAccount">
        <xsd:all>
          <xsd:element name="name" type="xsd:string"/>
          <xsd:element name="accountNumber" type="xsd:string"/>
          <xsd:element name="sortCode" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="BankStatementLine">
        <xsd:all>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="date" type="xsd:string"/>
          <xsd:element name="amount" type="xsd:float"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfBankStatementLine" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:BankStatementLine" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="EntityExtra">
        <xsd:all/>
        <xsd:attribute name="default_account_code" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="default_vat_rate" type="xsd:string" use="optional" default="0.00:Out"/>
        <xsd:attribute name="default_credit_terms" type="xsd:int" use="optional" default="30"/>
      </xsd:complexType>
      <xsd:complexType name="BankAccount">
        <xsd:all>
          <xsd:element name="bankName" type="xsd:string"/>
          <xsd:element name="name" type="xsd:string"/>
          <xsd:element name="sortcode" type="xsd:string"/>
          <xsd:element name="accountNumber" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="Entity">
        <xsd:all>
          <xsd:element name="supplier" type="tns:EntityExtra" minOccurs="0"/>
          <xsd:element name="customer" type="tns:EntityExtra" minOccurs="0"/>
          <xsd:element name="bankAccount" type="tns:BankAccount" minOccurs="0"/>
          <xsd:element name="company_name" type="xsd:string"/>
          <xsd:element name="contact_name" type="xsd:string"/>
          <xsd:element name="address1" type="xsd:string"/>
          <xsd:element name="town" type="xsd:string"/>
          <xsd:element name="county" type="xsd:string"/>
          <xsd:element name="postcode" type="xsd:string"/>
          <xsd:element name="email" type="xsd:string"/>
          <xsd:element name="phone1" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="id" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="country" type="xsd:string" use="optional" default="GB"/>
        <xsd:attribute name="building" type="xsd:string" use="optional"/>
        <xsd:attribute name="address2" type="xsd:string" use="optional"/>
        <xsd:attribute name="phone2" type="xsd:string" use="optional"/>
        <xsd:attribute name="fax" type="xsd:string" use="optional"/>
        <xsd:attribute name="website" type="xsd:string" use="optional"/>
        <xsd:attribute name="date_modified" type="xsd:dateTime" use="optional"/>
        <xsd:attribute name="external_id" type="xsd:string" use="optional"/>
        <xsd:attribute name="vat_number" type="xsd:string" use="optional"/>
        <xsd:attribute name="company_number" type="xsd:string" use="optional"/>
        <xsd:attribute name="statement_url" type="xsd:string" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="Item">
        <xsd:all>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="unitPrice" type="xsd:float"/>
          <xsd:element name="type" type="xsd:int"/>
        </xsd:all>
        <xsd:attribute name="vat" type="xsd:float" use="optional"/>
        <xsd:attribute name="quantity" type="xsd:float" use="optional" default="1"/>
        <xsd:attribute name="vatRate" type="xsd:string" use="optional" default="0"/>
        <xsd:attribute name="project" type="xsd:int" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfItem" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Item" ref="soap-enc:arrayType" minOccurs="1" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="Invoice">
        <xsd:all>
          <xsd:element name="items" type="tns:ArrayOfItem" minOccurs="0"/>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="entityId" type="xsd:int"/>
          <xsd:element name="dateCreated" type="xsd:dateTime"/>
          <xsd:element name="type" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="invoice_id" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="invoice_prefix" type="xsd:string" use="optional"/>
        <xsd:attribute name="invoiceNumber" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="reference" type="xsd:string" use="optional"/>
        <xsd:attribute name="dateDue" type="xsd:dateTime" use="optional"/>
        <xsd:attribute name="dateModified" type="xsd:dateTime" use="optional"/>
        <xsd:attribute name="dateAccrual" type="xsd:dateTime" use="optional"/>
        <xsd:attribute name="creditTerms" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="bankPaymentId" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="project" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="external_id" type="xsd:string" use="optional"/>
        <xsd:attribute name="status" type="xsd:string" use="optional"/>
        <xsd:attribute name="statementPage" type="xsd:string" use="optional"/>
        <xsd:attribute name="pdfUrl" type="xsd:string" use="optional"/>
        <xsd:attribute name="themeId" type="xsd:int" use="optional" default="1"/>
        <xsd:attribute name="vatTreatment" type="xsd:string" use="optional"/>
        <xsd:attribute name="multicurrency" type="xsd:int" use="optional"/>
        <xsd:attribute name="fxrate" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="gross" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="net" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="vat" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="paid" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="balance" type="xsd:float" use="optional" default="0"/>
        <xsd:attribute name="foreignCurrencyBalance" type="xsd:float" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="InvoiceReturn">
        <xsd:all>
          <xsd:element name="due" type="xsd:float"/>
          <xsd:element name="invoice_id" type="xsd:int"/>
          <xsd:element name="invoice_prefix" type="xsd:string"/>
          <xsd:element name="invoice_number" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfInvoice" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Invoice" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfInvoiceReturn" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:InvoiceReturn" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="JournalLedgerItem">
        <xsd:all>
          <xsd:element name="account" type="xsd:int"/>
          <xsd:element name="amount" type="xsd:float"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfJournalLedgerItem" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:JournalLedgerItem" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="Journal">
        <xsd:all>
          <xsd:element name="ledger" type="tns:ArrayOfJournalLedgerItem" minOccurs="0"/>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="accountingDate" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="project" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="entity" type="xsd:int" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="JournalReturn">
        <xsd:all>
          <xsd:element name="journal_id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="Payment">
        <xsd:all>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="invoices" type="tns:ArrayOfPaymentInvoice" minOccurs="0"/>
          <xsd:element name="type" type="xsd:string"/>
          <xsd:element name="project" type="xsd:int"/>
          <xsd:element name="accountingDate" type="xsd:dateTime"/>
          <xsd:element name="amount" type="xsd:float"/>
          <xsd:element name="entityId" type="xsd:int"/>
          <xsd:element name="paymentMethod" type="xsd:int"/>
          <xsd:element name="bankAccount" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="bsAccount" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="fxRate" type="xsd:float" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="PaymentReturn">
        <xsd:all>
          <xsd:element name="payment_id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfPayment" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Payment" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="Project">
        <xsd:all>
          <xsd:element name="projectName" type="xsd:string"/>
          <xsd:element name="status" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="description" type="xsd:string" use="optional"/>
        <xsd:attribute name="id" type="xsd:int" use="optional" default="0"/>
      </xsd:complexType>
      <xsd:complexType name="ProjectReturn">
        <xsd:all>
          <xsd:element name="project_id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ExchangeRateRequest">
        <xsd:all>
          <xsd:element name="targetCurrency" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="baseCurrency" type="xsd:string" use="optional" default="GBP"/>
        <xsd:attribute name="date" type="xsd:dateTime" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="EntityOutstandingBalance">
        <xsd:all>
          <xsd:element name="outstanding" type="xsd:float"/>
          <xsd:element name="overdue" type="xsd:float"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="AccountCodeHeading">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="heading_name" type="xsd:string"/>
          <xsd:element name="account_group" type="xsd:int"/>
          <xsd:element name="show_sales" type="xsd:int"/>
          <xsd:element name="show_purchases" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfAccountCodeHeading" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:AccountCodeHeading" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="AccountCode">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="account_name" type="xsd:string"/>
          <xsd:element name="group_name" type="xsd:string"/>
          <xsd:element name="default_vat_rate" type="xsd:string"/>
          <xsd:element name="show_sales" type="xsd:boolean"/>
          <xsd:element name="show_purchases" type="xsd:boolean"/>
          <xsd:element name="customAccountCode" type="xsd:string"/>
          <xsd:element name="hidden" type="xsd:boolean"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfAccountCode" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:AccountCode" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="BankAccountListItem">
        <xsd:all>
          <xsd:element name="account_type" type="xsd:int"/>
          <xsd:element name="balance" type="xsd:float"/>
          <xsd:element name="bank_name" type="xsd:string"/>
          <xsd:element name="currency" type="xsd:int"/>
          <xsd:element name="gl_account_code" type="xsd:string"/>
          <xsd:element name="id" type="xsd:int"/>
        </xsd:all>
        <xsd:attribute name="last_date" type="xsd:dateTime" use="optional"/>
        <xsd:attribute name="total_mc" type="xsd:float" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfBankAccountListItem" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:BankAccountListItem" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="ListBankAccountsReturn">
        <xsd:all>
          <xsd:element name="bankAccounts" type="tns:ArrayOfBankAccountListItem" minOccurs="0"/>
          <xsd:element name="total" type="xsd:float"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="Currency">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="name" type="xsd:string"/>
          <xsd:element name="code" type="xsd:string"/>
          <xsd:element name="symbol" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfCurrency" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Currency" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfInt" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="xsd:int" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="EntityQuery">
        <xsd:all>
          <xsd:element name="id" type="tns:ArrayOfInt" minOccurs="0"/>
        </xsd:all>
        <xsd:attribute name="companyName" type="xsd:string" use="optional"/>
        <xsd:attribute name="type" type="xsd:string" use="optional"/>
        <xsd:attribute name="offset" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="modifiedSince" type="xsd:dateTime" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfEntity" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Entity" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="InvoiceQuery">
        <xsd:all>
          <xsd:element name="id" type="tns:ArrayOfInt" minOccurs="0"/>
          <xsd:element name="entityId" type="tns:ArrayOfInt" minOccurs="0"/>
          <xsd:element name="ledger" type="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="status" type="xsd:string" use="optional"/>
        <xsd:attribute name="offset" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="modifiedSince" type="xsd:string" use="optional"/>
      </xsd:complexType>
      <xsd:complexType name="ListOutstandingBalancesReturn">
        <xsd:all>
          <xsd:element name="entity" type="xsd:int"/>
          <xsd:element name="balance" type="xsd:float"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfListOutstandingBalancesReturn" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:ListOutstandingBalancesReturn" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfProject" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Project" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="Theme">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="name" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfTheme" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:Theme" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:complexType name="InvoiceRef">
        <xsd:all>
          <xsd:element name="type" type="xsd:string"/>
          <xsd:element name="id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="RemovePayment">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="type" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="CreditQuery">
        <xsd:all>
          <xsd:element name="dateCreated" type="xsd:dateTime"/>
          <xsd:element name="description" type="xsd:string"/>
          <xsd:element name="ledger" type="xsd:string"/>
          <xsd:element name="accountCode" type="xsd:string"/>
          <xsd:element name="id" type="xsd:int"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="CreditResponseStatus">
        <xsd:all/>
        <xsd:attribute name="id" type="xsd:int" use="optional" default="0"/>
        <xsd:attribute name="msg" type="xsd:string" use="optional" default="Fail"/>
      </xsd:complexType>
      <xsd:complexType name="CreditPartialQuery">
        <xsd:all>
          <xsd:element name="invoiceId" type="xsd:int"/>
          <xsd:element name="creditId" type="xsd:int"/>
          <xsd:element name="amountToAllocate" type="xsd:float"/>
          <xsd:element name="ledger" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="PaymentMethod">
        <xsd:all>
          <xsd:element name="id" type="xsd:int"/>
          <xsd:element name="name" type="xsd:string"/>
          <xsd:element name="isClosed" type="xsd:boolean"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:complexType name="ArrayOfPaymentMethod" base="soap-enc:Array">
        <xsd:complexContent>
          <xsd:restriction base="soap-enc:Array">
            <xsd:attribute wsdl:arrayType="tns:PaymentMethod" ref="soap-enc:arrayType" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:restriction>
        </xsd:complexContent>
      </xsd:complexType>
      <xsd:element name="authenticate">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="apiKey" type="xsd:string"/>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:schema>
  </types>
  <portType name="AccountingPort">
    <operation name="allocatePayment">
      <documentation/>
      <input message="tns:allocatePaymentIn"/>
      <output message="tns:allocatePaymentOut"/>
    </operation>
    <operation name="createAccountCode">
      <documentation/>
      <input message="tns:createAccountCodeIn"/>
      <output message="tns:createAccountCodeOut"/>
    </operation>
    <operation name="createBankAccount">
      <documentation/>
      <input message="tns:createBankAccountIn"/>
      <output message="tns:createBankAccountOut"/>
    </operation>
    <operation name="addBankStatementLines">
      <documentation/>
      <input message="tns:addBankStatementLinesIn"/>
    </operation>
    <operation name="createEntity">
      <documentation/>
      <input message="tns:createEntityIn"/>
      <output message="tns:createEntityOut"/>
    </operation>
    <operation name="createInvoice">
      <documentation/>
      <input message="tns:createInvoiceIn"/>
      <output message="tns:createInvoiceOut"/>
    </operation>
    <operation name="createInvoices">
      <documentation/>
      <input message="tns:createInvoicesIn"/>
      <output message="tns:createInvoicesOut"/>
    </operation>
    <operation name="createJournal">
      <documentation/>
      <input message="tns:createJournalIn"/>
      <output message="tns:createJournalOut"/>
    </operation>
    <operation name="createPayment">
      <documentation/>
      <input message="tns:createPaymentIn"/>
      <output message="tns:createPaymentOut"/>
    </operation>
    <operation name="createPayments">
      <documentation/>
      <input message="tns:createPaymentsIn"/>
      <output message="tns:createPaymentsOut"/>
    </operation>
    <operation name="createProject">
      <documentation/>
      <input message="tns:createProjectIn"/>
      <output message="tns:createProjectOut"/>
    </operation>
    <operation name="deleteEntity">
      <documentation/>
      <input message="tns:deleteEntityIn"/>
      <output message="tns:deleteEntityOut"/>
    </operation>
    <operation name="deleteJournal">
      <documentation/>
      <input message="tns:deleteJournalIn"/>
      <output message="tns:deleteJournalOut"/>
    </operation>
    <operation name="getExchangeRate">
      <documentation/>
      <input message="tns:getExchangeRateIn"/>
      <output message="tns:getExchangeRateOut"/>
    </operation>
    <operation name="getEntityIdFromExternalId">
      <documentation/>
      <input message="tns:getEntityIdFromExternalIdIn"/>
      <output message="tns:getEntityIdFromExternalIdOut"/>
    </operation>
    <operation name="getEntityOutstandingBalance">
      <documentation/>
      <input message="tns:getEntityOutstandingBalanceIn"/>
      <output message="tns:getEntityOutstandingBalanceOut"/>
    </operation>
    <operation name="getInvoiceIdFromInvoiceNumber">
      <documentation/>
      <input message="tns:getInvoiceIdFromInvoiceNumberIn"/>
      <output message="tns:getInvoiceIdFromInvoiceNumberOut"/>
    </operation>
    <operation name="getPaymentIdFromExternalId">
      <documentation/>
      <input message="tns:getPaymentIdFromExternalIdIn"/>
      <output message="tns:getPaymentIdFromExternalIdOut"/>
    </operation>
    <operation name="listAccountCodeHeadings">
      <documentation/>
      <input message="tns:listAccountCodeHeadingsIn"/>
      <output message="tns:listAccountCodeHeadingsOut"/>
    </operation>
    <operation name="listAccountCodes">
      <documentation/>
      <input message="tns:listAccountCodesIn"/>
      <output message="tns:listAccountCodesOut"/>
    </operation>
    <operation name="listBankAccounts">
      <documentation/>
      <input message="tns:listBankAccountsIn"/>
      <output message="tns:listBankAccountsOut"/>
    </operation>
    <operation name="listCurrencies">
      <documentation/>
      <input message="tns:listCurrenciesIn"/>
      <output message="tns:listCurrenciesOut"/>
    </operation>
    <operation name="listEntities">
      <documentation/>
      <input message="tns:listEntitiesIn"/>
      <output message="tns:listEntitiesOut"/>
    </operation>
    <operation name="listInvoices">
      <documentation/>
      <input message="tns:listInvoicesIn"/>
      <output message="tns:listInvoicesOut"/>
    </operation>
    <operation name="listOutstandingBalances">
      <documentation/>
      <input message="tns:listOutstandingBalancesIn"/>
      <output message="tns:listOutstandingBalancesOut"/>
    </operation>
    <operation name="listProjects">
      <documentation/>
      <input message="tns:listProjectsIn"/>
      <output message="tns:listProjectsOut"/>
    </operation>
    <operation name="listThemes">
      <documentation/>
      <input message="tns:listThemesIn"/>
      <output message="tns:listThemesOut"/>
    </operation>
    <operation name="updateAccountCode">
      <documentation/>
      <input message="tns:updateAccountCodeIn"/>
      <output message="tns:updateAccountCodeOut"/>
    </operation>
    <operation name="updateEntity">
      <documentation/>
      <input message="tns:updateEntityIn"/>
      <output message="tns:updateEntityOut"/>
    </operation>
    <operation name="updateProject">
      <documentation/>
      <input message="tns:updateProjectIn"/>
      <output message="tns:updateProjectOut"/>
    </operation>
    <operation name="voidInvoice">
      <documentation/>
      <input message="tns:voidInvoiceIn"/>
      <output message="tns:voidInvoiceOut"/>
    </operation>
    <operation name="voidPayment">
      <documentation/>
      <input message="tns:voidPaymentIn"/>
      <output message="tns:voidPaymentOut"/>
    </operation>
    <operation name="writeOff">
      <documentation/>
      <input message="tns:writeOffIn"/>
      <output message="tns:writeOffOut"/>
    </operation>
    <operation name="writeOffPartial">
      <documentation/>
      <input message="tns:writeOffPartialIn"/>
      <output message="tns:writeOffPartialOut"/>
    </operation>
    <operation name="listPaymentMethods">
      <documentation/>
      <input message="tns:listPaymentMethodsIn"/>
      <output message="tns:listPaymentMethodsOut"/>
    </operation>
  </portType>
  <binding name="AccountingBinding" type="tns:AccountingPort">
    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="allocatePayment">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#allocatePayment"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createAccountCode">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createAccountCode"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createBankAccount">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createBankAccount"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="addBankStatementLines">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#addBankStatementLines"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createEntity">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createEntity"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createInvoice">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createInvoice"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createInvoices">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createInvoices"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createJournal">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createJournal"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createPayment">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createPayment"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createPayments">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createPayments"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="createProject">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#createProject"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="deleteEntity">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#deleteEntity"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="deleteJournal">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#deleteJournal"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="getExchangeRate">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#getExchangeRate"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="getEntityIdFromExternalId">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#getEntityIdFromExternalId"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="getEntityOutstandingBalance">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#getEntityOutstandingBalance"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="getInvoiceIdFromInvoiceNumber">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#getInvoiceIdFromInvoiceNumber"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="getPaymentIdFromExternalId">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#getPaymentIdFromExternalId"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listAccountCodeHeadings">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listAccountCodeHeadings"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listAccountCodes">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listAccountCodes"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listBankAccounts">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listBankAccounts"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listCurrencies">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listCurrencies"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listEntities">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listEntities"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listInvoices">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listInvoices"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listOutstandingBalances">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listOutstandingBalances"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listProjects">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listProjects"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listThemes">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listThemes"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="updateAccountCode">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#updateAccountCode"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="updateEntity">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#updateEntity"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="updateProject">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#updateProject"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="voidInvoice">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#voidInvoice"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="voidPayment">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#voidPayment"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="writeOff">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#writeOff"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="writeOffPartial">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#writeOffPartial"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
    <operation name="listPaymentMethods">
      <soap:operation soapAction="https://secure.clearbooks.co.uk/api/accounting/soap/#listPaymentMethods"/>
      <input>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
        <soap:header use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/" message="tns:header" part="authenticationHeader"/>
      </input>
      <output>
        <soap:body use="literal" namespace="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
      </output>
    </operation>
  </binding>
  <service name="AccountingService">
    <port name="AccountingPort" binding="tns:AccountingBinding">
      <soap:address location="https://secure.clearbooks.co.uk/api/accounting/soap/"/>
    </port>
  </service>
  <message name="allocatePaymentIn">
    <part name="query" type="tns:AllocateQuery"/>
  </message>
  <message name="allocatePaymentOut">
    <part name="return" type="tns:ResponseStatus"/>
  </message>
  <message name="createAccountCodeIn">
    <part name="code" type="tns:AccountCodeRequest"/>
  </message>
  <message name="createAccountCodeOut">
    <part name="return" type="tns:AccountCodeResult"/>
  </message>
  <message name="createBankAccountIn">
    <part name="bankAccount" type="tns:Bank_BankAccount"/>
  </message>
  <message name="createBankAccountOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="addBankStatementLinesIn">
    <part name="bankAccount" type="xsd:string"/>
    <part name="statementName" type="xsd:string"/>
    <part name="statementLines" type="tns:ArrayOfBankStatementLine"/>
  </message>
  <message name="createEntityIn">
    <part name="entity" type="tns:Entity"/>
  </message>
  <message name="createEntityOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="createInvoiceIn">
    <part name="invoice" type="tns:Invoice"/>
  </message>
  <message name="createInvoiceOut">
    <part name="return" type="tns:InvoiceReturn"/>
  </message>
  <message name="createInvoicesIn">
    <part name="invoices" type="tns:ArrayOfInvoice"/>
  </message>
  <message name="createInvoicesOut">
    <part name="return" type="tns:ArrayOfInvoiceReturn"/>
  </message>
  <message name="createJournalIn">
    <part name="project" type="tns:Journal"/>
  </message>
  <message name="createJournalOut">
    <part name="return" type="tns:JournalReturn"/>
  </message>
  <message name="createPaymentIn">
    <part name="payment" type="tns:Payment"/>
  </message>
  <message name="createPaymentOut">
    <part name="return" type="tns:PaymentReturn"/>
  </message>
  <message name="createPaymentsIn">
    <part name="payments" type="tns:ArrayOfPayment"/>
  </message>
  <message name="createPaymentsOut">
    <part name="return" type="tns:PaymentReturn"/>
  </message>
  <message name="createProjectIn">
    <part name="project" type="tns:Project"/>
  </message>
  <message name="createProjectOut">
    <part name="return" type="tns:ProjectReturn"/>
  </message>
  <message name="deleteEntityIn">
    <part name="entityId" type="xsd:int"/>
  </message>
  <message name="deleteEntityOut">
    <part name="return" type="xsd:boolean"/>
  </message>
  <message name="deleteJournalIn">
    <part name="journalId" type="xsd:int"/>
  </message>
  <message name="deleteJournalOut">
    <part name="return" type="xsd:boolean"/>
  </message>
  <message name="getExchangeRateIn">
    <part name="exchangeRateRequest" type="tns:ExchangeRateRequest"/>
  </message>
  <message name="getExchangeRateOut">
    <part name="return" type="xsd:float"/>
  </message>
  <message name="getEntityIdFromExternalIdIn">
    <part name="externalId" type="xsd:string"/>
  </message>
  <message name="getEntityIdFromExternalIdOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="getEntityOutstandingBalanceIn">
    <part name="entityId" type="xsd:int"/>
    <part name="type" type="xsd:string"/>
  </message>
  <message name="getEntityOutstandingBalanceOut">
    <part name="return" type="tns:EntityOutstandingBalance"/>
  </message>
  <message name="getInvoiceIdFromInvoiceNumberIn">
    <part name="type" type="xsd:string"/>
    <part name="invoicePrefix" type="xsd:string"/>
    <part name="invoiceNumber" type="xsd:string"/>
  </message>
  <message name="getInvoiceIdFromInvoiceNumberOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="getPaymentIdFromExternalIdIn">
    <part name="externalId" type="xsd:string"/>
  </message>
  <message name="getPaymentIdFromExternalIdOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="listAccountCodeHeadingsIn"/>
  <message name="listAccountCodeHeadingsOut">
    <part name="return" type="tns:ArrayOfAccountCodeHeading"/>
  </message>
  <message name="listAccountCodesIn"/>
  <message name="listAccountCodesOut">
    <part name="return" type="tns:ArrayOfAccountCode"/>
  </message>
  <message name="listBankAccountsIn"/>
  <message name="listBankAccountsOut">
    <part name="return" type="tns:ListBankAccountsReturn"/>
  </message>
  <message name="listCurrenciesIn"/>
  <message name="listCurrenciesOut">
    <part name="return" type="tns:ArrayOfCurrency"/>
  </message>
  <message name="listEntitiesIn">
    <part name="query" type="tns:EntityQuery"/>
  </message>
  <message name="listEntitiesOut">
    <part name="return" type="tns:ArrayOfEntity"/>
  </message>
  <message name="listInvoicesIn">
    <part name="query" type="tns:InvoiceQuery"/>
  </message>
  <message name="listInvoicesOut">
    <part name="return" type="tns:ArrayOfInvoice"/>
  </message>
  <message name="listOutstandingBalancesIn">
    <part name="type" type="xsd:string"/>
    <part name="limit" type="xsd:int"/>
  </message>
  <message name="listOutstandingBalancesOut">
    <part name="return" type="tns:ArrayOfListOutstandingBalancesReturn"/>
  </message>
  <message name="listProjectsIn">
    <part name="offset" type="xsd:int"/>
  </message>
  <message name="listProjectsOut">
    <part name="return" type="tns:ArrayOfProject"/>
  </message>
  <message name="listThemesIn"/>
  <message name="listThemesOut">
    <part name="return" type="tns:ArrayOfTheme"/>
  </message>
  <message name="updateAccountCodeIn">
    <part name="codeId" type="xsd:int"/>
    <part name="code" type="tns:AccountCodeRequest"/>
  </message>
  <message name="updateAccountCodeOut">
    <part name="return" type="tns:AccountCodeResult"/>
  </message>
  <message name="updateEntityIn">
    <part name="entityId" type="xsd:int"/>
    <part name="entity" type="tns:Entity"/>
  </message>
  <message name="updateEntityOut">
    <part name="return" type="xsd:int"/>
  </message>
  <message name="updateProjectIn">
    <part name="projectId" type="xsd:int"/>
    <part name="project" type="tns:Project"/>
  </message>
  <message name="updateProjectOut">
    <part name="return" type="tns:ProjectReturn"/>
  </message>
  <message name="voidInvoiceIn">
    <part name="invoice" type="tns:InvoiceRef"/>
  </message>
  <message name="voidInvoiceOut">
    <part name="return" type="tns:ResponseStatus"/>
  </message>
  <message name="voidPaymentIn">
    <part name="payment" type="tns:RemovePayment"/>
  </message>
  <message name="voidPaymentOut">
    <part name="return" type="tns:ResponseStatus"/>
  </message>
  <message name="writeOffIn">
    <part name="query" type="tns:CreditQuery"/>
  </message>
  <message name="writeOffOut">
    <part name="return" type="tns:CreditResponseStatus"/>
  </message>
  <message name="writeOffPartialIn">
    <part name="query" type="tns:CreditPartialQuery"/>
  </message>
  <message name="writeOffPartialOut">
    <part name="return" type="tns:CreditResponseStatus"/>
  </message>
  <message name="listPaymentMethodsIn"/>
  <message name="listPaymentMethodsOut">
    <part name="return" type="tns:ArrayOfPaymentMethod"/>
  </message>
  <message name="header">
    <part name="authenticationHeader" element="tns:authenticate"/>
  </message>
</definitions>
