InvoicesMarkInvoiceAsChecked

MarkInvoiceAsChecked

Invoicing service 1.1: Sets a booked invoice's status to Checked - typically because it has been paid - and returns the invoice.

ServiceInvoicing 1.1
EndpointPOST https://app{server-number}.timelog.com/{account}/WebServices/Invoicing/V1_1/InvoicingServiceSecure.svc
SOAPActionhttp://www.timelog.com/api/tlp/v1/InvoicingService/MarkInvoiceAsChecked
Content-Typetext/xml; charset=utf-8
AuthenticationA token from GetToken
Changes dataYes
Safe to retryYes

How it works

Moves the invoice with this GUID to status Checked. Allowed from Booked and Overdue; an invoice that is already Checked is returned unchanged; a DRAFT is refused. Return[0] is the invoice with Status = Checked. There is no API operation to UNDO it: un-checking is a UI action. UpdateExternalData with external status Checked has the same effect; external status Booked does not un-check. The GUID must be an invoice's. Reading the invoice first can itself store Overdue - harmless here, since Overdue → Checked is allowed.

Parameters

Each parameter has one label: Required, Conditional (required depending on other values) or Optional. Send them in the order shown.

guidguid
Required

GUID of the invoice to check.

tokenSecurityToken
Required

The token from GetToken: Initials, Expires and Hash, sent back unchanged.

Request

POST /{account}/WebServices/Invoicing/V1_1/InvoicingServiceSecure.svc HTTP/1.1
Host: app{server-number}.timelog.com
Content-Type: text/xml; charset=utf-8
SOAPAction: "http://www.timelog.com/api/tlp/v1/InvoicingService/MarkInvoiceAsChecked"

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
                  xmlns:invoicing="http://www.timelog.com/api/tlp/v1"
                  xmlns:tok="http://www.timelog.com/api/tlp/v1_3">
  <soapenv:Body>
    <invoicing:MarkInvoiceAsChecked>
      <invoicing:guid>{guid}</invoicing:guid>
      <invoicing:token>
        <tok:Initials>{Initials from GetToken}</tok:Initials>
        <tok:Expires>{Expires from GetToken, unchanged}</tok:Expires>
        <tok:Hash>{Hash from GetToken}</tok:Hash>
      </invoicing:token>
    </invoicing:MarkInvoiceAsChecked>
  </soapenv:Body>
</soapenv:Envelope>
Replace every {…} placeholder with your own value.

Response

The call returns the standard response envelope. Check ResponseState first: a failed call still returns HTTP 200.

ResponseStatestring
Required

Success, Invalid or Error.

ErrorCodeinteger

0 on success, otherwise the error code. See Errors.

ReturnInvoice[]

Response<Invoice>: Return[0] = the invoice after the change. No 'Successfully called' message.

