API Endpoints

Asperion Public REST API Endpoints

API Endpoints

Asperion has made an API available for third party software developers that intend to connect their commercial applications to the Asperion accounting software platform. Herewith an overview of all available endpoints with the opportunities and impossibilities. 

The documentation is enriched with additional information, which you could take into account with this API.  
For more general information about this API and the authorization via oAuth, see: Asperion REST API

More technical information can be found in the online Swagger docs: https://api-sandbox.asperion.nl/swagger/

 

Administrations

/v1/administrations (readonly)

List with available adminstrations (tenants) and details about an administration.
A user can access 1 or more administrations.
After retrieving an access token, the default administration of the client is selected.
You can retrieve the data of another administration (Tenant) by adding a parameter X-TenantId in the header.

 

Approvalroutes

/v1/approvalroutes (readonly)

List with available approvalroutes. If this option is activated in the administration, this will be a mandatory option when creating Purchase Invoices.
This is the list with the available routes for the selected administration.

 

Articles

 /v1/articles (read/write)

Articles management. Overviews of the articles can be retrieved with this endpoint and articles can be created and updated.
Attributes like the current stock (currentStock) can’t be edited, since this would have accounting consequences. This can only be done via the Asperion Application. 

An article can be active or inactive. Default the GET endpoints will only return active articles. If you need to search the inactive articles as well please use the ActiveState property.

If trade applications are used in Asperion (inTrade pack), the stock can be edited by creating new orders via the endpoint: /v1/SalesOrderWithLines/

Attribute "SalesTypeId" refers to the different sales types. (See endpoint: /v1/salestypes)
This determines the ledger calculation, where the sales of this article are based on.

 

ArticleLocations

/v1/articlelocations (readonly)
/v1/articlelocations/{id}/ (readonly)

This option is limited to inTrade users who manage inventory.​
Items can be stored in different locations (warehouses). An item can be linked to a location where this item can be found in the order picking process. This endpoint returns all available locations.

 

CostCenters

/v1/costcenters(readonly)

List of available costcenters that can be used with invoices or journal entries if the administration used costcenters.

 

CostUnits

/v1/costunits (readonly)

List of available cost units that can be used with invoices or journal entries if the administration used cost units.

 

CostUnitTypes

/v1/costunittypes (readonly)
/v1/costunittypes/{id} (readonly)

List of available cost unit types. A cost unit type can be used to characterize and filter cost units.

 

Countries

/v1/countries (readonly)

List with available countries that can be used when creating the master data of debtor/creditor or (concept) invoices.
All countries of this list are supported by Asperion.

 

Creditors

/v1/creditors (read/write)

Management of creditors (Suppliers). Can be used for the retrieval of creditor information, creating or updating the creditor information.
Can also be needed when creating a purchase invoice. 
A creditor has to be member of a creditor kind attr: creditorKindId. (see endpoint: creditorkinds)

 

Creditorkinds

/v1/creditorkinds (readonly)

Characterization / group of a creditor. Determines the contra account for the creditor payment in the ledger in Asperion.
A creditor has a required creditor kind

 

Debtors

/v1/debtors (read/write)

Management of the debtors/clients. Can be used when retrieving, creating or editing the debtor information.  
Can also be needed when creating a sales invoice (SalesInvoice / DraftSalesInvoice) or sales order (SalesOrderWithLines)
A debtor has to be member of a debtor kind. (See: debtorkinds)

 

Debtors - Mandates

/v1/debtors/{debtorId}/mandates (read/write)

Management of SEPA debtor mandates.
Mandates are needed to generate debtor mandates in Asperion.

Special attention to the following fields:

PUT endpoint suitable for updating the signdate.

 

Debtorkinds

/v1/debtorkinds(readonly)

Characterization / group of a debtor. Determines the contra account for the debtor payment in the ledger in Asperion.
A debtor has a required debtor kind

 

DraftSalesInvoices

/v1/draftsalesinvoices(read/write)

Draft Invoices. Creating and editing invoices in Asperion module Invoicing. If invoices are created here, you can make them final and provide them with an invoice number and layout. This endpoint will be the header of the invoice. Invoice lines are made with endpoint: /v1/draftsalesinvoices/{invoiceId}/lines

To create invoices with all the lines in one post, see endpoint: DraftSalesInvoicesWithLines 

Invoice lines:

The invoice lines can consist of the types: (bookingType) "A" = Article, "V" = Sales type, "G" = Ledger Account or "T" = Text.

 

Including or Excluding the VAT

