HK-FERRY-ROUTE
Hong Kong Ferry route Info Retrieval Script Documentation
GET
https://api.kosontechnology.com/hk-ferry.php
This API script is designed to retrieve information from the Hong Kong Ferry Route info database using provided parameters.
Path Parameters
district
String
To specify the district type
routeNameE
String
To specify the desire route name in English
serviceMode
String
To specify the desire service mode
specialType
Integer
To specify the desire fare type
routeSeq
Integer
To specify the desire route sequence
stopNameE
String
To specify the desire stop name in English
download
-
To download the json file
This API script is designed to retrieve information from the Hong Kong Ferry Route Information database using provided parameters. The script constructs the appropriate URL based on the parameters provided and then fetches data from the API. Please follow the instructions below to use this script effectively.
Usage
1. Making an HTTP request via a web browser or API Platform etc. Postman.
2. The following parameters are accepted:
district
To specify the district type
District type. Etc. KAITO
routeNameE
To specify the desire route name in English
Route Name. Etc.
Po Toi Island - Aberdeen
ServiceMode
To specify the desire service mode
Ferry service mode. Etc. T
specialType
To specify the desire fare type
Fare type. Etc. 1
routeSeq
To specify the desire route sequence
Route sequence. Etc. 1
stopNameE
To specify the desire stop name in English
Stop name. Etc. Po Toi Island
download
To download the JSON output
This parameter does not require the content, Leave empty or Type anything is acceptable.
Depending on the parameters provided, the script will construct a URL to fetch information from the hk-ferry-route database.
Parameter Guidelines
district
Parameter:If you provide a
district
parameter of district type etc. 'KAITO', the script will retrieve the district type.
routeNameE
Parameter:If you provide a
routeNameE
parameter of route name etc. 'Po Toi Island - Aberdeen', the script will retrieve route name.
serviceMode
Parameter:If you provide a
serviceMode
parameter of service mode type etc. 'T', the script will all information for selected service mode.
specialType
Parameter:If you provide a
specialType
parameter of fare type etc. '1', the script will retrieve selected route information of the fare type.
routeSeq
Parameter:If you provide a
routeSeq
parameter of route sequence etc. '1', the script will retrieve selected route sequence information.
stopNameE
Parameter:If you provide a
stopNameE
parameter of stop name etc. 'Po Toi Island', the script will retrieve information that is matches the selected stop name.
download Parameter:
If you want to download the JSON output of these parameters, define the download parameter with empty or any input will enable you to auto download it. See the download sample here.
List of District
KAITO
INNER
OUTLYING
List of Route Name and Stop Name
can refer link below to get the detail of the route name and stop name.
List of Service Mode
A=whole
N=night
NT=night & specific time
R=regular/day
T=regular & specific time
List of Special Type
0=Not applicable
1=Time or day specific services
2=Separate fare for weekend and Public Holidays
3=Time or day specific and separate fare for weekend and PHs
List of Route Sequence
1 = outbound or circular route
2 = inbound
Demo
Download
Add download at the back of the link to download the database in json format.
Last updated