Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search parameter "only" no longer working #172

Open
pitkant opened this issue Nov 22, 2022 · 0 comments
Open

Search parameter "only" no longer working #172

pitkant opened this issue Nov 22, 2022 · 0 comments

Comments

@pitkant
Copy link

pitkant commented Nov 22, 2022

I can't seem to restrict the fields returned by API search query. For example the following query returns also other fields than just name and street_address:

https://api.hel.fi/servicemap/v2/search/?q=leikkipuisto&only=unit.name,unit.street_address

Additionally, the documentation for the API seems to be partially incomplete. (Yes, I know this site is no longer in use but there seems to be no alternative either.) The description for only parameter ends abruptly

"Restrict the field returned in the results. Separate field names by commas. In the search endpoint, you must qualify the field names with the resource names using the format"

Maybe this should include similar instructions as the include parameter above?

For example, instead of include=department you must specify include=unit.department.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant