Update transaction proposals

Update transaction proposal by its unique identifier.

This API resource is only available to Premium APPs.

PUT transactionproposals/:id

When updating a transaction proposal the API expects all properties to be filled, missing properties or properties with value null will be cleared.

Transaction
Cash transaction proposals
Journal transaction proposals
Purchase transaction proposals
Sales transaction proposals
Special options
Auto create supplier

Transaction proposal update properties

All transaction proposal update models share the following properties. Properties specific to one type of transaction are explained in the specific resource pages.

Property Type Description Optional
Period String The period of a transaction relates to the transaction date and represents the specific period in the accounts of a company. Yes
TransactionDate DateTime (nullable) This is the date of the transaction, in most cases the invoice date. The invoice date is generally mentioned on each invoice and differs from the transaction date. Yes
TransactionLines Array Collection of transactionlines. Yes
AdditionalField1 String Additional text field I. Yes
IsFinalBooking Bool Indicates if this transaction needs to result in a final booking. Yes
Currency Reference object Mandatory Currency used in transaction. No

Transaction line properties

When updating lines new TransactionLineId will be created unless an existing TransactionLineId is provided.

All transaction lines share the following properties. Properties specific to one type of transaction are explained in the relevant resource page.

Property Type Description Optional
TransactionLineId Guid Unique identifier of the transaction line. Yes
Description String Description Yes
DestinationCompany Reference object Mandatory The destination company is the company to which the header of a transaction in generally booked. No
GeneralLedger Reference object This is the code of the ledger that is selected to book a transaction. This represents the category of booking. Yes
CostCenter Reference object Cost center Yes
CostUnit Reference object Cost unit.

Note: currently, supported only on Unit4 companies.

Yes
Project Reference object Project Yes
Amount Decimal (nullable) Amount Yes
VatCode Reference object Vat code Yes
VatAmount Decimal (nullable) Vat amount Yes

Reference object properties

A multipurpose reference object that is used to encapsulate a reference to a complex object.

Property Type Description
Code String The code for a particular complex object, typically this will be an externalId.

Response

Upon successful update of a transaction proposal in the Basecone system, a 200 http status code will be returned together with the update transaction proposal TransactionId unique identifier. If something goes wrong, an error message with failure details will be given together with a suitable http error status code.

Example of a successful response

{
  "companyId": "52a4471b-8cb4-4a13-981f-86a30b72feff"
}

Example of an error response

{  
  "message": "One or more validation errors occurred.",
  "code": "validation_error",
  "_metadata":[  
    {  
      "field": "company",
      "message": "UnknownTargetCompany",
    },
    {  
      "field": "currency",
      "message": "UnknownCurrency",
    }
  ],
  "_moreInfo":"http://developers.basecone.com/lookup/validation_error"
}

Possible error responses

Status code Error code Details
400 invalid_request_payload Transaction identifier is not valid.
400 validation_error Request failed with one or more validation errors (see below). For more information about how to handle validation errors, please consult client side errors section.
Possible validation error responses
Status code Error code Details
400 transaction_does_not_exist Transaction identifier is unknown.
400 unknown_target_company Destination company reference is unknown.
400 unknown_currency Currency reference is unknown or not supported.
400 document_immutable Associated transaction document is immutable.
400 user_does_not_have_access_to_document User has no access to the associated transaction document.