Documentation
¶
Overview ¶
Package escape provides the API client for the Escape Platform
Index ¶
- Variables
- func CreateLocation(ctx context.Context, name, sshPublicKey string) (string, error)
- func DeleteIntegration(ctx context.Context, id string) error
- func DeleteLocation(ctx context.Context, id string) error
- func DownloadScanExchangesZip(ctx context.Context, scanID string, outPath string) error
- func GetApplication(ctx context.Context, id string) (*v2.GetApplication200Response, error)
- func GetIntegration(ctx context.Context, id string) (*v2.GetIntegration200Response, error)
- func GetLocation(ctx context.Context, id string) (*v2.ListLocations200ResponseDataInner, error)
- func GetScan(ctx context.Context, scanID string) (*v2.ListScans200ResponseDataInner, error)
- func GetScanIssues(ctx context.Context, scanID string) ([]v2.ListIssues200ResponseInner, error)
- func ListApplications(ctx context.Context) ([]v2.ListApplications200ResponseInner, error)
- func ListIntegrations(ctx context.Context) ([]v2.ListIntegrations200ResponseInner, error)
- func ListLocations(ctx context.Context, next string) ([]v2.ListLocations200ResponseDataInner, string, error)
- func ListScans(ctx context.Context, applicationID, next string) ([]v2.ListScans200ResponseDataInner, string, error)
- func ListSubdomains(ctx context.Context, count *int, after *string) ([]v2.ListSubdomains200ResponseDataInner, string, error)
- func ParseJSONOrYAML[T parsable](body []byte, v T) (T, error)
- func StartScan(ctx context.Context, applicationID string, commitHash string, ...) (*v2.ListScans200ResponseDataInner, error)
- func UpdateApplicationConfig(ctx context.Context, id string, configPath string) error
- func UpdateApplicationSchema(ctx context.Context, id string, schemaPathOrURL string) error
- func UpdateLocation(ctx context.Context, id string, name, sshPublicKey string) error
- func UpsertIntegration(ctx context.Context, name string, locationID *string, ...) error
- func UpsertIntegrationFromFile(ctx context.Context, filePath string) error
- func UpsertLocation(ctx context.Context, name, sshPublicKey string) (string, error)
- func WatchScan(ctx context.Context, scanID string) (chan *v2.ListScans200ResponseDataInner, error)
Constants ¶
This section is empty.
Variables ¶
var Debug = false
Debug is a flag to enable debug mode for the API client
Functions ¶
func CreateLocation ¶
CreateLocation creates a location
func DeleteIntegration ¶
DeleteIntegration Deletes an integration
func DeleteLocation ¶
DeleteLocation deletes a location
func DownloadScanExchangesZip ¶
DownloadScanExchangesZip downloads the zip file of the scan exchanges and puts them in outPath
func GetApplication ¶
GetApplication gets an application by ID
func GetIntegration ¶
GetIntegration Get an integration by ID
func GetLocation ¶
GetLocation gets a location by ID
func GetScanIssues ¶
GetScanIssues returns issues found in a scan
func ListApplications ¶
func ListApplications(ctx context.Context) ([]v2.ListApplications200ResponseInner, error)
ListApplications lists all applications
func ListIntegrations ¶
func ListIntegrations(ctx context.Context) ([]v2.ListIntegrations200ResponseInner, error)
ListIntegrations Lists all integrations
func ListLocations ¶
func ListLocations(ctx context.Context, next string) ([]v2.ListLocations200ResponseDataInner, string, error)
ListLocations lists all locations
func ListScans ¶
func ListScans(ctx context.Context, applicationID, next string) ([]v2.ListScans200ResponseDataInner, string, error)
ListScans lists all scans for an application
func ListSubdomains ¶
func ListSubdomains(ctx context.Context, count *int, after *string) ([]v2.ListSubdomains200ResponseDataInner, string, error)
ListSubdomains lists subdomains with pagination
func ParseJSONOrYAML ¶
ParseJSONOrYAML parses a JSON or YAML data into the requested struct It returns an error if the data is neither JSON nor YAML
Example:
d, err := ParseJSONOrYAML([]byte(`{"kind": "KUBERNETES", "parameters": {}}`), &v2.GetIntegration200ResponseData{})
func StartScan ¶
func StartScan( ctx context.Context, applicationID string, commitHash string, commitLink string, commitBranch string, commitAuthor string, commitAuthorProfilePictureLink string, configurationOverride *v2.FrontendConfiguration, ) (*v2.ListScans200ResponseDataInner, error)
StartScan starts a scan for an application
func UpdateApplicationConfig ¶
UpdateApplicationConfig updates an application configuration
func UpdateApplicationSchema ¶
UpdateApplicationSchema updates an application schema
func UpdateLocation ¶
UpdateLocation updates a location
func UpsertIntegration ¶
func UpsertIntegration(ctx context.Context, name string, locationID *string, integration *v2.GetIntegration200ResponseData) error
UpsertIntegration Upserts an integration
func UpsertIntegrationFromFile ¶
UpsertIntegrationFromFile Upserts an integration from a file
func UpsertLocation ¶
UpsertLocation Creates or updates a location
Types ¶
This section is empty.