Skip to content

Commit

Permalink
Merge pull request #6243 from HSLdevcom/legid-alias-docs
Browse files Browse the repository at this point in the history
Document the need to use graphQL alias for leg id when querying id an…
  • Loading branch information
vesameskanen authored Nov 8, 2024
2 parents 55cce3f + bdf60e0 commit 20b7888
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -670,8 +670,10 @@ type Leg {
"""
headsign: String
"""
An identifier for the leg, which can be used to re-fetch transit leg information.
An identifier for the leg, which can be used to re-fetch transit leg information, except leg's fare products.
Re-fetching fails when the underlying transit data no longer exists.
**Note:** when both id and fare products are queried with [Relay](https://relay.dev/), id should be queried using a suitable GraphQL alias
such as `legId: id`. Relay does not accept different fare product ids in otherwise identical legs.
"""
id: String
"""
Expand Down Expand Up @@ -1173,6 +1175,7 @@ type QueryType {
"""
Try refetching the current state of a transit leg using its id.
This fails when the underlying transit data (mostly IDs) has changed or are no longer available.
Fare products cannot be refetched using this query.
"""
leg(id: String!): Leg
"""
Expand Down

0 comments on commit 20b7888

Please sign in to comment.