github.com/solo-io/cue@v0.4.7/pkg/tool/http/pkg.go (about) 1 // Code generated by go generate. DO NOT EDIT. 2 3 //go:generate rm pkg.go 4 //go:generate go run ../../gen/gen.go 5 6 package http 7 8 import ( 9 "github.com/solo-io/cue/internal/core/adt" 10 "github.com/solo-io/cue/pkg/internal" 11 ) 12 13 func init() { 14 internal.Register("tool/http", pkg) 15 } 16 17 var _ = adt.TopKind // in case the adt package isn't used 18 19 var pkg = &internal.Package{ 20 Native: []*internal.Builtin{}, 21 CUE: `{ 22 Get: Do & { 23 method: "GET" 24 } 25 Post: Do & { 26 method: "POST" 27 } 28 Put: Do & { 29 method: "PUT" 30 } 31 Delete: Do & { 32 method: "DELETE" 33 } 34 Do: { 35 $id: *"tool/http.Do" | "http" 36 method: string 37 url: string 38 request: { 39 body?: bytes | string 40 header: { 41 [string]: string | [...string] 42 } 43 trailer: { 44 [string]: string | [...string] 45 } 46 } 47 response: { 48 status: string 49 statusCode: int 50 body: *bytes | string 51 header: { 52 [string]: string | [...string] 53 } 54 trailer: { 55 [string]: string | [...string] 56 } 57 } 58 } 59 }`, 60 }