-
-
Notifications
You must be signed in to change notification settings - Fork 45
How to use Trufi Core
The Trufi Core is an Open Source Public Transport Application created and maintained by the Trufi Association e.V.. The Trufi Core uses as a standard MapTiler and OpenStreetMap.
- MapTiler Cloud Key / MapTiler Self Hosted
There are two possible ways to set up your application. The first one is to add an app_config.json file into your assets/cfg folder. Here are a lot of relevant Links and Information included. The other way is the TrufiConfiguration
singleton. It is used in the example to overwrite specific values.
{
"emailFeedback": "feedback@trufi.app",
"emailInfo": "info@trufi.app",
"urlOtpEndpoint": "https://api.trufi.app/otp/routers/default",
"urlAdsEndpoint": "",
"urlRouteFeedback": "https://trufifeedback.z15.web.core.windows.net/route.html",
"urlDonate": "http://www.trufi.app/donate-inapp",
"urlWebsite": "https://www.trufi.app/blog/",
"urlFacebook": "https://www.facebook.com/trufiapp",
"urlTwitter": "https://twitter.com/TrufiAssoc",
"urlInstagram": "https://www.instagram.com/trufi.app",
"urlShare": "https://appurl.io/BOPP7QnKX",
// Replace by your own maptiler server URL
"urlTilesStreetsEndpoint": "https://api.maptiler.com/maps/streets",
"urlTilesSatelliteEndpoint": "https://api.maptiler.com/maps/hybrid",
"urlTilesTerrainEndpoint": "https://api.maptiler.com/maps/topo",
"mapTilerKey": "<Your-Map-Tiler-Key>" // Only needed for MapTiler Cloud
}
Ensure that all of your keys that you want to use are also registered with the TrufiConfiguration Object. For example, if you want to use the MapTiler Cloud, you will need to execute the following in the main.dart.
TrufiConfiguration().map.mapTilerKey = globalCfg.get("mapTilerKey");
Now, if you open your application, you should see the Map from OpenStreetView, and the application should work properly.
-
Getting Started
-
Translations