When the origin system stored the line amounts including VAT end when calling the API rounding differences may occur when converting to exclusive amounts. In this case, you can also specify the unit price (unitPrice) including VAT. For this you pass the parameter unitPriceIncludingVat = true.

DraftSalesInvoicesWithLines

/v1/draftsalesinvoiceswithlines (read/write)

Draft invoices (Module Invoicing). Creating invoices in Asperion module Invoicing with all lines. This way, a draft invoice can immediately be created.
Also see endpoint: DraftSalesInvoices.

 

Files

/v1/files (readonly)

Downloading PDF files based on the id. Like the scan of the purchase invoice or receipt.

 

InboxFiles

/v1/inboxfiles (POST / GET)

InboxFiles is the central list with documents that still need to be processed into the administration.
These inboxfiles can also be (scans of) purchase invoices, sales invoices or receipts for further processing of Asperion.

Downloading PDF files from the inbox file list based on the id. (GET)
Adding PDF files tot he inbox, max. 5mb (POST)

Journals

/v1/journals (readonly)

Journals used by the Administration. This can be used for the retrieval of the available journals.
Among others needed for the creation of journal entries (JournalEntries)
The following types of journals are available. (M = Memorial, K = Cash Registration)

 

Journalentries

/v1/journalentries (read/write)
/v1/journalentrieswithlines (read/write)

Endpoint for the creation of Journal entries and Journal entries with lines. Journal entries enter Asperion as a draft, ready to process.

A journal entry always consists of a valid:

Furthermore, a description can be added, like “Ledger June 2021”, and a Date.
The creation of journal posts is limited to the types: (M) Memorial or (K) Cash Registration.
Memorial journal posts (lines) have to be balanced. (Debit sum = Credit sum) 
Treasury journal posts have to be provided with an opening balance and closing balance. (openingBalance / closingBalance) differences between these balances have to be documented as line(s).

 

JournalEntryLog

/v1/journalentrylog (readonly)
/v1/journalentrylog/{id}/ (readonly)

Endpoint to get the changelog of Journalentries. Usefull to get all changed journnalentries in a date/time range.

There a 2 type op registration actions. 1 = added en 2 = reverted journalentries. 

 

LedgeraccountClassifications

/v1/ledgeraccountclassifications (readonly)

Structure of the list of accounts. Ledger accounts and compaction structure of the administration, including RGS coding.
Usage with reportsoftware like PowerBI, for the retrieval of the classification and compaction structure. See endpoint LedgerGrouped for the actual ledger data

 

Ledgeraccounts

/v1/ledgeraccounts (readonly)
/v1/ledgeraccounts/{id} (readonly)

List of available ledger accounts in the selected administration (tenant). Or the details of a ledger account like the description, Type, RGS code etc.
A ledger account follows a certain type. In order to filter for the use.

Filter on Type

 

LedgerAccountTypes

/v1/ledgeraccounttypes (readonly)
/v1/ledgeraccounttypes/{id} (readonly)

List with available ledger account types. Also see endpoint: Ledgeraccounts.

 

LedgerGrouped

/v1/ledgergrouped (readonly)

List with balance per ledger account for a specified period (bookyear = required).


Extra options to group per journal, etc.



This is meant for exporting the booking data from Asperion for an administration for the use of report software or other sort of reporting applications.

Furthermore, a couple of fields are available to filter the results.
An important thing to take into account is the filter on BalanceOrProfitLoss

 

LedgerLines

/v1/ledgerlines (readonly)

Endpoint to retrieve a selection of ledger transactions. Various filter options to select the right mutations. Fiscal year is a mandatory parameter. Can be used, for example, to collect payments on an invoice.

 

OutstandingPurchaseInvoices

/v1/outstandingpurchaseinvoices (readonly)

List with all outstanding purchase invoices from the selected administration (tenant).
Including the information from the invoice (outstanding sum, date, age and days till expiry) and information about the creditor. (Name, number and ID)
A couple of fields are available to filter the results on

 

OutstandingSalesInvoices

/v1/outstandingsalesinvoices (readonly)

List with outstanding sales invoices from the selected administration.  
Including the information of the invoice (outstanding sum, date, age and days till expiry) and information about the debtor. (Name, number and ID)
A couple of fields are available to filter the results on

 

Paymentconditions

/v1/paymentconditions (readonly)

Payment conditions available in the administration.

Can be used with the DraftSalesInvoice, DraftSalesInvoiceWithLines, SalesInvoices and SalesInvoicesWithLines

 

PaymentMethod

/v1/paymentmethod (readonly)

List with available payment methods.  
Can be used with the DraftSalesInvoice and DraftSalesInvoiceWithLines endpoints.
Examples: IDEAL, PayPal, Invoice, Bol.com, Creditcard etc.

 

