parent
80e28d15d6
commit
db39cdcdc7
|
@ -8,7 +8,7 @@
|
||||||
# MIT license (LICENSE-MIT)
|
# MIT license (LICENSE-MIT)
|
||||||
import std/[macros, options, uri, sequtils]
|
import std/[macros, options, uri, sequtils]
|
||||||
import chronos, chronos/apps/http/[httpcommon, httptable, httpclient]
|
import chronos, chronos/apps/http/[httpcommon, httptable, httpclient]
|
||||||
import chronicles
|
import chronicles except error
|
||||||
import httputils, stew/base10
|
import httputils, stew/base10
|
||||||
import segpath, common, macrocommon, agent
|
import segpath, common, macrocommon, agent
|
||||||
export httpclient, httptable, httpcommon, options, agent, httputils
|
export httpclient, httptable, httpcommon, options, agent, httputils
|
||||||
|
@ -19,9 +19,11 @@ template meth*(v: HttpMethod) {.pragma.}
|
||||||
type
|
type
|
||||||
RestClient* = object of RootObj
|
RestClient* = object of RootObj
|
||||||
session: HttpSessionRef
|
session: HttpSessionRef
|
||||||
address: HttpAddress
|
address*: HttpAddress
|
||||||
agent: string
|
agent: string
|
||||||
|
|
||||||
|
RestClientRef* = ref RestClient
|
||||||
|
|
||||||
RestPlainResponse* = object
|
RestPlainResponse* = object
|
||||||
status*: int
|
status*: int
|
||||||
contentType*: string
|
contentType*: string
|
||||||
|
@ -40,8 +42,6 @@ type
|
||||||
RestReturnKind {.pure.} = enum
|
RestReturnKind {.pure.} = enum
|
||||||
Status, PlainResponse, GenericResponse, Value
|
Status, PlainResponse, GenericResponse, Value
|
||||||
|
|
||||||
RestClientRef* = ref RestClient
|
|
||||||
|
|
||||||
RestDefect* = object of Defect
|
RestDefect* = object of Defect
|
||||||
RestError* = object of CatchableError
|
RestError* = object of CatchableError
|
||||||
RestEncodingError* = object of RestError
|
RestEncodingError* = object of RestError
|
||||||
|
|
Loading…
Reference in New Issue