Retrieve purchase transaction from Basecone by its unique identifier.
GET transactions/:id
Example response
{
"type": "purchase",
"description": "3.30",
"dueDate": "2014-08-19T00:00:00",
"invoiceNumber": "dfgd4534",
"purchaseOrderNumber": "PO123456789",
"supplier": {
"supplierId": "eda72dba-e8e9-417e-97fa-07ad838c81e7",
"code": "2000",
"name": ""
},
"paymentCondition":{
"paymentConditionId": "d6bbcf34-9fec-40ca-800d-8df0ded40f61",
"code": "30"
},
"isInPaymentBatch": true,
"isCreditNote": false,
"totalAmount": 500,
"transactionId": "6c57832a-959e-4a22-8d76-f2489dc5c448",
"documentId": "d04808be-f40d-4328-82c9-773c110a434e",
"targetCompany": {
"code": "9901"
},
"destinationCompany": {
"code": "9901"
},
"transactionNumber": null,
"transactionDate": "2014-08-05T00:00:00",
"generalLedger": {
"generalLedgerId": "42c79cbd-b845-432c-a67c-ea45739070f7",
"code": "1600"
},
"period": "2014/8",
"currency": {
"currencyId": "c9a4dfa7-7ac6-4a04-9054-c89d2af29d07",
"code": "EUR"
},
"additionalField1": "Some text",
"additionalField2": "Some more text",
"additionalField3": "AAAHlw==D04808BEF40D432882C9773C110A434E",
"transactionLines": [
{
"intraCommunity": {
"code": "0090",
"VatNumber": "NL3298742987",
"Date": "2014-08-05T00:00:00",
"IcpDeliveryType": "goods",
},
"purchaseOrderNumber": null,
"quantity" : {
"value" : 123.45,
"unit" : {
"code" : "mtr"
}
},
"transactionLineId": "fc3fa8ef-ddad-407b-b6f4-ecb3e329f4e3",
"lineNumber": 1,
"description": "3.30",
"additionalField1": "Some text",
"destinationCompany": {
"code": "9901"
},
"generalLedger": {
"generalLedgerId": "42c79cbd-b845-432c-a67c-ea45739070f7",
"code": "0090"
},
"costCenter": {
"code": "00013"
},
"costUnit": {
"code": "D0001"
},
"project": {
"code": "P0008"
},
"amount": 500,
"vatCode": {
"vatCodeId": "ea3123f2-3dd9-4c0b-843d-fb98cc340788",
"code": "IV21"
},
"vatAmount": 120
}
],
"bookYear": 2014
}
Purchase transaction properties
Properties specific to purchase transactions are printed bold, other properties are shared between all types of transactions.
Property |
Type |
Description |
Optional |
AdditionalField1 |
Type |
Additional text field I |
No |
Description |
String |
Description |
No |
DueDate |
DateTime (nullable) |
Due date |
No |
InvoiceNumber |
String |
Invoice number |
No |
PurchaseOrderNumber |
String |
Purchase order number |
No |
Supplier |
Supplier object |
Supplier |
No |
PaymentCondition |
Payment condition object |
Payment condition, not supported for all accounting systems |
No |
IsInPaymentBatch |
Bool |
This indicates and provides a trigger if the transaction needs to be taken into account for any payment run in the 3rd party application. |
No |
IsCreditNote |
Bool |
Indicates whether this transaction is a credit note. |
No |
TotalAmount |
Decimal (nullable) |
Total amount |
No |
TransactionId |
Guid |
Unique identifier of the transaction. |
No |
Type |
String |
Indicates the type of transaction, possible value are cash ,sales ,purchase ,journal . |
No |
DocumentId |
Guid |
Unique identifier of related document. |
No |
TargetCompany |
Company object |
This is the company that is targeted to receive the posting line details. This differs from the destination company. |
No |
DestinationCompany |
Company object |
The destination company is the company to which the header of a transaction in generally booked. |
No |
TransactionNumber |
Long (nullable) |
Transaction number is the unique number per booking, that is a reference for the transaction from Basecone or any other application (3rd party). |
No |
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. |
No |
GeneralLedger |
GeneralLedger object |
This is the code of the ledger that is selected to book a transaction. This represents the category of booking. |
No |
Period |
String |
The period of a transaction relates to the transaction date and represents the specific period in the accounts of a company. |
No |
Currency |
Currency object |
Currency used in transaction. |
No |
AdditionalField1 |
String |
Additional text field I |
No |
AdditionalField2 |
String |
Additional text field II |
No |
AdditionalField3 |
String |
Additional text field III |
No |
IsFinalBooking |
Bool |
Indicates if this transaction is booked as a final booking. |
No |
TransactionLines |
Array |
Collection of transactionlines. Type of transactionline depends on the type of transaction. |
Yes |
BookYear |
Int |
The booking year of a transaction relates to the year in the period property. |
No |
Purchase transaction line properties
Property |
Type |
Description |
Optional |
IntraCommunity |
IntraCommunity object |
This indicates if the VAT code is related to an Intra Community Transaction/delivery. |
No |
PurchaseOrderNumber |
String |
Purchase Order Number |
No |
AdditionalField1 |
String |
Additional text field I |
No |
Quantity |
Quantity object |
This indicates the quantity and unit relevant to the transaction line. |
No |
TransactionLineId |
Guid |
Unique identifier of the transaction line. |
No |
LineNumber |
Int |
Line number |
No |
Description |
String |
Description |
No |
DestinationCompany |
Company object |
The destination company is the company to which the header of a transaction in generally booked. |
No |
GeneralLedger |
GeneralLedger object |
This is the code of the ledger that is selected to book a transaction. This represents the category of booking. |
No |
CostCenter |
CostCenter object |
Cost center |
No |
CostUnit |
CostUnit object |
Cost unit.
Note: currently, supported only on Unit4 companies.
|
No |
Project |
Project object |
Project |
No |
Amount |
Decimal (nullable) |
Amount |
No |
VatCode |
VatCode object |
Vat code |
No |
VatAmount |
Decimal (nullable) |
Vat amount |
No |
Quantity
Property |
Type |
Description |
Optional |
Value |
Decimal |
The actual quantity up to two decimal precision. |
No |
Unit.Code |
String |
The code of the unit used, possible value are kg (kilograms),mtr (meters),pcs (pieces),sqrmtr (square meters),hrs (hours). |
No |
Possible error responses
Status code |
Error code |
Details |
404 |
transaction_not_found |
Transaction with specified unique id could not be found |