AWSRequest
public struct AWSRequest
Object encapsulating all the information needed to generate a raw HTTP request to AWS
-
Undocumented
Declaration
Swift
public let region: Region -
Undocumented
Declaration
Swift
public var url: URL -
Undocumented
Declaration
Swift
public let serviceProtocol: ServiceProtocol -
Undocumented
Declaration
Swift
public let operation: String -
Undocumented
Declaration
Swift
public let httpMethod: String -
Undocumented
Declaration
Swift
public var httpHeaders: [String : Any] -
Undocumented
Declaration
Swift
public var body: Body -
Initialize AWSRequest struct
Declaration
Swift
public init(region: Region = .useast1, url: URL, serviceProtocol: ServiceProtocol, operation: String, httpMethod: String, httpHeaders: [String : Any] = [:], body: Body = .empty)Parameters
regionRegion of AWS server
urlRequest URL
serviceProtocolprotocol of service (.json, .xml, .query etc)
operationName of AWS operation
httpMethodHTTP method to use (“GET”, “PUT”, “PUSH” etc)
httpHeadersHTTP request headers
bodyHTTP Request body
-
Add a header value
Declaration
Swift
public mutating func addValue(_ value: String, forHTTPHeaderField field: String)Parameters
valuevalue
forHTTPHeaderFieldname of header
View on GitHub
AWSRequest Structure Reference