Usage
Creating a gRPC mock API
To create a gRPC mock API, select the gRPC API template on the mock API creation page and give it a name (and optional custom hostname) of your choosing.
Uploading a descriptor set file
Once your API is created, the first step to take before you can configure your stubs is to upload a gRPC descriptor set file that describes your gRPC services, methods and messages. Navigate to your mock API’s gRPC page and select a file from your file system to upload.
Configuring gRPC stubs.
Once you’ve successfully uploaded your descriptor set file you can create stubs for your gRPC API. The stub form for a gRPC mock API is similar to a general HTTP/HTTPS mock API with a few key differences. Firstly, each gRPC stub must be associated with a particular service and method defined in the uploaded descriptor set file.

booking
method would look something like the following:
OK
status, the response body is not used and a Status Reason
must be provided.
An example response body is generated for your stub after selecting the service and method, to help guide the shape of
your responses.
An example request body is also generated for JSON equality body matchers that you add to your stub.
Testing your stubs
Like with traditional mock APIs, gRPC mock APIs come with a test requester built into the WireMock Cloud app. This test requester can be used to make real gRPC requests to your mock API via a simple interface. To use the test requester, make sure to navigate to the gRPC mock API you wish to test in WireMock Cloud, then open the Test Requester tab on the right side of your browser window. Select the service and method that you want to make a request to, add any headers you want to include and supply a request body, if desired.
Generating a descriptor set file
To generate a descriptor set file from your proto file, simply add the--descriptor_set_out
option to your protoc
command.
For example,