-
Notifications
You must be signed in to change notification settings - Fork 30
QR Coding API
QR Codes are used within the Bus CIS server to identify stops and direct smartphones to the mobile-site information for that stop. This API returns BMP images encoding URLs of HTTP://BT.MTA.INFO/S/(Stop_ID)
.
(tdm component)/api/barcode/getByStopId/(stop_id)
The input file should be the body of a POST request to the batch generator service. The file can be of multiple types, including TXT and CSV. The file should look like the following, in this case listing 4 stop_ids to generate:
STOP_ID 1000 2000 2500 568732
Optional Parameter | Controls | Default |
---|---|---|
?img-dimension= | Size of returned image | 99 |
?img-type= | Filetype of the image returns | BMP |
?margin-rows= | The guaranteed minimum number of quiet zone/margin rows in the returned image | 4 |
Barcodes can also be generated in batch. This allows for generating a zip file of barcode images based on an input file containing a listing of stop ids.
The batch generation service allows the same optional parameters as for the single barcode generation. The optional parameters and defaults apply to all of the input files. That means all of the files in the output will have the same dimensions and image type.
NOTE: If the same stop id is listed more than once, just one instance will be returned.
Returns a file of (filetype) from the url or a zipfile of multiple files of (filetype). There is additionally a file Additionally, a data file designed for the HASTUS software is included in the output. This file allows HASTUS to import the QR codes.