Docsright arrowBlackbirdright arrowCode run and debug

2 min • read

Code run and debug

Running and debugging your API specification or mock instance allows you to test the behavior of your API, analyze request and response data, and troubleshoot issues throughout the development process.

Note: You must install Docker to use code run and code debug commands with Blackbird. For more information, see Get Docker.

Building and running a local container with a remote server

To start debugging an API or mock, pass the instance name as well as the path to the dockerfile and context.

Building and debugging a local container with a remote server

Use the following command, which is similar to the run command, but it attaches a debugger to the container:

Securing a code instance

By default, the remote code instance server endpoints are available publicly. To secure these endpoints, you can use API keys. You can also create and set an API key on creation with the --apikey-header flag. The following templates show the valid ways to enable an API key for code instance servers.