fix(api): use request objects in all api clients#97
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the Navitia API client to consistently use request objects across all API methods and updates documentation from NumPy style to Google style docstrings.
Key changes:
- Standardize API methods to use request objects instead of individual parameters
- Update all docstrings from NumPy style to Google style
- Remove default values from request parameters in several methods (breaking change)
Reviewed Changes
Copilot reviewed 18 out of 18 changed files in this pull request and generated 14 comments.
Show a summary per file
| File | Description |
|---|---|
traffic_report_apis.py |
Moved request parameter to first position, removed default value; updated docstrings to Google style |
terminus_schedules_apis.py |
Updated docstrings to Google style; no API signature changes |
stop_schedules_apis.py |
Updated docstrings to Google style; no API signature changes |
route_schedules_apis.py |
Updated docstrings to Google style; no API signature changes |
public_transport_objects_apis.py |
Updated docstrings to Google style; no API signature changes |
places_nearby_apis.py |
Major refactor: replaced individual parameters with PlacesNearbyRequest object; updated docstrings |
place_apis.py |
Updated docstrings to Google style; no API signature changes |
line_report_apis.py |
Moved request parameter to first position, removed default value; updated docstrings |
journeys_apis.py |
Major refactor: replaced 30+ individual parameters with JourneyRequest object; updated docstrings |
isochrone_apis.py |
Updated docstrings to Google style; no API signature changes |
inverted_geocoding_apis.py |
Updated docstrings to Google style; no API signature changes |
freefloatings_nearby_apis.py |
Removed default values from request parameters; updated docstrings |
equipment_report_apis.py |
Removed default values from request parameters; updated docstrings |
departure_apis.py |
Updated docstrings to Google style; no API signature changes |
datasets_apis.py |
Updated docstrings to Google style; no API signature changes |
coverage_apis.py |
Updated docstrings to Google style; no API signature changes |
contributors_apis.py |
Updated docstrings to Google style; no API signature changes |
arrival_apis.py |
Updated docstrings to Google style; no API signature changes |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Changelog * Fix APIs missing usage of request objects * Update documentation * Fix tests
7dfec40 to
5b4a77f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog