status

Sets the HTTP status code and returns this builder for chaining.

Java-friendly fluent alternative to httpStatus.

Example:

builder.body(myObject).status(201).header("Location", "/items/1");

Return

This builder instance.

Parameters

code

The HTTP status code as an integer, e.g. 201, 404.