Documentation ¶
Index ¶
- Variables
- type APIResponse
- type APISResponse
- type CategoriesPayload
- type Client
- func (c *Client) CreateAPIs(apiDefs *[]objects.DBApiDefinition) error
- func (c *Client) CreateAssets(assetsDefs *[]objects.DBAssets) error
- func (c *Client) CreateCertificate(cert []byte) (string, error)
- func (c *Client) CreatePolicies(pols *[]objects.Policy) error
- func (c *Client) DeleteAPI(id string) error
- func (c *Client) DeleteAssets(id string) error
- func (c *Client) DeletePolicy(id string) error
- func (c *Client) FetchAPI(apiID string) (objects.DBApiDefinition, error)
- func (c *Client) FetchAPIs() (*APISResponse, error)
- func (c *Client) FetchAsset(assetID string) (objects.DBAssets, error)
- func (c *Client) FetchAssets() ([]objects.DBAssets, error)
- func (c *Client) FetchOASAPI(id string) (*oas.OAS, error)
- func (c *Client) FetchOASCategory(id string) ([]string, error)
- func (c *Client) FetchPolicies() ([]objects.Policy, error)
- func (c *Client) FetchPolicy(id string) (*objects.Policy, error)
- func (c *Client) GetActiveID(def *objects.DBApiDefinition) string
- func (c *Client) SetInsecureTLS(val bool)
- func (c *Client) SyncAPIs(apiDefs []objects.DBApiDefinition) error
- func (c *Client) SyncAssets(assetsDefs []objects.DBAssets) error
- func (c *Client) SyncPolicies(pols []objects.Policy) error
- func (c *Client) UpdateAPIs(apiDefs *[]objects.DBApiDefinition) error
- func (c *Client) UpdateAssets(assetsDef *[]objects.DBAssets) error
- func (c *Client) UpdateOASCategory(oasApi *objects.DBApiDefinition) (*grequests.Response, error)
- func (c *Client) UpdatePolicies(pols *[]objects.Policy) error
- type PoliciesData
Constants ¶
This section is empty.
Variables ¶
View Source
var ( UseUpdateError error = errors.New("Object seems to exist (same ID, API ID, Listen Path or Slug), use update()") UsePolUpdateError error = errors.New("Object seems to exist (same ID, Explicit ID), use update()") UseCreateError error = errors.New("Object does not exist, use create()") UseAssetUpdateError error = errors.New("Object seems to exist (same ID) use update()") )
Functions ¶
This section is empty.
Types ¶
type APIResponse ¶
type APISResponse ¶
type APISResponse struct { Apis []objects.DBApiDefinition `json:"apis"` Pages int `json:"pages"` }
type CategoriesPayload ¶ added in v1.5.0
type CategoriesPayload struct {
Categories []string `json:"categories"`
}
CategoriesPayload is a struct that holds a list of categories.
type Client ¶
type Client struct { InsecureSkipVerify bool OrgID string // contains filtered or unexported fields }
func NewDashboardClient ¶
func (*Client) CreateAPIs ¶ added in v1.2.3
func (c *Client) CreateAPIs(apiDefs *[]objects.DBApiDefinition) error
func (*Client) CreateAssets ¶ added in v1.5.0
func (*Client) CreatePolicies ¶ added in v1.2.3
func (*Client) DeleteAssets ¶ added in v1.5.0
func (*Client) DeletePolicy ¶
func (*Client) FetchAPI ¶ added in v1.2.0
func (c *Client) FetchAPI(apiID string) (objects.DBApiDefinition, error)
func (*Client) FetchAPIs ¶
func (c *Client) FetchAPIs() (*APISResponse, error)
func (*Client) FetchAsset ¶ added in v1.5.0
func (*Client) FetchAssets ¶ added in v1.5.0
func (*Client) FetchOASAPI ¶ added in v1.5.0
func (*Client) FetchOASCategory ¶ added in v1.5.0
func (*Client) GetActiveID ¶
func (c *Client) GetActiveID(def *objects.DBApiDefinition) string
func (*Client) SetInsecureTLS ¶
func (*Client) SyncAPIs ¶ added in v1.2.3
func (c *Client) SyncAPIs(apiDefs []objects.DBApiDefinition) error
func (*Client) SyncAssets ¶ added in v1.5.0
func (*Client) UpdateAPIs ¶ added in v1.2.3
func (c *Client) UpdateAPIs(apiDefs *[]objects.DBApiDefinition) error
func (*Client) UpdateAssets ¶ added in v1.5.0
func (*Client) UpdateOASCategory ¶ added in v1.5.0
type PoliciesData ¶
Click to show internal directories.
Click to hide internal directories.