BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Microsoft Releases Dev Proxy v0.21: New Features Enhance API Testing and Development Efficiency

Microsoft Releases Dev Proxy v0.21: New Features Enhance API Testing and Development Efficiency

This item in japanese

Microsoft has announced the release of Dev Proxy v0.21, introducing several notable features. Among the key additions are the ability to simulate authentication and authorization using API keys and OAuth2, the capability to quickly generate JWT tokens for testing, a new version of the toolkit, and other improvements.

For readers unfamiliar with Dev Proxy, formerly known as Microsoft 365 Developer Proxy, it is a command-line tool designed to simulate real-world API behaviors for testing applications. Dev Proxy enables developers to build resilient applications that handle errors and rate limits effectively.

A significant addition to this version is the AuthPlugin, which allows developers to add authentication and authorization to any URL easily. It has been reported that when building an API on Azure Functions, developers can now verify API access key security locally. By configuring Dev Proxy accordingly, access key security with specified keys can be applied to an Azure Function running on a local machine.

As stated, the AuthPlugin configuration can also be adapted to use OAuth2-based security with Microsoft Entra ID or any other OAuth2 identity provider. This flexibility allows developers to simulate various authentication scenarios during the development phase. More details are available in the plugin's documentation.

To further assist those working with APIs secured by OAuth2, the update introduces a command for generating JWT tokens. Typically, obtaining a JWT token outside an application can be complex, requiring an understanding of OAuth flows and interaction with identity provider APIs. The new jwt create command simplifies this process by generating a JWT token with default values programmed into Dev Proxy, making it suitable for testing purposes.

(Creating new JWT with jwt create command, Source: Microsoft Offical Blog)

In parallel with the Dev Proxy update, version 0.10.0 of the Dev Proxy Toolkit for Visual Studio Code has also been released. This extension facilitates the creation and updating of configuration files. The latest version allows developers to start and control Dev Proxy directly from Visual Studio Code, through global commands or editor actions that appear when a Dev Proxy configuration file is open.

The toolkit now includes commands and editor actions for starting and stopping Dev Proxy, initiating and ending recording sessions, and raising mock requests. These enhancements streamline the workflow, making it more convenient to interact with Dev Proxy during development.

(Interaction with Dev Proxy using global commands, Source: Microsoft Offical Blog)

The development team has also outlined upcoming features stating the following:

We keep evolving Dev Proxy to make it an even more helpful tool, that keeps you in the flow and helps you build more robust apps connected to APIs. Here’s what you can expect in the next version.

As reported a new plugin is in development, allowing developers to check minimal permissions for any API using local API specifications. Starting from the next version, each logged message will include the plugin's name, and a new message type, skip, will indicate plugins that did not affect the request and the reasons why. With a note, that users will have the option to disable skip-messages through configuration settings.

Additionally, pre-release versions of the Dev Proxy Toolkit will be made available to complement the latest Dev Proxy beta releases. This initiative will enable developers to test new features before their official release and provide feedback to aid development.

Lastly, developers are encouraged to refer to the official release notes for a comprehensive list of changes in this version.

About the Author

Rate this Article

Adoption
Style

BT