-
Notifications
You must be signed in to change notification settings - Fork 29
Bundle API
carabalb edited this page Nov 5, 2025
·
14 revisions
This API returns bundle information in JSON form.
(tdm component)/api/bundle/(option)
| Option | Operation |
|---|---|
| list | Fetch the list of all bundles available from the TDM |
| (bundle-id)/file/(bundle-files-filename)/get | Download a single file from the TDM |
{
"bundles": [
{
"id": "2012_September_Bronx_Subway_r01_b02",
"name": "2012_September_Bronx_Subway_r01_b02",
"applicable-agency-ids": ["MTA NYCT"],
"service-date-from": "2012-10-02",
"service-date-to": "2013-01-05",
"created": "2012-10-03T11:56:01-04:00",
"updated": "2012-10-03T11:56:01-04:00",
"files": [
{ "filename": "org_onebusaway_transit_data.script", "md5": "6c21ec01399fdbbfff4c857f94843a06" },
{ "filename": "StopSearchIndex/segments.gen", "md5": "2eb2668d2bf13379fa3584b9a9867b46" }
],
"status": "OK"
}
]
}
Bundles are deployed to the TDM by a Bus CIS Administrator via the Admin UI.
The bundle serving service uses a master bundle folder which contains an array of bundle folders, each containing one bundle. The contents of the bundle folder must look like the following, and BundleMetadata.json must be JSON-parsable for the bundle serving service to consider the bundle valid.
-
BundleMetadata.json – text file containing metadata of the bundle (see below) in JSON format. The
idvalue inBundleMetadata.jsonmust match the name of the directory it lives in. -
data – data directory containing data files of the bundle. Relative paths in
BundleMetadata.jsonare relative to this directory. - inputs – directory for inputs to the bundle building process.
- outputs – directory for outputs from the bundle building process.
{
"id": "all",
"name": "Test Bundle From Some Pick",
"applicable-agency-ids": ["MTA NYCT"],
"service-date-from": "2011-06-03",
"service-date-to": "2012-04-09",
"created": "2011-11-13T10:10:00-05:00",
"updated": "2011-11-14T10:10:00-05:00",
"files": [
{ "filename": "BaseLocations.txt", "md5": "c1876be140be1e9de079068a1d41fcaf" },
{ "filename": "BlockLayoverIndices.obj", "md5": "bf65d73d8693ab3fc898dd5eeb701851" },
{ "filename": "BlockTripIndices.obj", "md5": "c6d5d375c517b522c3383eec1429ef72" },
{ "filename": "CalendarServiceData.obj", "md5": "907eb39c7fe08efa9139d3946f2c00fd" },
{ "filename": "DSCForTripIndices.obj", "md5": "86da1d78ceceecf2a0681477721d3661" },
{ "filename": "FrequencyBlockTripIndices.obj", "md5": "5a61d172722d8920444274d0249847c7" },
{ "filename": "NarrativeProvider.obj", "md5": "e84613022b293bbb4fa20ae524f71d1f" },
{ "filename": "NotInServiceDSCs.obj", "md5": "ac138569974661654d9114fa10085dcb" },
{ "filename": "NotInServiceDSCs.txt", "md5": "e2fa62c16c0a4160d998dc3ad0756dbe" },
{ "filename": "org_onebusaway_transit_data.log", "md5": "88786eb0aa6170cbc87b269c72cd9a21" },
{ "filename": "org_onebusaway_transit_data.properties", "md5": "914e0b1e70458db2874c4047f256cd95" },
{ "filename": "org_onebusaway_transit_data.script", "md5": "27a2df1991ce186e3508730c1f21919b" },
{ "filename": "ServiceAlerts.xml", "md5": "d41d8cd98f00b204e9800998ecf8427e" },
{ "filename": "ShapeGeospatialIndexData.obj.gz", "md5": "3254e15dc6ae75e2ca730b627cddaca8" },
{ "filename": "TransitGraph.obj", "md5": "136c0e66809b99216c8ce30e054c15a8" },
{ "filename": "TripRunData.obj", "md5": "61908a4ef53a3fedc0b87df1c819885c" },
{ "filename": "TripsForDSCIndices.obj", "md5": "55449f17f5580c87a3e2984f597e5985" },
{ "filename": "RouteSearchIndex/_0.cfs", "md5": "a433ca3d18337c81964a91ef8268e985" },
{ "filename": "RouteSearchIndex/_0.cfx", "md5": "a3a536b54bc4c97770d1861c038ba601" },
{ "filename": "RouteSearchIndex/segments_2", "md5": "8e5d608ee9f93bba75359ac9b17a1f4a" },
{ "filename": "RouteSearchIndex/segments.gen", "md5": "2eb2668d2bf13379fa3584b9a9867b46" },
{ "filename": "StopSearchIndex/_0.cfs", "md5": "52b07d75b51c89fd621be22956643901" },
{ "filename": "StopSearchIndex/_0.cfx", "md5": "67a2d5e0b498631086b5a00dd365fdbe" },
{ "filename": "StopSearchIndex/segments_2", "md5": "e2c5fcc1abf7dc23f8c780938425fb4d" },
{ "filename": "StopSearchIndex/segments.gen", "md5": "2eb2668d2bf13379fa3584b9a9867b46" }
]
}