Skip to content

Instantly share code, notes, and snippets.

@waldekmastykarz
Last active September 25, 2024 14:50
Show Gist options
  • Save waldekmastykarz/b62843dc96543908f89f1f437b9ccd48 to your computer and use it in GitHub Desktop.
Save waldekmastykarz/b62843dc96543908f89f1f437b9ccd48 to your computer and use it in GitHub Desktop.
Dev Proxy configuration to simulate access key authentication for Azure Functions
{
"$schema": "https://raw.githubusercontent.com/microsoft/dev-proxy/main/schemas/v0.21.0/rc.schema.json",
"plugins": [
{
"name": "AuthPlugin",
"enabled": true,
"pluginPath": "~appFolder/plugins/dev-proxy-plugins.dll",
"configSection": "apiKey"
}
],
"urlsToWatch": [
"http://localhost:7071/*"
],
"apiKey": {
"type": "apiKey",
"apiKey": {
"parameters": [
{
"name": "x-api-key",
"in": "header"
},
{
"name": "code",
"in": "query"
}
],
"allowedKeys": [
"1234"
]
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment