We are actively seeking accomplished programmers to join our growing team and actively participate in design, architecture, implementation and deployment of web based applications.
The purpose of this project is to test a candidate's programming aptitude, style and knowledge of best practices.
The following challenge should be built using one of the languages of your choice:
- PHP
- Python
- C#/.NET
Design and develop a Project, which uses a CLI command to parse a GTFS Real-time TripUpdates feed in JSON format to an Object, then store the TripUpdate
entity with it's unique identifier, and also each StopTimeUpdate
within it's own entity which is related to the TripUpdate parent within the database of your choice.
Use the GTFS-RT feed provided in the instructions below.
Provide instructions for us on how to setup the project and run the command within the README.
An example of running the command using PHP/Symfony would be as follows: php bin/console data:parse-feed
Extra Credit example:
Existing records within the database should be skipped, and new ones should be appended.
DO NOT Fork This Repository
Make use of GitHub for development: commits, PRs, issues
Create a private or public GitHub, GitLab or BitBucket repository for this coding challenge.
Utilize a database or service to store information using some form of ORM with the language of your choice.
Provide documentation for deployment, if we cannot get the project up and running based on the README, we will not acknowledge the challenge.
- Use the Swiftly API provided in this repository to parse and store TripUpdates and the related StopTimeUpdates within a database.
- Create an Entity for each TripUpdate with relational properties to a StopTimeUpdate entity. Each TripUpdate record in the database should have a OneToMany relationship with the corresponding StopTimeUpdates.
- Create a console command that parses the TripUpdates feed, iterates through each TripUpdate, and stores the data for each
TripUpdate
andStopTimeUpdate
as a new row in the database, where the StopTimeUpdates are related to the parent TripUpdate. - When storing the TripUpdates, make sure to also store the ID of each entity.
- Extra Credit: Existing records within the database should be skipped, and new ones should be appended.
- Make an API endpoint in the same application that returns up to 100 results from the database.
- Must be able to query the endpoint with the following URL or something similar:
GET /real-time/trip-updates
and return the stored TripUpdates in JSON similar to the Swiftly API response. - Use the following API endpoint and API Key to retrieve the Trip Updates Feed:
- Endpoint:
https://api.goswift.ly/real-time/vta/gtfs-rt-trip-updates
- API Key:
59af72683221a1734f637eae7a7e8d9b
- format: json
- Full Endpoint: https://api.goswift.ly/real-time/vta/gtfs-rt-trip-updates?apiKey=59af72683221a1734f637eae7a7e8d9b&format=json
- Documentation: https://swiftly-inc.stoplight.io/docs/realtime-standalone/613d1d7f1eae3-gtfs-rt-trip-updates
- Endpoint:
- Must be able to run this project on a local machine
- Commit often and frequently, use branches, issues, and pull requests where needed.
- DO NOT USE code from stackoverflow, CHATGPT, or other websites, this code must be your own.
- Add arguments to the command for the API endpoint with arguments for the API key and GET parameters. (ex: format=json), which is then used to pull the TripUpdates feed.
- Create Unit/Functional tests for the command and supporting methods.
- Remove expired TripUpdates every time the command is executed.
- Deploy to the cloud using the serverless.com (serverless) framework.
- https://developers.google.com/transit/gtfs-realtime/reference
- https://swiftly-inc.stoplight.io/docs/standalone/99a5881ffdb83-gtfs-rt-trip-updates
- https://symfony.com/doc/current/console/style.html
- https://developers.google.com/protocol-buffers/docs/reference/php-generated
- https://developers.google.com/protocol-buffers/docs/downloads