-
Notifications
You must be signed in to change notification settings - Fork 32
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
Autocomplete site locations #38
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Site entity association will be available, for the moment, just for municipalities.
To get the list of municipalities we are going to use The Big Indexer municipalities collection.
The endpoint to obtain the suggestions is to a given query is
https://tbi.populate.tools/gobierto/collections/c-municipios-espanya/suggestions
.It requires a parameter
query
and an authorization header:query
: contains the query argument to the suggestions.authorization: Bearer <TOKEN_BODY>
(I'll provide the token body in private). Maybe it'll make sense to set that token as an installation setting, because I suspect we are going to use The Big Indexer in some places in the future.
In javascript you can do this:
The output of the endpoint is an object with a key
suggestions
and all the suggestions, composed of a value, and a raw data object:The text was updated successfully, but these errors were encountered: