Interface HttpRequest
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
HttpRequest.Jsii$Proxy
@Generated(value="jsii-pacmak/1.106.0 (build e852934)",
date="2025-02-17T19:20:39.190Z")
@Stability(Experimental)
public interface HttpRequest
extends software.amazon.jsii.JsiiSerializable
(experimental) Request to the HttpCall resource.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.integtests.alpha.*; HttpRequest httpRequest = HttpRequest.builder() .parameters(HttpRequestParameters.builder() .url("url") // the properties below are optional .fetchOptions(FetchOptions.builder() .body("body") .headers(Map.of( "headersKey", "headers")) .method("method") .port(123) .build()) .build()) // the properties below are optional .flattenResponse("flattenResponse") .build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final class
A builder forHttpRequest
static final class
An implementation forHttpRequest
-
Method Summary
Modifier and TypeMethodDescriptionstatic HttpRequest.Builder
builder()
default String
(experimental) Whether or not to flatten the response from the HTTP request.(experimental) Parameters from the custom resource.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getParameters
(experimental) Parameters from the custom resource. -
getFlattenResponse
(experimental) Whether or not to flatten the response from the HTTP request.Valid values are 'true' or 'false' as strings
Typically when using an HttpRequest you will be passing it as the
actual
value to an assertion provider so this would be set to 'false' (you want the actual response).If you are using the HttpRequest to perform more of a query to return a single value to use, then this should be set to 'true'.
Default: 'false'
-
builder
- Returns:
- a
HttpRequest.Builder
ofHttpRequest
-