PurchaseInvoices

/v1/purchaseinvoices (read/write)
/v1/purchaseinvoiceswithlines (read/write)

Creating or retrieving of purchase invoices from the administration (tenant).
Seperately creating the header and invoice lines via endpoint /v1/purchaseinvoices 
Or the complete invoice including lines via endpoint: /v1/purchaseinvoiceswithline


This endpoint is used when adding purchase invoices that have already been coded in another pack. These are already provided with the correct ledger account coding, correct creditor, etc.
The purchase invoices will be filled in ready-made via these API.
If there aren’t assigned any ledger accounts, the invoice will be read via the PDF scan via the endpoint /v1/InboxFiles.

Via the GET endpoints, the purchase invoice details can be retrieved.
You can also add an invoice scan (PDF) to the purchase invoice with the endpoint: /v1/purchaseinvoices/{id}/file [POST]


 

 

SalesInvoices

/v1/salesinvoices (read/write)
/v1/salesinvoiceswithlines (read/write)

 

Creating or retrieving of sales invoices from the administration.
Seperately creating the header and invoice lines via endpoint /v1/salesinvoices 
Or the complete invoice including the lines via endpoint: /v1/salesinvoiceswithline

This endpoint can be used for the creation of sales invoices that have already been coded in another pack. These have already been provided with the correct ledger account coding, correct debtor, etc.
The sales invoices will be entered “ready-made” via this API.
If there aren’t assigned any ledger accounts, the invoice will be read via the PDF scan via the endpoint /v1/InboxFiles.

Via the GET endpoints, the details of sales invoices can be retrieved.
You can also add an invoice scan (PDF) to the purchase invoice with the endpoint: /v1/salesinvoices/{id}/file [POST]

 

SalesOrders

/v1/salesorders(read/write)

Creating and editing of sales orders.
* There are only applicable if the administration has the inTrade pack or the module sales order.

Sales order endpoint can be used for retrieving order information or updating the order. For example, a shipping date or address.

To manage the orderlines see endpoint SalesOrderWithLines

 

SalesOrderWithLines

/v1/salesorderwithlines (read/write)

Creating and editing of sales orders with lines.
* There are only applicable if the administration has the inTrade pack or the module sales order.

The sales order lines can only be of types: (bookingType) "A" = Article or "T" = contains text.
This concerns the enpoint for the creation of sales orders, meant for the distribution of ordered products.
A sales order has to consist of at least 1 line with the bookingType "A". 

If the field bookingType "A" Article is used, the field ArticleSku (Article number) would also be required. The bookingType "T" is for additional lines of text.

 

SalesTypes

/v1/SalesTypes (readonly)

List with available sales types from the administration (tenant).
For the use in DraftSalesInvoices*, SalesInvoices* endpoints.

 

VatCodes

/v1/vatcodes (readonly)

List with available VAT codes from the administration.
For the use in DraftSalesInvoices*, SalesInvoices*, PurchaseInvoices* endpoints.

Use the field: salesCode (bool) as a filter to retrieve either the sales codes or purchase codes.

 

 

Tags
Disclaimer:
De voor u beschikbare functies worden bepaald door het type abonnement dat is afgesloten. Sommige hier beschreven functies kunnen voor u dus niet beschikbaar zijn en/of soms iets anders werken dan zoals hier beschreven.

Hoewel bij de totstandkoming van de informatie in dit document de uiterste zorg is betracht en er naar gestreefd is om deze informatie zo compleet en volledig mogelijk te maken en te houden, kan Asperion noch de juistheid, noch de volledigheid, noch een specifieke toepasselijkheid van de gepubliceerde en/of gevraagde informatie in dit document garanderen. Asperion wijst iedere aansprakelijkheid af voor enige directe, indirecte of gevolgschade, schade in de vorm van gemiste winst of van bedrijfsonderbreking welke het gevolg zou zijn van het gebruik van dit document. Het ontlenen of gebruik van informatie uit dit document geschiedt te allen tijde op eigen risico van de gebruiker. Teksten kunnen, zonder kennisgeving vooraf, veranderd worden.

Niets uit deze uitgave mag worden verveelvoudigd, opgeslagen in een geautomatiseerd gegevensbestand, of openbaar gemaakt in enige vorm, op enige wijze, hetzij door middel van druk, fotokopieën, microfilm of op welke andere wijze dan ook, zonder voorafgaande schriftelijke toestemming van Asperion

© Copyright - Asperion® en het Asperion logo zijn zowel handelsnaam als geregistreerde handelsmerken van Asperion Software B.V.