Show/Hide Toolbars

How to set up Flowbird Connect

Navigation: Appendix

Specification of SOA service request and response

Scroll Prev Top Next More

This chapter describes the SOA service request and response if custom Ongoing Purchase Provider for an external system is used.

Note:
This description works with a Service Request Type in XML format.

 

Formatting a Request

In the path filed insert the path the the service: e.g. http://xxx.mipermit.net/Services/wsExtPayDisplay.asmx

In the Post Format field insert a request like the example below:

<m:OngoingPurchase xmlns:m="http://xxx.mipermit.net">
  <m:Parking>
    <m:PurchaseGuid>{0}</m:PurchaseGuid>
    <m:TerminalGuid>{1}</m:TerminalGuid>
    <m:TerminalID>{2}</m:TerminalID>
    <m:ArticleID>{3}</m:ArticleID>
    <m:TariffPackageID>{4}</m:TariffPackageID>
    <m:VAT>{5}</m:VAT>
    <m:Amount>{6}</m:Amount>
    <m:Currency>{7}</m:Currency>
    <m:CreateDate>{8}</m:CreateDate>
    <m:StartDate>{9}</m:StartDate>
    <m:EndDate>{10}</m:EndDate>
    <m:Code>{11}</m:Code>
  </m:Parking>
</m:OngoingPurchase>

 

Dynamic variables that can be used in the Post Format for an Ongoing Purchase Provider:

Variable {n}

Variable Name

Description

Data Type

0

PurchaseGuid

Unique purchase ID

guid

1

TerminalGuid

Unique Terminal ID

guid

2

TerminalID

Terminal name

nvarchar(50)

3

ArticleID

Article used in this purchase

int32

4

TariffPackageID

Tariff package used in this purchase

int32

5

VAT

VAT for the purchase

float

6

Amount

Amount for the purchase. 2 decimals, separator can be ',' or '.' (per customer setup)

float

7

Currency

Numeric Currency code (ISO), example 752 for Swedish krona

nchar(3)

8

CreateDate

Date when the customer started the purchase in UTC.

Format: yyyy-MM-ddTHH:mm:ss

example 2010-11-10T00:00:00

DateTime

9

StartDateUtc

Starting date for purchase payment time. Example parking time starting point (after initial free time) in UTC.

Format: yyyy-MM-ddTHH:mm:ss

DateTime

10

EndDateUtc

End date for the purchase, example parking time ending point in UTC.

Format: yyyy-MM-ddTHH:mm:ss

DateTime

11

Code

Manual input in the CWT. Typically used for Vehicle registration number input.

nvarchar(20)

12

NodeName

Name of the node in Terminal Command Center where the terminal is located.

nvarchar(50)

13

ParkingSpaceID

ID of the parking space.

nvarchar(50)

14

StartDateLocal

Starting date for purchase payment time. Example parking time starting point (after initial free time) in Local Time.

Format: yyyy-MM-ddTHH:mm:ss

DateTime

15

EndDateLocal

End date for the purchase, example parking time ending point in Local Time.

Format: yyyy-MM-ddTHH:mm:ss

DateTime

16

Card Fee Amount

Card fee amount for the purchase.  2 decimals, separator can be ',' or '.' (per customer setup)

float

17

Masked PAN

Masked card number (6 first and four last)

Example: 554501*5623

(Only for CWT terminals that uses ongoing purchase version 3)

char(11)

18

Transaction Reference

Reference information for the card transaction.

(Only for CWT terminals that uses ongoing purchase version 3)

nvarchar(128)

19

Units

The number of units/minutes sold

int32

20

Syncronization Mode

Only applicable when the CWT is configured for synchronous ongoing purchase with offline fallback. Either Online or Offline

nvarchar(20)

21

Pay Unit ID

CWT Pay Unit ID. Sample

ID    Description

Coin

Card

Bill

External Payunit 0

External Payunit 1

11     Arcontia Contactless Reader

14     Ponferrada Contactless Reader

18     Santa Monica Contactless Reader

 

