class HTTP::Request

Overview

An HTTP request.

It serves both to perform requests by an HTTP::Client and to represent requests received by an HTTP::Server.

A request always holds an IO as a body. When creating a request with a String or Bytes its body will be a IO::Memory wrapping these, and the Content-Length header will be set appropriately.

NOTE To use Request, you must explicitly import it with require "http/request"

Defined in:

runcobo/extensions/http.cr
runcobo/extensions/request.cr
runcobo/request_input.cr

Instance Method Summary

Instance Method Detail

def base_url(*args, **options) #

[View source]
def base_url(*args, **options, &) #

[View source]
def host(*args, **options) #

[View source]
def host(*args, **options, &) #

[View source]
def port(*args, **options) #

[View source]
def port(*args, **options, &) #

[View source]
def protocol(*args, **options) #

[View source]
def protocol(*args, **options, &) #

[View source]
def remote_ip(*args, **options) #

[View source]
def remote_ip(*args, **options, &) #

[View source]
def request_id : String | Nil #

[View source]
def request_id=(request_id : String | Nil) #

[View source]
def route_params : Hash(String, String) #

[View source]
def route_params=(route_params : Hash(String, String)) #

[View source]
def runcobo_input : Runcobo::RequestInput #

[View source]
def scheme(*args, **options) #

[View source]
def scheme(*args, **options, &) #

[View source]
def ssl?(*args, **options) #

[View source]
def ssl?(*args, **options, &) #

[View source]