Overview
The Unit4 Access Point java API, code named Ringo, is the easiest way to communicate with the Unit4 Access Point if you use java.
Just download required libraries and use the following snippet of code as an example to get started.
The Unit4 Access Point java API, code named Ringo, is the easiest way to communicate with the Unit4 Access Point if you use java.
Just download required libraries and use the following snippet of code as an example to get started.
Download Ringo client and add ringo-client.jar
and ringo-api.jar
to the classpath of your project
First step is to create the client instance. In order to so do you must provide a RingoConfig object, a username and a password. There is a DefaultRingoConfig implementation which has some sensible defaults and just requires AccessPoint service address.
Use Inbox
object to download unread messages. To get hold of it just call getInbox()
method on the client instance.
Next step is to call getMessages()
to get access to new messages which then can be downloaded and marked as read as shown below.
Note: Calling getMessages()
will return only first 25 messages. To retrieve next messages, previous ones must be marked as read and the method
needs to be called again.
To send an invoice use client's send
method. There're two variants which allow to pass either a file or a stream.
The result is an instance of sent message.
This example demonstrates how to use the method.
Using client's isParticipantRegistered
method you can check if legal entity with given participant id is registered in PEPPOL network.
The method will return either true or false
Using client's fetchAcceptedDocumentTransfers
method you can fetch a list of PEPPOL DocumentType Identifiers and PEPPOL ProcessType Identifiers accepted by legal entity with given participant id..