Skip to content
| Marketplace
Sign in
Visual Studio Code>Testing>MK API ClientNew to Visual Studio Code? Get it now.
MK API Client

MK API Client

MK Developer Tools

|
2 installs
| (1) | Free
A lightweight, local-first API client for VS Code.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

MK API Client

A lightweight, local-first API client for VS Code. No account, subscription, cloud backend, or telemetry is required. HTTP traffic is sent from the VS Code extension host rather than the webview.

Features

  • Collections, nested folders, environments, request history, whole-collection/folder runs, and request selection
  • GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS, and custom methods
  • Query parameters, repeated headers, JSON, XML, text, forms, GraphQL, multipart fields/files, and binary bodies
  • Basic, Bearer, API Key, OAuth 2.0 Client Credentials, and Authorization Code with PKCE
  • Secret environment variables backed by VS Code SecretStorage
  • Cancellable requests, timeouts, RFC-scoped cookies, bounded downloads, binary responses, and formatted responses
  • Visual assertions for status, duration, headers, JSON, text, and regular expressions
  • CSV/JSON data-driven runs with JSON, HTML, and JUnit reports
  • cURL, Postman v2.1, Thunder Client, OpenAPI 3.x JSON/YAML, and native import/export
  • Headless CLI using the same collection format and runner

Build and install

Requirements: Node.js 20+, npm, and VS Code 1.95+.

npm ci
npm test
npm run package

In VS Code, run Extensions: Install from VSIX..., select the generated VSIX, and run Developer: Reload Window. Open MK API Client from the Activity Bar.

CLI

node dist/cli-v2.js run `
  --file .mk-api/collections.json `
  --collection "My API" `
  --folder "Regression Tests" `
  --environment QA `
  --report report.xml `
  --report-format junit

Additional options include --iterations, --delay, --concurrency, --retry-failures, --rerun-failed-workflows, --stop-on-failure, --timeout, and --enable-scripts. CLI secrets use environment variables named MK_API_SECRET_<variableName>. Exit code 0 means all requests passed, 1 means a request or assertion failed, and 2 means usage or configuration failed.

The published extension does not include or start a mock server. Requests are sent only when you explicitly send one or run a selected collection/folder against an endpoint you configure.

Security principles

MK API Client follows secure-by-default, least-privilege, explicit-trust, data-minimization, and defense-in-depth principles. These controls reduce risk, but an API client can still send data to any URL you choose. Review imported collections and runner selections before executing them.

Keep secrets separate

Secret environment variables are stored with VS Code SecretStorage, separately from .mk-api/collections.json. Reference them from requests instead of entering credentials directly:

Authorization: Bearer {{token}}

Direct Basic passwords, Bearer tokens, API-key values, OAuth client secrets, sensitive headers, and credential-like variables such as api_token, password, and private_key are blocked from saved requests and collection/folder defaults by default. This protection can be disabled with mkApi.security.allowPlaintextCredentials, but doing so may place credentials in workspace JSON and backup files.

The CLI reads secrets from environment variables named MK_API_SECRET_<variableName>. Avoid passing secrets as command-line arguments because operating-system process listings and shell history may expose them.

Validate trust boundaries

The webview is an editor, not a network client. It uses a restrictive Content Security Policy, sends structured messages to the extension host, and displays response content as text rather than executable HTML. The extension host rebuilds incoming requests through bounded runtime schemas. Native imports receive nested schema validation; other import formats are converted into the internal model and report unsupported features.

Protect network communication

Requests run in the desktop VS Code extension host. TLS certificate verification cannot be disabled. Custom CA files, authenticated HTTP(S) proxies, PEM client certificates, and PFX/P12 client identities are supported without weakening verification. OAuth Authorization Code uses PKCE S256 and validates the callback state. Cookies reject unrelated domains and follow domain, path, Secure, and expiry matching rules.

Bound resource use

Requests have configurable timeouts and cancellation. Responses are read as a bounded stream; downloads larger than mkApi.response.maxDownloadBytes are cancelled before the complete response is retained in memory. The response editor separately limits rendered output with mkApi.response.maxDisplayBytes. Script processes have hard execution timeouts.

Minimize persisted data

Workspace mode writes versioned data to .mk-api/collections.json; user mode uses VS Code global storage. Writes are atomic, keep a .bak recovery copy, and reject overwriting files changed externally. History and exports remove request bodies, authentication data, sensitive headers, scripts, and local upload paths. Telemetry is not implemented or transmitted.

Treat scripts as code

Scripts are disabled by default, require a trusted VS Code workspace, and must be explicitly enabled. They run in a separate constrained process with an empty environment and no exposed filesystem, module-loading, network, timer, or process APIs. Imported scripts never run automatically. This sandbox is defense in depth, not a reason to execute unreviewed code; see docs/SCRIPT_API.md.

Remote SSH, WSL, and Dev Containers send requests and access files from the extension-host machine. Browser-based VS Code is unsupported.

See docs/ARCHITECTURE.md, docs/FEATURE_MATRIX.md, docs/SCRIPT_API.md, and docs/KNOWN_LIMITATIONS.md for implementation details, operational boundaries, and unsupported features.

Third-party names and trademarks

Postman and Thunder Client are trademarks of their respective owners. MK API Client is an independent project and is not affiliated with, endorsed by, certified by, or sponsored by Postman or Thunder Client.

Those product names are used only where necessary to describe local file-format compatibility, including importing or exporting collections and environments. MK API Client does not use their logos or visual identity, does not depend on their cloud services, and does not claim complete feature parity. Compatibility may change when third-party formats change.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft