Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
DefaultCollectionName = "Root"
)
Functions ¶
func New ¶
func New(cfg Config) docbuilder.DocBuilder
Types ¶
type Body ¶
type Body struct { Mode string `json:"mode"` FormData []Variable `json:"formdata"` URLEncoded []Variable `json:"urlencoded"` Raw string `json:"raw"` }
Body describes a request body
type Collection ¶
type Collection struct { Info Info `json:"info"` Items []Item `json:"item"` Variables []Variable `json:"variable"` }
Collection describes the full API documentation
type Info ¶
type Info struct { Name string `json:"name"` Description string `json:"description"` Schema string `json:"schema"` }
Info describes the postman info section
type Item ¶
type Item struct { Name string `json:"name"` Description string `json:"description"` Items []RequestItem `json:"item"` RequestItem }
Item describes a request collection/item
type Request ¶
type Request struct { Method string `json:"method"` Headers []Variable `json:"header"` Body Body `json:"body"` URL URL `json:"url"` Description string `json:"description"` }
Request describes a request
type RequestItem ¶
type RequestItem struct { Name string `json:"name"` Items []RequestItem `json:"item"` Request Request `json:"request"` Responses []Response `json:"response"` IsSubFolder bool `json:"_postman_isSubFolder"` }
RequestItem describes a request item
type Response ¶
type Response struct { ID string `json:"id"` Name string `json:"name"` OriginalRequest Request `json:"originalRequest"` Status string `json:"status"` Code int `json:"code"` Headers []Variable `json:"header"` Body string `json:"body"` PreviewLanguage string `json:"_postman_previewlanguage"` }
Response describes a request resposne
type URL ¶
type URL struct { Raw string `json:"raw"` Host []string `json:"host"` Path []string `json:"path"` Description string `json:"description"` Query []Variable `json:"query"` Variables []Variable `json:"variable"` }
URL describes URL of the request
type Variable ¶
type Variable struct { Key string `json:"key"` Value string `json:"value"` Description string `json:"description"` Type string `json:"type"` Disabled bool `json:"disabled"` Enabled bool `json:"enabled"` // this field is used by env }
Field describes query, header, form-data and urlencoded field of request
Click to show internal directories.
Click to hide internal directories.