Example response

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Body>
    <MarkInvoiceAsCheckedResponse xmlns="http://www.timelog.com/api/tlp/v1">
      <MarkInvoiceAsCheckedResult xmlns:a="http://api.timelog.com"
                                  xmlns:b="http://www.timelog.com/api/tlp/v1"
                                  xmlns:c="http://www.timelog.com/api/tlp/v1_1"
                                  xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
        <a:Return>
          <b:Invoice>
            <a:Action>Original</a:Action>
            <a:IsCustomFieldsLoaded>false</a:IsCustomFieldsLoaded>
            <a:CustomFields i:nil="true"/>
            <a:IsExternalKeysLoaded>false</a:IsExternalKeysLoaded>
            <a:ExternalKeys i:nil="true"/>
            <b:ID>1001</b:ID>
            <b:InvoiceNo>1001</b:InvoiceNo>
            <b:Header>Example</b:Header>
            <b:Message>Example</b:Message>
            <b:InvoiceDate>2026-10-01T00:00:00</b:InvoiceDate>
            <b:DueDate>2026-10-01T00:00:00</b:DueDate>
            <b:Status>Example</b:Status>
            <b:Type>Example</b:Type>
            <b:RequisitionNo>1001</b:RequisitionNo>
            <b:InvoicingAddress>
              <c:Address1>Example</c:Address1>
              <c:Address2>Example</c:Address2>
              <c:Address3>Example</c:Address3>
              <c:ZipCode>1000</c:ZipCode>
              <c:City>Copenhagen</c:City>
              <c:State>Example</c:State>
              <c:Country>DK</c:Country>
            </b:InvoicingAddress>
            <b:CustomerID>1001</b:CustomerID>
            <b:ContactID>1001</b:ContactID>
            <b:CustomerReference>Example</b:CustomerReference>
            <b:InternalReference>Example</b:InternalReference>
            <b:CalculateVAT>false</b:CalculateVAT>
            <b:NetAmount>0</b:NetAmount>
            <b:VATIncluded>0</b:VATIncluded>
            <b:Rounding>0</b:Rounding>
            <b:AmountDue>0</b:AmountDue>
            <b:InvoiceLines>
              <b:InvoiceLine>
                <a:Action>Original</a:Action>
                <a:IsCustomFieldsLoaded>false</a:IsCustomFieldsLoaded>
                <a:CustomFields i:nil="true"/>
                <a:IsExternalKeysLoaded>false</a:IsExternalKeysLoaded>
                <a:ExternalKeys i:nil="true"/>
                <b:ID>1001</b:ID>
                <b:InvoiceID>1001</b:InvoiceID>
                <b:Date>2026-10-01T00:00:00</b:Date>
                <b:ProductNo>1001</b:ProductNo>
                <b:Text>Example</b:Text>
                <b:Quantity>0</b:Quantity>
                <b:Rate>0</b:Rate>
                <b:Amount>0</b:Amount>
                <b:Discount>0</b:Discount>
                <b:InvoiceLineType>0</b:InvoiceLineType>
                <b:VAT>0</b:VAT>
                <b:Details>
                  <b:ProjectHeader i:nil="true"/>
                  <b:Comment>Example</b:Comment>
                </b:Details>
              </b:InvoiceLine>
            </b:InvoiceLines>
            <b:Currency>DKK</b:Currency>
            <b:EAN>Example</b:EAN>
            <b:InvoiceCurrencyRate>0</b:InvoiceCurrencyRate>
            <b:GUID>3f2504e0-4f89-41d3-9a0c-305000000001</b:GUID>
            <b:InvoicingAttention>Example</b:InvoicingAttention>
            <b:InvoicingCustomerName>Example invoicing customer</b:InvoicingCustomerName>
            <b:CustomerReferenceID>1001</b:CustomerReferenceID>
            <b:InvoiceNoExternal>Example</b:InvoiceNoExternal>
            <b:Details>
              <b:Status>
                <a:Action>Original</a:Action>
                <a:IsCustomFieldsLoaded>false</a:IsCustomFieldsLoaded>
                <a:CustomFields i:nil="true"/>
                <a:IsExternalKeysLoaded>false</a:IsExternalKeysLoaded>
                <a:ExternalKeys i:nil="true"/>
                <b:ID>1001</b:ID>
                <b:Name>Example </b:Name>
              </b:Status>
              <b:Type>
                <a:Action>Original</a:Action>
                <a:IsCustomFieldsLoaded>false</a:IsCustomFieldsLoaded>
                <a:CustomFields i:nil="true"/>
                <a:IsExternalKeysLoaded>false</a:IsExternalKeysLoaded>
                <a:ExternalKeys i:nil="true"/>
                <b:ID>1001</b:ID>
                <b:Name>Example </b:Name>
              </b:Type>
              <b:InternalReference>
                <c:ID>1001</c:ID>
                <c:Initials>ABC</c:Initials>
                <c:FullName>Example full</c:FullName>
              </b:InternalReference>
              <b:Currency>
                <c:ID>1001</c:ID>
                <c:Abbreviation>DKK</c:Abbreviation>
                <c:Rate>0</c:Rate>
                <c:RateDate>2026-10-01T00:00:00</c:RateDate>
                <c:DescriptiveName>Example descriptive</c:DescriptiveName>
              </b:Currency>
              <b:CustomerHeader>
                <c:ID>1001</c:ID>
                <c:Name>Example </c:Name>
                <c:No>1001</c:No>
                <c:GUID>3f2504e0-4f89-41d3-9a0c-305000000002</c:GUID>
              </b:CustomerHeader>
              <b:ContactHeader>
                <c:GUID>3f2504e0-4f89-41d3-9a0c-305000000003</c:GUID>
                <c:FirstName>Example first</c:FirstName>
                <c:LastName>Example last</c:LastName>
              </b:ContactHeader>
              <b:ProjectHeader>
                <c:ID>1001</c:ID>
                <c:Name>Example </c:Name>
                <c:No>1001</c:No>
                <c:IsActive>true</c:IsActive>
                <c:IsGeneralProject>false</c:IsGeneralProject>
                <c:StartDate>2026-10-01T00:00:00</c:StartDate>
                <c:EndDate>2026-10-01T00:00:00</c:EndDate>
              </b:ProjectHeader>
            </b:Details>
          </b:Invoice>
        </a:Return>
        <a:ReturnTypeDescription>Invoice</a:ReturnTypeDescription>
        <a:Request>…</a:Request>
        <a:ResponseState>Success</a:ResponseState>
        <a:Messages>
          <a:APIMessage>
            <a:Message>Duration of call was 0,0421337 sec.</a:Message>
            <a:Severity>Message</a:Severity>
            <a:ErrorCode>0</a:ErrorCode>
          </a:APIMessage>
        </a:Messages>
        <a:ErrorCode>0</a:ErrorCode>
        <a:IsReturnPaged>false</a:IsReturnPaged>
        <a:TotalPageCount>0</a:TotalPageCount>
      </MarkInvoiceAsCheckedResult>
    </MarkInvoiceAsCheckedResponse>
  </s:Body>
</s:Envelope>
Illustrative example: built from the service description (WSDL) in the same format as a real response, with made-up values. The Request block is shortened.

Errors

All errors come back with HTTP 200: check ResponseState, ErrorCode and Messages. The errors every operation can return (expired or invalid token, API not enabled, HTTPS required, general errors) are listed once in Responses and errors.

Errors specific to this operation:

ResponseStateErrorCodeMessageWhat it meansWhat to do
Error40001Error during call on TimeLog.API, Message 'You can't check an invoice in draft state'The invoice is a draft. Nothing is changed.—
Error40001Error during call on TimeLog.API, Message 'Unable to retrieve invoiceDTO with GUID:{guid}
In Stored Procedure: …'No invoicing document has this GUID.Check the GUID.
Error40001Error during call on TimeLog.API, Message 'Invoice was requested has the wrong type (Expected: Invoice, Was: {CreditNote|Reminder|Voucher})'The GUID belongs to a credit note, reminder or voucher. Nothing is changed.Use the credit-note operations for credit notes; reminders and vouchers have no operation in this service.