Set Query String Parameter

Template ID: setqueryparameter

Adds or updates value of request query string parameter. This template is available in Power Apps and Power Automate.

The target use case for this scenario is to override or add information to a query string parameter.


Let’s look at some examples that use the following parameters.

headers: test=foo, name=123

connectionParameters: cat=bar

queryParameters: domain=pqr

Query string template nameQuery string template valueResulting query parameter
domain@connectionParameters('dog', 'default')domain=default

Examples from open-sourced connectors

We have multiple instances of this template being used in our open-sourced connectors repository.

Cloudmersive PDFQuery string parameter is overridden by a new static value
OutlookTasksQuery string parameter is added if the query parameter does not exist
PlannerQuery string parameter for the select filter is overridden by 2 specific values separated by a comma

Input Parameters

Name Key Required Type Description
Query parameter name True String Specifies the name of the query parameter to be set.
Query parameter value x-ms-apimTemplateParameter.value True String Specifies the value of the query parameter to be set. This parameter supports expressions. Click here to learn more about expressions.
Action if query parameter exists x-ms-apimTemplateParameter.existsAction Enum Specifies what action to take when the query parameter is already specified.
- override: Replaces existing value with the value from policy template.
- skip: Existing value isn't replaced with the value from policy template.
- append: Appends the value from policy template to existing value.
Operations x-ms-apimTemplate-operationName Array Policy will run on the selected list of actions and triggers.If no operation is selected, this policy will apply to all operations.