VISMA AccountViewDankzij de BackOffice Server (BOS) óf de COM Client Access module van AccountView is het mogelijk om applicaties aan uw AccountView administratie te koppelen. Echter ontbreekt de BackOffice Server van AccountView een eenvoudige methode om verzoeken in te dienen en het resultaat weer op te vragen en bij de COM Client Access module moet u zelf een directe koppeling ontwikkelen. Met andere woorden, er wordt geen oplossing geboden voor het transporteren van gegevens tussen uw applicatie en AccountView.

Met de Communicatieserver van Kras IT, ook wel AVRESTWS genoemd, kunt u middels een HTTP REST API op eenvoudige wijze XML verzoekbestanden uploaden. Wanneer de AccountView BackOffice Server of de COM Client Access module het verzoek heeft verwerkt krijgt u direct het resultaat terug. Of, indien dit niet nodig is kunt u het resultaat op een later tijdstip opnieuw opvragen (alleen bij BOS).

Door gebruik te maken van de Communicatieserver kunnen ontwikkelaars direct bezig gaan met de ontwikkeling van hun koppeling met AccountView, zonder zich druk te hoeven maken over hoe ze de gegevens op een betrouwbare moeten uitwisselen.

Voordelen voor de ontwikkelaar zijn dan ook:

  • Snelle installatie van een kant en klare oplossing om berichten uit te wisselen middels de BOS server of COM Client Access module. Dit bespaart tijd in het zelf ontwikkelen van een betrouwbare communicatieoplossing.
  • Real time data uitwisselen met de BOS server of COM Client Access module. Tientallen berichten gelijktijdig is geen probleem, de BOS server vormt de bottleneck. Bij COM Client Access ligt het aantal gelijktijdige verzoeken lager.
  • Eenvoudige interface voor het uitwisselen van XML berichten middels HTTP(S).
  • Mogelijkheid om diverse gebruikers toe te kennen met toegang tot de Communicatieserver. Daarnaast kunt u nog steeds de gebruikersauthenticatie van AccountView gebruiken.
  • Veilige verbinding middels HTTPS/SSL.

Prijzen

  • Aanschaf licentie (per server) € 400,-.
  • Na het eerste jaar worden er jaarlijkse onderhoudskosten gerekend die de continuïteit van het product garanderen. Deze kosten betreffen 12% van de licentiekosten, á € 48,- p/j.
  • Indien Kras IT voor u de installatie moet verrichten wordt daar het reguliere uurtarief voor gerekend.
  • Let wel dat u ook in het bezit moet zijn van de AccountView module AccountView .NET BackOffice Server (“BOS”) óf COM Client Access.

Heeft u interesse in het gebruik van de Communicatieserver voor AccountView neem dan gerust contact op. Wij bespreken graag de mogelijkheden met u.

Huidige Versie: 1.04

# DESCRIPTION

AVRESTWS is a communication server for AccountView using either the .NET
BackOffice Server (BOS for short) or the COM Client Access module. AVRESTWS
works in cojunction with either of these modules.

The BOS server does not provide any means for transporting request and response
files. AVRESTWS solves this problem by providing an HTTP REST API which can be
used to upload AVXML request files and returns the response generated by the
BOS server.

Aside from the BOS server the COM Client Access module is also supported.
Whilst this module isn't as performing as the BOS server it's very capable of
processing requests. Best used when not many concurrent requests to AccountView
are required.

## HOW DOES IT WORK

Depending on the mode, BOS or COM, AVRESTWS behaves differently. BOS has some
benefits over COM, mainly performance and being able to drop a request and
retrieve it when you see fit. With COM you're forced to wait for the response.

### Using BackOffice Server

When AVRESTWS retrieves a request it puts the content body of the HTTP POST
request inside an XML file which is stored inside the -avs-directory. It then
monitors the Response/ folder inside the -avs-directory and returns the
generated response by the BOS Server, if any has been generated. If after
-timeout seconds the BOS server hasn't responded with an answer it'll generate
a time out. If the Request ID has been stored the contents of the response file
can always be retrieved on a later time, given that the BOS server has
processed the request file.