(Only for CWT terminals that uses ongoing purchase version 3)

int32

22

Card ID

Card id e.g. Mifare card id

(Only for CWT terminals that uses ongoing purchase version 3)

nvarchar(50)

23

Balance After Debit

Balance After Debit for the purchase when MiFare contactless cards are used.  2 decimals, separator can be ',' or '.' (Only for CWT terminals that uses ongoing purchase version 3)

float

24

Parking Space Location

Location for the Parking Space

nvarchar(50)

25

Article Name

Article name for the article used in this purchase

nvarchar(50)

26

Response External ID at update

If it is a purchase update the response external id for the original purchase is stored in this variable. If it is not an update an empty string is used.

nvarchar(50)

27

Parking Zone Name

Name for the parking zone used in this purchase.

nvarchar(50)

28

Parking Zone Number

Number for the parking zone used in this purchase.

int32

29

Parking ID

Parking ID in WebOffice

int16

30

Ticket Number

Ticket Number used in this purchase

int32

31

Net Amount

Net Amount inclusive VAT for the purchase. 2 decimals, separator can be ',' or '.' (per customer setup)

float

32

Net Amount Exclusive VAT

Net Amount exclusive VAT for the purchase. 2 decimals, separator can be ',' or '.' (per customer setup). Calculation: Net Amount Exclusive VAT =Net Amount/(1+ Article.VAT/10000.0)

float

33

Net Amount VAT

Net Amount VAT for the purchase. 2 decimals, separator can be ',' or '.' (per customer setup). Calculation: Net Amount VAT = (Net Amount - Net Amount Exclusive VAT)

 

34

Purchase PreRequisites External Reference

External reference that will be saved in Purchases

 

 

When sending the request WebOffice will insert the request in a SOAP envelope like done below

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
  <SOAP-ENV:Body>
    <m:OngoingPurchase xmlns:m="http://xxx.mipermit.net">
        <m:Parking>
          <m:PurchaseGuid>{0}</m:PurchaseGuid>
          <m:TerminalGuid>{1}</m:TerminalGuid>
          <m:TerminalID>{2}</m:TerminalID>
          <m:ArticleID>{3}</m:ArticleID>
          <m:TariffPackageID>{4}</m:TariffPackageID>
          <m:VAT>{5}</m:VAT>
          <m:Amount>{6}</m:Amount>
          <m:Currency>{7}</m:Currency>
          <m:CreateDate>{8}</m:CreateDate>
          <m:StartDate>{9}</m:StartDate>
          <m:EndDate>{10}</m:EndDate>
          <m:Code>{11}</m:Code>
        </m:Parking>
    </m:OngoingPurchase>
  </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

 

The response

Requirements of the response

1.Must contain a tag with name OngoingPurchaseResponse.

2.The tag OngoingPurchaseResponse must have a child tag with the name Purchase with an attribute ExternalID if the fields Response Node XPath, Response External ID Attribute, and Response External Description Attribute in form Ongoing purchase provider details are empty. Otherwise these parameters can be used for defining where to find the external id and description in the response message,

Example

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <processResponse>
        <processResult>
          <OngoingPurchaseResponse>
              <Purchase ExternalID="1" ExternalDescription="7a6d7366-ec1d-d663-d10d-cba52ea3a0fb"/>
          </OngoingPurchaseResponse>
        </processResult>
    </processResponse>
  </soap:Body>
</soap:Envelope>

 

Description of variables in response from ongoing purchase provider

Nr

Attribute Name

Description

Data Type

0

ExternalID

Unique purchase identifier in the external system, will be sent to terminal.

If no external ID is received the purchase is cancelled.

nvarchar(50)

1

ExternalDescription

Description (Option). Will be sent to terminal if terminal uses ongoing purchase version >1.

nvarchar(255)

2

ResultCode

Result code from third party.

Result code can be set to one of following values:

1 = Accepted (request is accepted at third party)

2 = No respons (No response from third party)

3 = Denied (The request is actively denied at third party)

byte