API documentation

Create PSCS payment V1

Our platform is integrated with Netopia MobilPay and for the moment we use their sandbox platform. For further details please contact us.
Only for testing you can use the following cards that are accepted by the sandbox platform:

9900004810225098 - accepted card with CVV=111
9900541631437790 - expired card

POST /api/order_pscs

Include access_token in HTTP header:

Authorization: Bearer 09ba487fc3df...

Description

This web service is used to create a payment in our database and receive information that should be used to create the actual payment on the remote payment service.

REQUEST PARAMETERS

Parameter name Parameter type Description
duration_minutes int desired duration for the parking in minutes
car_id int id of the car for which the payment is made
zone_id int id of the zone where the payment is made
return_url string Base64(return_url) url where the payment service will redirect after the payment
start_time datetime start_time to use when creating the order, defaults to current time (OPTIONAL)
parking_id int id of the parking on which the user makes the payment (OPTIONAL)
latitude float location of the user from which he makes the payment (OPTIONAL)
longitude float location of the user from which he makes the payment (OPTIONAL)
{
   "duration_minutes" : 90,
   "car_id" :  3,
   "zone_id" : 1,
   "return_url" : Base64(return_url),
   "start_time" : "2014-10-10T10:33:19Z", // Optional
   "parking_id" : <<parking_id>>, // Optional
   "latitude" : 46.1234,       // Optional
   "longitude" : 23.1234       // Optional
}

Regarding the optional fields there are 4 cases:

  1. Both location and parking_id is given => They are just saved as received.
  2. Only location is given => Parking is deduced as the closest Parking to the given location.
  3. Only parking is given => Location is set to that Parking location.
  4. Neither a location nor a parking are given => No PaymentLocation is created.

Response

Status Code: 201 if OK

{
       "id": 12,
       "duration_minutes": 90,
       "start_time": "2014-10-10T10:33:19Z",
       "end_time": "2014-10-10T12:03:19Z",
       "pay_amount": "3.0",
       "pay_url" : "<<pay_url>>",
       "is_card_verification" : true,
       "env_key" : "<<env_key>>",
       "data" : "<<data>>"
}

Response parameters

Parameter name Parameter type Description
id int id of the payment
duration_minutes int desired duration for the parking in minutes
pay_amount string price of the parking
pay_url string url to be used to post the env_key and data parameters in order to make a payment
is_card_verification bool true if there was no card created and a card is about to be created
env_key string key to be sent to pay_url link in order to create a payment
data string data to be sent to pay_url link in order to create a payment
start_time string parking start time
end_time string parking end time

Using these three params:

       "pay_url" : "<<pay_url>>",
       "env_key" : "<<env_key>>",
       "data" : "<<data>>"

You have to make a POST to the pay_url with the other two params. This will redirect the user to the mobilPay web site that will make the actual payment and redirect to given return_url.

Status Code: 400 if return_url is missing

Status Code: 401 if request access token not ok

Status Code: 404 if zone_id or car_id not ok

Status Code: 422 if there were errors (messages included in body)


Create PSCS payment V2

V2 also integrates the EPX payment provider and it's in testing mode for now.
Only for testing you can use the following card that is accepted by EPX's testing platform:
4000000000000002 - accepted card with CVV=123, EXP_DATE=12/2025, ADDRESS=123 NN CENTRAL, ZIP=12345

When the MobilPay provider is set on platform you can use the MobilPay cards from V1.

POST /api/order_pscs

Include access_token and version in HTTP headers:

Authorization: Bearer 09ba487fc3df...
Accept: application/vnd.parkingplus.v2+json

Description

Same as for v1.

REQUEST PARAMETERS

Same as for v1.

Response

Status Code: 201 if OK

{
       "id": 12,
       "duration_minutes": 90,
       "start_time": "2014-10-10T10:33:19Z",
       "end_time": "2014-10-10T12:03:19Z",
       "pay_amount": "3.0",
       "pay_url" : "<<pay_url>>",
       "pay_params": {
           "env_key" : "<<env_key>>",
           "data" : "<<data>>"
         },
       "is_card_verification" : true,
}

Response parameters

Parameter name Parameter type Description
id int id of the payment
duration_minutes int desired duration for the parking in minutes
pay_amount string price of the parking
pay_url string url to be used to post the env_key and data parameters in order to make a payment
is_card_verification bool true if there was no card created and a card is about to be created
pay_params object object containing the parameters to be sent to pay_url in order to make a payment
env_key string key to be sent to pay_url link in order to create a payment
data string data to be sent to pay_url link in order to create a payment
start_time string parking start time
end_time string parking end time

Note: The "pay_params" above are for when the MobilPay provider is enabled. And the pay_url, env_key and data can be used to create a payment the same way as for v1.

For when EPX provider is enabled the "pay_params" will look like this:

  "pay_params": {
    "cust_nbr": "<<cust_nbr>>",
    "merch_nbr": "<<merch_nbr>>",
    "dba_nbr": "<<dba_nbr>>",
    "terminal_nbr": "<<terminal_nbr>>",
    "amount": "3.00",
    "tac": "<<TAC token>>",
    "redirect_url": "http://www.example.com/epx_confirm",
    "tran_nbr": 1,
    "batch_id": 0,
    "invalid_redirect_url": "http://www.example.com/epx_invalid"
  }

You have to make a POST to pay_url with the parameters inside pay_params. This will redirect the user to the EPX web site that will make the actual payment and redirect to the redirect_url.

Status Code: 400 shouldn't happen because return_url is no more required

Status Codes: 401, 404 and 422 are the same as for v1


Create PSCS payment V4

V4 integrates the EPX payment provider and it's in testing mode for now.

Only for testing you can use the following card that is accepted by EPX's testing platform:
4000000000000002 - accepted card with CVV='', EXP_DATE=12/2025

When the MobilPay provider is set on platform you can use the MobilPay cards from V1.

POST /api/order_pscs

Include access_token and version in HTTP headers:

Authorization: Bearer 09ba487fc3df...
Accept: application/vnd.parkingplus.v4+json

Description

This web service is used to create a payment in our database and receive a link that should be used to create the actual payment on the remote payment service.

REQUEST PARAMETERS

Same as for v1.

Response

Status Code: 201 if OK

{
       "id": 12,
       "duration_minutes": 90,
       "start_time": "2014-10-10 10:33:19",
       "end_time": "2014-10-10 12:03:19",
       "pay_amount": "3.0",
       "currency": "USD",
       "pay_url" : "<<pay_url>>"
}

Response parameters

Parameter name Parameter type Description
id int id of the payment
duration_minutes int desired duration for the parking in minutes
start_time string parking start time
end_time string parking end time
pay_amount string price of the parking
currency string currency iso code (ex: USD, EUR, GBP, CHF)
pay_url string url to be used to make a GET request in mobile WebView in order to continue with the payment

Note: After the actual payment is finished on the remote payment service it will redirect to the redirect_url request parameter.

Status Codes: 400, 401, 404 and 422 are the same as for v1