### Using COM Client Access

When AVRESTWS retrieves a request it uses the COM Client Access library to
connect to AccountView. It then runs your XML script and returns your response
as soon as it's ready.

# USAGE

avrestws.exe [flags] [command]

## FLAGS

## General
  -config="config.ini": Config file to use
  -tls=false: Use HTTPS
  -tls-cert="cert.pem": Default certificate to use
  -tls-key="key.pem": Default key to use
  -mode="BOS": Defaults to BOS. Use COM when using the COM Client Access module

### For use with the BackOffice Server
  -avs-directory="./": Path to avs/ directory
  -host="": Default listen host
  -port=9000: Default listen port
  -timeout=30: Default waiting time for BOS to respond to request

## COMMANDS

  run               Run (default if omitted)
  install           Install as Windows Service
  uninstall         Uninstall Windows Service
  start             Start Windows Service
  stop              Stop Windows Service
  version           Show version number of AVRESTWS

## CONFIGURATION

Configuration is done by passing flags to avrestws.exe. Use config.ini to
define which users have access to the HTTP REST API. For example:

  [users]
  john = abcdefghijk
  jane = lmnopqrstuv

# INSTALLING AS SERVICE

To install AVRESTWS as a Windows Service run the command with the flags you
want the service to use.

## Using BackOffice server

  avrestws.exe -avs-directory="D:\Program Files (x86)\Visma Software BV\AccountView\avs" -config="F:\Software\avrestws\config.ini" install

This will override the defaults for -avs-directory and -config. Be sure to
provide full paths. If a flag is omitted it will fall back to its default
value.

## Using COM Client Access

  avrestws.exe -mode=COM -config="F:\Software\avrestws\config.ini" install

# HTTP REST API

Basic HTTP Authentication is used. Users are defined inside the configuration
file. Available routes are:

  GET     /status                 To see if service is running
  GET     /exchange?id=<ID>       Retrieve response for request with id <ID>.
                                  This route is not available when -mode=COM
  POST    /exchange               Post XML payload for AccountView
                                  The optional settings below are not available
                                  when -mode=COM:
                                  - add ?delete_response=1 in case you want the
                                   response file to be deleted afterwards.
                                   Useful for requests that are solely there to
                                   retrieve data and not clogging the file
                                   system with all these request files.
                                 - add ?delete_request=1 in case you want the
                                   request file to be deleted afterwards.
                                 - add ?wait=0 if you don't need the response
                                   right away but will use its ID later on,
                                   allowing the request to finish before
                                   receiving the response from AccountView.
                                   Don't mix this with delete_response. It
                                   defaults to 1.

When POSTing to /exchange an HTTP header named X-Request-Id will contain the
Request ID which can be used when calling GET /exchange?id=<ID> to retrieve the
contents of the response. Use cases of this can be when the BOS server is not
running and not processing requests.

## RESPONSE CODES

  GET   /*                      403     Authentication failed
  GET   /exchange?id=<ID>       404     Response file not found
  POST  /exchange               500     Server error, inspect response body

# AUTHORS

AVRESTWS is a product developed and owned by Kras IT. AVRESTWS and Kras IT are
not related to AccountView or Visma Software BV.

http://www.kras-it.nl
info@kras-it.nl

# LICENSE

Copyright (c) 2013-2016 Kras IT

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
Revision history for Project.

1.04  2016-04-14
    - Added support for AccountView COM Client Access as an alternative to BOS.

1.03  2016-04-06
    - Added optional ?wait=0 to immediately return a 204 No Content response
      after posting a request.

1.02  2016-03-10
    - Fixed warning when generating UUID on Windows Server 2012.

1.01  2015-05-20
    - In some configurations the FileWatcher didn't work properly which
      resulted in not being properly notified that the response file was ready.
      This would occur on Windows Server 2012 R2.
    - Fixed server crash when request file could not be written to avs/
      directory.
    - Added ?delete_request in addition to ?delete_response.

1.00  2015-04-17
    - Initial release.