Package org.springframework.vault.client
Interface VaultClient.RequestBodySpec
- All Superinterfaces:
VaultClient.RequestHeadersSpec<VaultClient.RequestBodySpec>
- All Known Subinterfaces:
VaultClient.RequestHeadersBodyPathSpec
- Enclosing interface:
- VaultClient
public static interface VaultClient.RequestBodySpec
extends VaultClient.RequestHeadersSpec<VaultClient.RequestBodySpec>
Contract for specifying request headers and body leading up to the exchange.
-
Method Summary
Modifier and TypeMethodDescriptionSet the body of the request to the givenObject.body(T body, ParameterizedTypeReference<T> bodyType) Set the body of the request to the givenObject.
-
Method Details
-
body
Set the body of the request to the givenObject. For example:Person person = ... ; ResponseEntity<Void> response = client.post() .path("/persons/{id}", id) .body(person) .retrieve() .toBodilessEntity();- Parameters:
body- the body of the request.- Returns:
- this builder.
-
body
Set the body of the request to the givenObject. The parameterbodyTypeis used to capture the generic type.- Parameters:
body- the body of the request.bodyType- the type of the body, used to capture the generic type.- Returns:
- this builder.
-