Easily retrieve detailed transaction information using the /transactionLines endpoint.
Looking to retrieve transaction details from your 24SevenOffice ERP? We’ve got you covered with a super simple way to get that info via our /transactionLines endpoint. Whether you’re a developer or just a curious person who wants to know more about the transactions going on in your system, this guide will help you along the way!
Important: When referencing API endpoints in your code, be sure to use lowercase instead of camel case. While camel case is used in this article to enhance readability, it's not the format required in the actual implementation. Always refer to the API documentation to ensure correct usage before integrating it into your project.
Here’s the deal:
The /transactionLines endpoint will fetch all the details about a specific transaction. It comes with handy properties, such as transaction.id
and transaction.number
, that identify the transaction you’re looking for.
You can also filter /transactionLines by transactionNumber query parameter if you’re searching for a particular transaction quickly.
Want to know what type of transaction you’re dealing with? There’s an object called transactionType
, which links up with another endpoint, /transactionTypes, to give you more context on what type of transaction you’re looking at.
Example Payload from the /transactionLines Endpoint
Here’s what a typical response looks like when you retrieve transaction details. Don’t worry, it’s pretty easy to understand!
Payload:
{
"id": 7001,
"transaction": {
"id": 3001,
"number": 1010
},
"account": {
"id": 1000001,
"number": 1900,
"name": "Cash, NOK"
},
"transactionType": {
"id": 5001
},
"tax": {
"id": 2001,
"rate": 25
},
"amount": 1500,
"currency": {
"code": "USD",
"rate": 10
},
"date": "2022-07-01",
"invoice": {
"number": "INV-2024-001",
"dueDate": "2024-08-01",
"remittanceReference": "OCR-123456789"
},
"customer": {
"id": 6001
},
"comment": "Payment for services",
"createdAt": "2022-01-01T18:00:00Z",
"modifiedAt": "2023-12-31T18:00:00Z"
}
Key Fields to Notice:
- transaction.id: The unique ID of the transaction.
- transaction.number: The transaction number, perfect for identifying specific entries.
- transactionType.id: This is the type of transaction. You can use this with the /transactionTypes endpoint for more details.
- account: Gives details of the account associated with the transaction line.
- amount: The total amount of the transaction line.
- currency.code: The currency used in this transaction.
- invoice: If the transaction is tied to an invoice, you’ll get all the juicy details right here.
That’s a quick look at how to retrieve transaction details using the /transactionLines endpoint, but there’s so much more you can do! Whether you're building integrations or just curious, the documentation will give you all the tools and insights you need to make the most of 24SevenOffice’s REST API. Happy coding!