Sign Up
Loading...

Including query parameters and auth tokens in URLs

Asked by Jai on February 16, 2025

How can I create a single URL where a query parameter is passed along with an auth token, such as api.example.com/check/{query_parameter}/{auth_token}?


Answered by Twidget

Query parameters are passed after a "?" in the URL. For example: api.example.com/check/{auth_token}?query={query_parameter}. Note that it’s more secure to send auth tokens in an Authorization header rather than embedding them in the URL. See the tutorial: https://www.youtube.com/watch?v=iHULlNQ5KQo&ab_channel=Twidget and the auth tutorial: https://www.youtube.com/watch?v=kfbS6gJqRa4

Related Questions