For OcTranspo map, GTFS Shapes To Features
Steps:
Download the GTFS zip file, extract;
http://www.octranspo.com/developersLogin to ArcPro, active the portal which you want to use in ArcPro;
Add folder into ArcPro;
Open the iPython, run the Convert.py.
Run Convert
the file content:import arcpy # arcpy.conversion.GTFSShapesToFeatures(r"D:/GTFS/shapes.txt", r"D:/Data/output.gdb/shapes") # arcpy.conversion.GTFSShapesToFeatures(r"C:\Develop\OcTranspo\google_transit\shapes.txt", r"C:\Develop\OcTranspo\google_transit\Output") # arcpy.conversion.GTFSShapesToFeatures(r"C:\Develop\OcTranspo\google_transit\trips.txt", r"C:\Develop\OcTranspo\google_transit\Output") arcpy.conversion.GTFSStopsToFeatures(r"C:\Develop\OcTranspo\google_transit/stops.txt", r"C:\Develop\OcTranspo\google_transit\Output\stops")
In Catalog of ArcPro, add the folder: (C:\Develop\OcTranspo\google_transit\Output)
Add the stops.shp on map;
Then run the sharing as web layer:
Click Analyze button, if you get the following 2 warning, do nothing;
Click Publish button;
In Dev Portal, you will get this:
in Dev Portal, if you click the Open in Map viewer:
zoom in the map, and click a bus station:
click the direction in the pop up window
then select another bus stop, you will get this service:
Other features which provided by Octranspo:
http://www.octranspo.com/developers/documentation
Description of Methods
- GetRouteSummaryForStop: Retrieves the routes for a given stop number.
- GetNextTripsForStop: Retrieves next three trips on the route for a given stop number.
- GetNextTripsForStopAllRoutes: Retrieves next three trips for all routes for a given stop number.
- GTFS: Retrieves specific records from all sections the of GTFS file.
Warning message for Analyze in ArcPro:
24011: Data source is not registered with the server and data will be copied to the server
Solution
**Do nothing**. The source data will be copied to the federated server. This includes all related or joined data.
If you do not wish to copy your data to the server you will need to register the original data source with the federated server.
The provided solution will open the Registration dialog. Enter a name for the data store and click OK.
24041: Layer does not have a feature template set
Solution