Documentation ¶
Index ¶
Constants ¶
View Source
const (
// HiroFileName is the hiro config
HiroFileName = "hiro.json"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APISpec ¶
type APISpec struct { // Spec is the local file source for this api Spec string `json:"spec,omitempty"` // Source is the remote url for the api Source string `json:"source,omitempty"` // Principal is the data structure to use for authorization context Principal string `json:"principal,omitempty"` // Version is the semantic version for the function Version string `json:"version,omitempty"` // Models is the models import path Models string `json:"models"` // BasePath is the generated source base path BasePath string `json:"base"` // ServerPackage is the service base package ServerPackage string `json:"server_package"` // WithContext determine if the api methods will have a context.Context parameter WithContext bool `json:"with_context"` // AutoSync tells hiro to sync this api implicitly if sync is called with no parameters AutoSync bool `json:"auto_sync"` }
APISpec defines an API Specification
type Config ¶
type Config struct { // Name is the project name Name string `json:"name"` // APIs is the project apis APIs map[string]*APISpec `json:"apis"` // Options is the Swagger Generation Options Options GenOptions `json:"options"` // License is the license definition for the project License License `json:"license"` // Environment defines the global environment Environment map[string]map[string]string `json:"environment,omitempty"` // contains filtered or unexported fields }
Config is the hiro project file definition
type Function ¶
type Function struct { Source string `json:"source,omitempty"` Proxy string `json:"proxy,omitempty"` Env string `json:"env,omitempty"` }
Function defines a function settings
type GenOptions ¶
type GenOptions struct { // Generate using non-pointer arrays i.e. []type vs []*type ScalarArrays bool `json:"scalar_arrays"` }
GenOptions defines globa swagger generation options
Click to show internal directories.
Click to hide internal directories.