package
0.0.0-20230516194455-8aef9cf14534
Repository: https://github.com/nextlinux/client-go.git
Documentation: pkg.go.dev

# README

Go API client for external

This is the Nextlinux Engine API. Provides the primary external API for users of the service.

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 0.1.16
  • Package version: 0.1.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context
go get github.com/antihax/optional

Put the package under your project folder and add the following in import:

import "./external"

Documentation for API Endpoints

All URIs are relative to http://localhost

ClassMethodHTTP requestDescription
ArchivesApiArchiveImageAnalysisPost /archives/images
ArchivesApiCreateAnalysisArchiveRulePost /archives/rules
ArchivesApiDeleteAnalysisArchiveRuleDelete /archives/rules/{ruleId}
ArchivesApiDeleteArchivedAnalysisDelete /archives/images/{imageDigest}
ArchivesApiGetAnalysisArchiveRuleGet /archives/rules/{ruleId}
ArchivesApiGetArchivedAnalysisGet /archives/images/{imageDigest}
ArchivesApiListAnalysisArchiveGet /archives/images
ArchivesApiListAnalysisArchiveRulesGet /archives/rules
ArchivesApiListArchivesGet /archives
DefaultApiGetOauthTokenPost /oauth/token
DefaultApiHealthCheckGet /health
DefaultApiListFileContentSearchResultsGet /images/{imageDigest}/artifacts/file_content_searchReturn a list of analyzer artifacts of the specified type
DefaultApiListRetrievedFilesGet /images/{imageDigest}/artifacts/retrieved_filesReturn a list of analyzer artifacts of the specified type
DefaultApiListSecretSearchResultsGet /images/{imageDigest}/artifacts/secret_searchReturn a list of analyzer artifacts of the specified type
DefaultApiPingGet /
DefaultApiVersionCheckGet /version
EventsApiDeleteEventDelete /events/{eventId}Delete Event
EventsApiDeleteEventsDelete /eventsDelete Events
EventsApiGetEventGet /events/{eventId}Get Event
EventsApiListEventTypesGet /event_typesList Event Types
EventsApiListEventsGet /eventsList Events
IdentityApiAddCredentialPost /user/credentialsadd/replace credential
IdentityApiGetCredentialsGet /user/credentialsGet current credential summary
IdentityApiGetUserGet /userList authenticated user info
IdentityApiGetUsersAccountGet /accountList the account for the authenticated user
ImagesApiAddImagePost /imagesSubmit a new image for analysis by the engine
ImagesApiDeleteImageDelete /images/{imageDigest}Delete an image analysis
ImagesApiDeleteImageByImageIdDelete /images/by_id/{imageId}Delete image by docker imageId
ImagesApiDeleteImagesAsyncDelete /imagesBulk mark images for deletion
ImagesApiGetImageGet /images/{imageDigest}Get image metadata
ImagesApiGetImageByImageIdGet /images/by_id/{imageId}Lookup image by docker imageId
ImagesApiGetImageContentByTypeGet /images/{imageDigest}/content/{ctype}Get the content of an image by type
ImagesApiGetImageContentByTypeFilesGet /images/{imageDigest}/content/filesGet the content of an image by type files
ImagesApiGetImageContentByTypeImageIdGet /images/by_id/{imageId}/content/{ctype}Get the content of an image by type
ImagesApiGetImageContentByTypeImageIdFilesGet /images/by_id/{imageId}/content/filesGet the content of an image by type files
ImagesApiGetImageContentByTypeImageIdJavapackageGet /images/by_id/{imageId}/content/javaGet the content of an image by type java
ImagesApiGetImageContentByTypeJavapackageGet /images/{imageDigest}/content/javaGet the content of an image by type java
ImagesApiGetImageContentByTypeMalwareGet /images/{imageDigest}/content/malwareGet the content of an image by type malware
ImagesApiGetImageMetadataByTypeGet /images/{imageDigest}/metadata/{mtype}Get the metadata of an image by type
ImagesApiGetImagePolicyCheckGet /images/{imageDigest}/checkCheck policy evaluation status for image
ImagesApiGetImagePolicyCheckByImageIdGet /images/by_id/{imageId}/checkCheck policy evaluation status for image
ImagesApiGetImageVulnerabilitiesByTypeGet /images/{imageDigest}/vuln/{vtype}Get vulnerabilities by type
ImagesApiGetImageVulnerabilitiesByTypeImageIdGet /images/by_id/{imageId}/vuln/{vtype}Get vulnerabilities by type
ImagesApiGetImageVulnerabilityTypesGet /images/{imageDigest}/vulnGet vulnerability types
ImagesApiGetImageVulnerabilityTypesByImageIdGet /images/by_id/{imageId}/vulnGet vulnerability types
ImagesApiListImageContentGet /images/{imageDigest}/contentList image content types
ImagesApiListImageContentByImageidGet /images/by_id/{imageId}/contentList image content types
ImagesApiListImageMetadataGet /images/{imageDigest}/metadataList image metadata types
ImagesApiListImagesGet /imagesList all visible images
ImportApiImportImageArchivePost /import/imagesImport an nextlinux image tar.gz archive file. This is a deprecated API replaced by the "/imports/images" route
ImportsApiCreateOperationPost /imports/imagesBegin the import of an image analyzed by Syft into the system
ImportsApiGetOperationGet /imports/images/{operation_id}Get detail on a single import
ImportsApiImportImageConfigPost /imports/images/{operation_id}/image_configImport a docker or OCI image config to associate with the image
ImportsApiImportImageDockerfilePost /imports/images/{operation_id}/dockerfileBegin the import of an image analyzed by Syft into the system
ImportsApiImportImageManifestPost /imports/images/{operation_id}/manifestImport a docker or OCI distribution manifest to associate with the image
ImportsApiImportImagePackagesPost /imports/images/{operation_id}/packagesBegin the import of an image analyzed by Syft into the system
ImportsApiImportImageParentManifestPost /imports/images/{operation_id}/parent_manifestImport a docker or OCI distribution manifest list to associate with the image
ImportsApiInvalidateOperationDelete /imports/images/{operation_id}Invalidate operation ID so it can be garbage collected
ImportsApiListImportDockerfilesGet /imports/images/{operation_id}/dockerfileList uploaded dockerfiles
ImportsApiListImportImageConfigsGet /imports/images/{operation_id}/image_configList uploaded image configs
ImportsApiListImportImageManifestsGet /imports/images/{operation_id}/manifestList uploaded image manifests
ImportsApiListImportPackagesGet /imports/images/{operation_id}/packagesList uploaded package manifests
ImportsApiListImportParentManifestsGet /imports/images/{operation_id}/parent_manifestList uploaded parent manifests (manifest lists for a tag)
ImportsApiListOperationsGet /imports/imagesLists in-progress imports
PoliciesApiAddPolicyPost /policiesAdd a new policy
PoliciesApiDeletePolicyDelete /policies/{policyId}Delete policy
PoliciesApiGetPolicyGet /policies/{policyId}Get specific policy
PoliciesApiListPoliciesGet /policiesList policies
PoliciesApiUpdatePolicyPut /policies/{policyId}Update policy
QueryApiQueryImagesByPackageGet /query/images/by_packageList of images containing given package
QueryApiQueryImagesByVulnerabilityGet /query/images/by_vulnerabilityList images vulnerable to the specific vulnerability ID.
QueryApiQueryVulnerabilitiesGet /query/vulnerabilitiesListing information about given vulnerability
RegistriesApiCreateRegistryPost /registriesAdd a new registry
RegistriesApiDeleteRegistryDelete /registries/{registry}Delete a registry configuration
RegistriesApiGetRegistryGet /registries/{registry}Get a specific registry configuration
RegistriesApiListRegistriesGet /registriesList configured registries
RegistriesApiUpdateRegistryPut /registries/{registry}Update/replace a registry configuration
RepositoryCredentialsApiAddRepositoryPost /repositoriesAdd repository to watch
SubscriptionsApiAddSubscriptionPost /subscriptionsAdd a subscription of a specific type
SubscriptionsApiDeleteSubscriptionDelete /subscriptions/{subscriptionId}Delete subscriptions of a specific type
SubscriptionsApiGetSubscriptionGet /subscriptions/{subscriptionId}Get a specific subscription set
SubscriptionsApiListSubscriptionsGet /subscriptionsList all subscriptions
SubscriptionsApiUpdateSubscriptionPut /subscriptions/{subscriptionId}Update an existing and specific subscription
SummariesApiListImagetagsGet /summaries/imagetagsList all visible image digests and tags
SystemApiDeleteFeedDelete /system/feeds/{feed}
SystemApiDeleteFeedGroupDelete /system/feeds/{feed}/{group}
SystemApiDeleteServiceDelete /system/services/{servicename}/{hostid}Delete the service config
SystemApiDescribeErrorCodesGet /system/error_codesDescribe nextlinux engine error codes.
SystemApiDescribePolicyGet /system/policy_specDescribe the policy language spec implemented by this service.
SystemApiGetServiceDetailGet /systemSystem status
SystemApiGetServicesByNameGet /system/services/{servicename}Get a service configuration and state
SystemApiGetServicesByNameAndHostGet /system/services/{servicename}/{hostid}Get service config for a specific host
SystemApiGetStatusGet /statusService status
SystemApiGetSystemFeedsGet /system/feedslist feeds operations and information
SystemApiListServicesGet /system/servicesList system services
SystemApiPostSystemFeedsPost /system/feedstrigger feeds operations
SystemApiTestWebhookPost /system/webhooks/{webhook_type}/testAdds the capabilities to test a webhook delivery for the given notification type
SystemApiToggleFeedEnabledPut /system/feeds/{feed}
SystemApiToggleGroupEnabledPut /system/feeds/{feed}/{group}
UserManagementApiCreateAccountPost /accountsCreate a new user. Only avaialble to admin user.
UserManagementApiCreateUserPost /accounts/{accountname}/usersCreate a new user
UserManagementApiCreateUserCredentialPost /accounts/{accountname}/users/{username}/credentialsadd/replace credential
UserManagementApiDeleteAccountDelete /accounts/{accountname}Delete the specified account, only allowed if the account is in the disabled state. All users will be deleted along with the account and all resources will be garbage collected
UserManagementApiDeleteUserDelete /accounts/{accountname}/users/{username}Delete a specific user credential by username of the credential. Cannot be the credential used to authenticate the request.
UserManagementApiDeleteUserCredentialDelete /accounts/{accountname}/users/{username}/credentialsDelete a credential by type
UserManagementApiGetAccountGet /accounts/{accountname}Get info about an user. Only available to admin user. Uses the main user Id, not a username.
UserManagementApiGetAccountUserGet /accounts/{accountname}/users/{username}Get a specific user in the specified account
UserManagementApiListAccountsGet /accountsList user summaries. Only available to the system admin user.
UserManagementApiListUserCredentialsGet /accounts/{accountname}/users/{username}/credentialsGet current credential summary
UserManagementApiListUsersGet /accounts/{accountname}/usersList accounts for the user
UserManagementApiUpdateAccountStatePut /accounts/{accountname}/stateUpdate the state of an account to either enabled or disabled. For deletion use the DELETE route

Documentation For Models

Documentation For Authorization

Endpoints do not require authorization.

Author

[email protected]