From d80792320cc3316d3af2f15c5ddc4bd0749228f2 Mon Sep 17 00:00:00 2001 From: Garry Trinder Date: Wed, 13 May 2026 14:42:09 +0100 Subject: [PATCH 1/2] Add auth key support for CRUD API to skill. Closes #1663 Increment skill version Update examples to use v3.0.0 schema --- skills/dev-proxy/SKILL.md | 6 +- .../dev-proxy/references/analyze-api-usage.md | 10 ++-- .../dev-proxy/references/ci-cd-integration.md | 6 +- skills/dev-proxy/references/configuration.md | 4 +- skills/dev-proxy/references/installation.md | 2 +- .../references/mock-api-responses.md | 57 +++++++++++++++---- .../references/test-api-resilience.md | 26 ++++----- skills/dev-proxy/references/test-llm-apps.md | 18 +++--- 8 files changed, 82 insertions(+), 47 deletions(-) diff --git a/skills/dev-proxy/SKILL.md b/skills/dev-proxy/SKILL.md index c79c0870..c11fb696 100644 --- a/skills/dev-proxy/SKILL.md +++ b/skills/dev-proxy/SKILL.md @@ -1,7 +1,7 @@ --- name: dev-proxy metadata: - version: 1.0.0 + version: 1.1.0 description: "Simulate API failures, mock responses, test rate limiting, and analyze API traffic using Dev Proxy's plugin-based proxy engine. WHEN: 'mock API responses', 'simulate API errors', 'test rate limiting', 'test error handling', 'mock OpenAI responses', 'test AI app', 'analyze API usage', 'configure Dev Proxy', 'install Dev Proxy', 'set up Dev Proxy', 'use Dev Proxy in CI/CD', 'chaos testing for APIs', 'run Dev Proxy in background', 'detached mode', 'run Dev Proxy detached'." --- @@ -79,7 +79,7 @@ A quick reference. All configuration details are in [references/configuration.md ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "PluginName", @@ -90,7 +90,7 @@ A quick reference. All configuration details are in [references/configuration.md ], "urlsToWatch": ["https://api.contoso.com/*"], "pluginConfig": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/pluginname.schema.json" + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/pluginname.schema.json" } } ``` diff --git a/skills/dev-proxy/references/analyze-api-usage.md b/skills/dev-proxy/references/analyze-api-usage.md index ac3e5822..ab7eb5b4 100644 --- a/skills/dev-proxy/references/analyze-api-usage.md +++ b/skills/dev-proxy/references/analyze-api-usage.md @@ -40,7 +40,7 @@ Use `OpenApiSpecGeneratorPlugin` to reverse-engineer OpenAPI specs from intercep ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "OpenApiSpecGeneratorPlugin", @@ -56,7 +56,7 @@ Use `OpenApiSpecGeneratorPlugin` to reverse-engineer OpenAPI specs from intercep ], "urlsToWatch": ["https://api.contoso.com/*"], "openApiSpecGeneratorPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/openapispecgeneratorplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/openapispecgeneratorplugin.schema.json", "specVersion": "v3_0", "specFormat": "Json", "includeOptionsRequests": false, @@ -349,7 +349,7 @@ Reporter plugins format report output. Always place them AFTER reporting plugins ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "ExecutionSummaryPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "executionSummaryPlugin" }, { "name": "GraphMinimalPermissionsPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "graphMinimalPermissionsPlugin" }, @@ -369,7 +369,7 @@ Reporter plugins format report output. Always place them AFTER reporting plugins ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "ApiCenterOnboardingPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "apiCenterOnboardingPlugin" }, { "name": "ApiCenterProductionVersionPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "apiCenterProductionVersionPlugin" }, @@ -385,7 +385,7 @@ Reporter plugins format report output. Always place them AFTER reporting plugins ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "UrlDiscoveryPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll" }, { "name": "OpenApiSpecGeneratorPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "openApiSpecGeneratorPlugin" }, diff --git a/skills/dev-proxy/references/ci-cd-integration.md b/skills/dev-proxy/references/ci-cd-integration.md index b71e81b1..b9980c69 100644 --- a/skills/dev-proxy/references/ci-cd-integration.md +++ b/skills/dev-proxy/references/ci-cd-integration.md @@ -182,7 +182,7 @@ No dedicated actions — use script tasks with the Dev Proxy API. ```yaml variables: - name: DEV_PROXY_VERSION - value: v2.4.0 + value: v3.0.0 steps: - task: Cache@2 @@ -233,7 +233,7 @@ pool: variables: - name: DEV_PROXY_VERSION - value: v2.4.0 + value: v3.0.0 - name: LOG_FILE value: devproxy.log @@ -300,7 +300,7 @@ For any CI system, follow these steps: ### 1. Install with Pinned Version ```bash -bash -c "$(curl -sL https://aka.ms/devproxy/setup.sh)" -- v2.4.0 +bash -c "$(curl -sL https://aka.ms/devproxy/setup.sh)" -- v3.0.0 ``` ### 2. Start in Background with Logging diff --git a/skills/dev-proxy/references/configuration.md b/skills/dev-proxy/references/configuration.md index 2297aa81..cabdb083 100644 --- a/skills/dev-proxy/references/configuration.md +++ b/skills/dev-proxy/references/configuration.md @@ -10,7 +10,7 @@ A configuration file follows a specific property order: `$schema`, then `plugins ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "RetryAfterPlugin", @@ -28,7 +28,7 @@ A configuration file follows a specific property order: `$schema`, then `plugins "https://jsonplaceholder.typicode.com/*" ], "genericRandomErrorPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/genericrandomerrorplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/genericrandomerrorplugin.schema.json", "errorsFile": "devproxy-errors.json", "rate": 50 }, diff --git a/skills/dev-proxy/references/installation.md b/skills/dev-proxy/references/installation.md index 7b9f4a9e..625177b5 100644 --- a/skills/dev-proxy/references/installation.md +++ b/skills/dev-proxy/references/installation.md @@ -63,7 +63,7 @@ Or with PowerShell: Pass the version to the setup script: ```bash -bash -c "$(curl -sL https://aka.ms/devproxy/setup.sh)" -- v2.4.0 +bash -c "$(curl -sL https://aka.ms/devproxy/setup.sh)" -- v3.0.0 ``` With winget: diff --git a/skills/dev-proxy/references/mock-api-responses.md b/skills/dev-proxy/references/mock-api-responses.md index ddb19dcf..550576a0 100644 --- a/skills/dev-proxy/references/mock-api-responses.md +++ b/skills/dev-proxy/references/mock-api-responses.md @@ -20,7 +20,7 @@ The most common mocking plugin. Returns predefined responses matched by URL, HTT ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "MockResponsePlugin", @@ -31,7 +31,7 @@ The most common mocking plugin. Returns predefined responses matched by URL, HTT ], "urlsToWatch": ["https://api.contoso.com/*"], "mocksPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/mockresponseplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/mockresponseplugin.schema.json", "mocksFile": "mocks.json", "blockUnmockedRequests": false } @@ -46,7 +46,7 @@ CLI overrides: `--no-mocks` to disable, `--mocks-file ` to change mock fil ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/mockresponseplugin.mocksfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/mockresponseplugin.mocksfile.schema.json", "mocks": [ { "request": { @@ -174,7 +174,7 @@ Creates a fully functional CRUD API backed by an in-memory JSON data store. Supp ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "CrudApiPlugin", @@ -184,7 +184,7 @@ Creates a fully functional CRUD API backed by an in-memory JSON data store. Supp } ], "customersApi": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/crudapiplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/crudapiplugin.schema.json", "apiFile": "customers-api.json" } } @@ -194,7 +194,7 @@ Creates a fully functional CRUD API backed by an in-memory JSON data store. Supp ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/crudapiplugin.apifile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/crudapiplugin.apifile.schema.json", "baseUrl": "https://api.contoso.com/v1/customers", "dataFile": "customers-data.json", "actions": [ @@ -226,9 +226,44 @@ Creates a fully functional CRUD API backed by an in-memory JSON data store. Supp - The data file must be a JSON array (can be empty: `[]`). - Data persists in memory during the Dev Proxy session. -### Entra Auth for CRUD APIs +### Auth for CRUD APIs -Set `"auth": "entra"` in the API file: +CRUD APIs support two built-in authentication modes: API Key and Entra. Set the `auth` property in the API definition file to `"apiKey"` or `"entra"`. + +#### API Key Auth + +Set `"auth": "apiKey"` and provide `apiKeyAuthConfig`: + +```json +{ + "baseUrl": "https://api.contoso.com/v1/customers", + "dataFile": "customers-data.json", + "auth": "apiKey", + "apiKeyAuthConfig": { + "apiKey": "my-secret-key", + "headerName": "X-API-Key", + "queryParameterName": "code" + }, + "actions": [ + { "action": "getAll" }, + { "action": "create" } + ] +} +``` + +Dev Proxy checks the header first, then the query parameter. If either matches, the request is authorized. + +| Property | Required | Default | Description | +|----------|----------|---------|-------------| +| `apiKey` | Yes | — | The valid API key that must be present in the request | +| `headerName` | No | — | HTTP header name to read the API key from | +| `queryParameterName` | No | — | Query parameter name to read the API key from | + +At least one of `headerName` or `queryParameterName` should be specified. Per-action API Key auth is supported by setting `"auth": "apiKey"` on individual actions — the root `apiKeyAuthConfig` is used. + +#### Entra Auth + +Set `"auth": "entra"` and provide `entraAuthConfig`: ```json { @@ -266,7 +301,7 @@ Mocks STDIO communication for MCP servers and STDIO-based apps. Use with `devpro ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "MockStdioResponsePlugin", @@ -276,7 +311,7 @@ Mocks STDIO communication for MCP servers and STDIO-based apps. Use with `devpro } ], "mockStdioResponsePlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/mockstdioresponseplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/mockstdioresponseplugin.schema.json", "mocksFile": "stdio-mocks.json", "blockUnmockedRequests": false } @@ -287,7 +322,7 @@ Mocks STDIO communication for MCP servers and STDIO-based apps. Use with `devpro ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/mockstdioresponseplugin.mocksfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/mockstdioresponseplugin.mocksfile.schema.json", "mocks": [ { "request": { "bodyFragment": "initialize" }, diff --git a/skills/dev-proxy/references/test-api-resilience.md b/skills/dev-proxy/references/test-api-resilience.md index 48c9794e..a685b7fc 100644 --- a/skills/dev-proxy/references/test-api-resilience.md +++ b/skills/dev-proxy/references/test-api-resilience.md @@ -10,7 +10,7 @@ Randomly fails requests with errors from a configured file. Works with any API. ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "GenericRandomErrorPlugin", @@ -21,7 +21,7 @@ Randomly fails requests with errors from a configured file. Works with any API. ], "urlsToWatch": ["https://api.contoso.com/*"], "genericRandomErrorPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/genericrandomerrorplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/genericrandomerrorplugin.schema.json", "errorsFile": "errors.json", "rate": 50, "retryAfterInSeconds": 5 @@ -41,7 +41,7 @@ CLI: `devproxy --failure-rate 80` overrides `rate`. ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/genericrandomerrorplugin.errorsfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/genericrandomerrorplugin.errorsfile.schema.json", "errors": [ { "statusCode": 429, @@ -70,7 +70,7 @@ When `addDynamicRetryAfter: true`, Dev Proxy auto-calculates the Retry-After val ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/genericrandomerrorplugin.errorsfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/genericrandomerrorplugin.errorsfile.schema.json", "errors": [ { "statusCode": 400, "body": { "error": { "code": "BadRequest", "message": "The request was malformed or contains invalid parameters." } } }, { "statusCode": 401, "body": { "error": { "code": "Unauthorized", "message": "Authentication required." } } }, @@ -89,7 +89,7 @@ When `addDynamicRetryAfter: true`, Dev Proxy auto-calculates the Retry-After val ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/genericrandomerrorplugin.errorsfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/genericrandomerrorplugin.errorsfile.schema.json", "errors": [ { "statusCode": 429, "headers": [{ "name": "Retry-After", "value": "@dynamic" }, { "name": "Content-Type", "value": "application/json" }], "body": { "error": { "message": "Rate limit reached for default-gpt-4 in organization org-xxx on tokens per min.", "type": "tokens", "param": null, "code": "rate_limit_exceeded" } }, "addDynamicRetryAfter": true }, { "statusCode": 429, "body": { "error": { "message": "The engine is currently overloaded, please try again later.", "type": "server_error", "param": null, "code": null } } }, @@ -105,7 +105,7 @@ Fails Microsoft Graph requests with Graph-specific error responses. Supports bat ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "GraphRandomErrorPlugin", @@ -119,7 +119,7 @@ Fails Microsoft Graph requests with Graph-specific error responses. Supports bat "https://graph.microsoft.com/beta/*" ], "graphRandomErrorPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/graphrandomerrorplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/graphrandomerrorplugin.schema.json", "allowedErrors": [429, 500, 502, 503, 504, 507], "rate": 50 } @@ -163,7 +163,7 @@ Simulates rate-limit behavior with configurable headers, thresholds, and respons ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "RateLimitingPlugin", @@ -173,7 +173,7 @@ Simulates rate-limit behavior with configurable headers, thresholds, and respons } ], "rateLimiting": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/ratelimitingplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/ratelimitingplugin.schema.json", "costPerRequest": 2, "rateLimit": 120, "resetTimeWindowSeconds": 60, @@ -271,7 +271,7 @@ Adds random delay to responses. Works with both HTTP and STDIO. ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LatencyPlugin", @@ -281,7 +281,7 @@ Adds random delay to responses. Works with both HTTP and STDIO. } ], "latencyPlugin": { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/latencyplugin.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/latencyplugin.schema.json", "minMs": 200, "maxMs": 10000 } @@ -311,7 +311,7 @@ devproxy config get openai-throttling ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LatencyPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "latencyPlugin" }, { "name": "RateLimitingPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "rateLimiting" }, @@ -328,7 +328,7 @@ devproxy config get openai-throttling ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "RetryAfterPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll" }, { "name": "GraphRandomErrorPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "graphRandomErrorPlugin" }, diff --git a/skills/dev-proxy/references/test-llm-apps.md b/skills/dev-proxy/references/test-llm-apps.md index 9bd1356b..65d3f3fb 100644 --- a/skills/dev-proxy/references/test-llm-apps.md +++ b/skills/dev-proxy/references/test-llm-apps.md @@ -19,7 +19,7 @@ Use `OpenAIMockResponsePlugin` to simulate OpenAI/Azure OpenAI completions and c ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "OpenAIMockResponsePlugin", @@ -64,7 +64,7 @@ Use `LanguageModelFailurePlugin` to test how an app handles common LLM failure m ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LanguageModelFailurePlugin", @@ -123,7 +123,7 @@ Use `LanguageModelRateLimitingPlugin` to test token quota handling. ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LanguageModelRateLimitingPlugin", @@ -158,7 +158,7 @@ Use `LanguageModelRateLimitingPlugin` to test token quota handling. ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/languagemodelratelimitingplugin.customresponsefile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/languagemodelratelimitingplugin.customresponsefile.schema.json", "statusCode": 429, "headers": [ { "name": "retry-after", "value": "@dynamic" }, @@ -188,7 +188,7 @@ Use `OpenAITelemetryPlugin` to send usage telemetry to OpenTelemetry-compatible ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "OpenAITelemetryPlugin", @@ -228,7 +228,7 @@ Use `OpenAITelemetryPlugin` to send usage telemetry to OpenTelemetry-compatible ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/openaitelemetryplugin.pricesfile.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/openaitelemetryplugin.pricesfile.schema.json", "prices": { "gpt-4": { "input": 0.03, "output": 0.06 }, "gpt-4-turbo": { "input": 0.01, "output": 0.03 }, @@ -291,7 +291,7 @@ See the mocking reference (`references/mock-api-responses.md`) for STDIO mock fi ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LanguageModelFailurePlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "languageModelFailurePlugin" }, { "name": "LanguageModelRateLimitingPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "languageModelRateLimitingPlugin" }, @@ -312,7 +312,7 @@ This config: randomly injects LLM failures (50% of requests), enforces token lim ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "OpenAIMockResponsePlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll" }, { "name": "OpenAIUsageDebuggingPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll" } @@ -326,7 +326,7 @@ This config: randomly injects LLM failures (50% of requests), enforces token lim ```json { - "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v2.4.0/rc.schema.json", + "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v3.0.0/rc.schema.json", "plugins": [ { "name": "LatencyPlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "latencyPlugin" }, { "name": "MockStdioResponsePlugin", "enabled": true, "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll", "configSection": "mockStdioResponsePlugin" } From f4226738030bada9d838fbeba14e40a4a130bf43 Mon Sep 17 00:00:00 2001 From: Garry Trinder Date: Wed, 13 May 2026 14:54:28 +0100 Subject: [PATCH 2/2] Address PR review comments - Update winget version pin to 3.0.0 - Update GitHub Actions version pins to 3.0.0 - Tighten API Key auth wording: headerName/queryParameterName must be specified - Clarify API Key auth applies to all actions (no per-action support) --- skills/dev-proxy/references/ci-cd-integration.md | 4 ++-- skills/dev-proxy/references/installation.md | 2 +- skills/dev-proxy/references/mock-api-responses.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/skills/dev-proxy/references/ci-cd-integration.md b/skills/dev-proxy/references/ci-cd-integration.md index b9980c69..11661247 100644 --- a/skills/dev-proxy/references/ci-cd-integration.md +++ b/skills/dev-proxy/references/ci-cd-integration.md @@ -63,7 +63,7 @@ Access via `${{ steps..outputs.proxy-url }}`. ```yaml - uses: dev-proxy-tools/actions/setup@v1 with: - version: 2.4.0 + version: 3.0.0 ``` ### Multiple Recording Sessions @@ -103,7 +103,7 @@ jobs: - uses: dev-proxy-tools/actions/setup@v1 with: - version: 2.4.0 + version: 3.0.0 - id: start-proxy uses: dev-proxy-tools/actions/start@v1 diff --git a/skills/dev-proxy/references/installation.md b/skills/dev-proxy/references/installation.md index 625177b5..e654a69a 100644 --- a/skills/dev-proxy/references/installation.md +++ b/skills/dev-proxy/references/installation.md @@ -69,7 +69,7 @@ bash -c "$(curl -sL https://aka.ms/devproxy/setup.sh)" -- v3.0.0 With winget: ```console -winget install DevProxy.DevProxy --version 2.4.0 --silent +winget install DevProxy.DevProxy --version 3.0.0 --silent ``` ## First Run Setup diff --git a/skills/dev-proxy/references/mock-api-responses.md b/skills/dev-proxy/references/mock-api-responses.md index 550576a0..db41f3ba 100644 --- a/skills/dev-proxy/references/mock-api-responses.md +++ b/skills/dev-proxy/references/mock-api-responses.md @@ -259,7 +259,7 @@ Dev Proxy checks the header first, then the query parameter. If either matches, | `headerName` | No | — | HTTP header name to read the API key from | | `queryParameterName` | No | — | Query parameter name to read the API key from | -At least one of `headerName` or `queryParameterName` should be specified. Per-action API Key auth is supported by setting `"auth": "apiKey"` on individual actions — the root `apiKeyAuthConfig` is used. +At least one of `headerName` or `queryParameterName` must be specified — omitting both means no request can be authorized. API Key auth applies to all actions and cannot be configured per-action. #### Entra Auth