Update

update

ParameterTypeI/ODescription
<General>INParameters described in Overview
CompanyStringINThe users default company number for the companies list
ActionStringINIdentifier for the list requested
InputStringINData array containing optional parameters
expensesheet_expensesheetinternalStringINExpense sheet input data array parameter
expensesheet_companyStringINExpense sheet company parameter required for create

expensesheet_suppliercode

[OPTIONAL]

StringINExpense sheet suppliercode parameter, required for create

expensesheet_sheetdate

[OPTIONAL]

StringINExpense sheet date parameter

expensesheet_sheetstatuscode

[OPTIONAL]

StringINStatus code for the expense sheet

expensesheet_description

[OPTIONAL]

StringINSheet description
ResponseXML / JSONOUTAn XML tree / JSON string containing the success or error response

Description

Calling the expenses API with an action of update retrieves a response. Update can be used to Create, Update or Delete an expense line.

  • Providing a expensesheet_expensesheetinternal along with other optional parameters will assume the update operation to be an update.
  • Providing expensesheet_expensesheetinternal without any other optional parameters assumes the update operation to be a delete.
  • Providing optional parameters without a expensesheet_expensesheetinternal will assume the update operation to be a create. Create requires the expensesheet_company and expensesheet_resourcecode to be supplied as part of the input data. The response will contain the UUID for the sheet created.

Return Values

Response – Success or error response.

The structure of the response is:

<Responses>
  <Success>
    <SuccessText>data processed successfully.</SuccessText>
    <Data>
      <expensesheet_uuid>E4F8CFB657A34540AC7A3A7A1133BC27
      </expensesheet_uuid>
    </Data>
    <Data>
      <expensesheet_expensesheetinternal>1331
      </expensesheet_expensesheetinternal>
    </Data>
  </Success>
</Responses>
{
    "responsecode": 1,
    "responsestatus": "OK",
    "errorcode": 0,
    "errormessage": "",
    "responsemessage": "data processed successfully.",
    "success": true,
    "data": [
        {
            "expensesheet_uuid": "679BC088725B8E469719E41682D7DD67",
            "expensesheet_expensesheetinternal": 1330
        }
    ]
}