0.3.2 • Published 7 years ago

harbor_api v0.3.2

Weekly downloads
-
License
Unlicense
Repository
-
Last release
7 years ago

harbor_api

HarborApi - JavaScript client for harbor_api These APIs provide services for manipulating Harbor project. This SDK is automatically generated by the Swagger Codegen project:

  • API version: 0.3.0
  • Package version: 0.3.0
  • Build package: io.swagger.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install harbor_api --save

git

If the library is hosted at a git repository, e.g. https://github.com/YOUR_USERNAME/harbor_api then install it via:

    npm install YOUR_USERNAME/harbor_api --save

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Getting Started

Please follow the installation instruction and execute the following JS code:

var HarborApi = require('harbor_api');

var api = new HarborApi.ProductsApi()

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.configurationsGet(callback);

Documentation for API Endpoints

All URIs are relative to http://localhost/api

ClassMethodHTTP requestDescription
HarborApi.ProductsApiconfigurationsGetGET /configurationsGet system configurations.
HarborApi.ProductsApiconfigurationsPutPUT /configurationsModify system configurations.
HarborApi.ProductsApiconfigurationsResetPostPOST /configurations/resetReset system configurations.
HarborApi.ProductsApiemailPingPostPOST /email/pingTest connection and authentication with email server.
HarborApi.ProductsApiinternalSyncregistryPostPOST /internal/syncregistrySync repositories from registry to DB.
HarborApi.ProductsApijobsReplicationGetGET /jobs/replicationList filters jobs according to the policy and repository
HarborApi.ProductsApijobsReplicationIdDeleteDELETE /jobs/replication/{id}Delete specific ID job.
HarborApi.ProductsApijobsReplicationIdLogGetGET /jobs/replication/{id}/logGet job logs.
HarborApi.ProductsApildapPingPostPOST /ldap/pingPing available ldap service.
HarborApi.ProductsApildapUsersImportPostPOST /ldap/users/importImport selected available ldap users.
HarborApi.ProductsApildapUsersSearchPostPOST /ldap/users/searchSearch available ldap users.
HarborApi.ProductsApilogsGetGET /logsGet recent logs of the projects which the user is a member of
HarborApi.ProductsApipoliciesReplicationGetGET /policies/replicationList filters policies by name and project_id
HarborApi.ProductsApipoliciesReplicationIdEnablementPutPUT /policies/replication/{id}/enablementPut modifies enablement of the policy.
HarborApi.ProductsApipoliciesReplicationIdGetGET /policies/replication/{id}Get replication policy.
HarborApi.ProductsApipoliciesReplicationIdPutPUT /policies/replication/{id}Put modifies name, description, target and enablement of policy.
HarborApi.ProductsApipoliciesReplicationPostPOST /policies/replicationPost creates a policy
HarborApi.ProductsApiprojectsGetGET /projectsReturn projects created by Harbor
HarborApi.ProductsApiprojectsHeadHEAD /projectsCheck if the project name user provided already exists.
HarborApi.ProductsApiprojectsPostPOST /projectsCreate a new project.
HarborApi.ProductsApiprojectsProjectIdDeleteDELETE /projects/{project_id}Delete project by projectID
HarborApi.ProductsApiprojectsProjectIdGetGET /projects/{project_id}Return specific project detail infomation
HarborApi.ProductsApiprojectsProjectIdLogsFilterPostPOST /projects/{project_id}/logs/filterGet access logs accompany with a relevant project.
HarborApi.ProductsApiprojectsProjectIdMembersGetGET /projects/{project_id}/members/Return a project's relevant role members.
HarborApi.ProductsApiprojectsProjectIdMembersPostPOST /projects/{project_id}/members/Add project role member accompany with relevant project and user.
HarborApi.ProductsApiprojectsProjectIdMembersUserIdDeleteDELETE /projects/{project_id}/members/{user_id}Delete project role members accompany with relevant project and user.
HarborApi.ProductsApiprojectsProjectIdMembersUserIdGetGET /projects/{project_id}/members/{user_id}Return role members accompany with relevant project and user.
HarborApi.ProductsApiprojectsProjectIdMembersUserIdPutPUT /projects/{project_id}/members/{user_id}Update project role members accompany with relevant project and user.
HarborApi.ProductsApiprojectsProjectIdPublicityPutPUT /projects/{project_id}/publicityUpdate properties for a selected project.
HarborApi.ProductsApirepositoriesGetGET /repositoriesGet repositories accompany with relevant project and repo name.
HarborApi.ProductsApirepositoriesRepoNameDeleteDELETE /repositories/{repo_name}Delete a repository.
HarborApi.ProductsApirepositoriesRepoNameSignaturesGetGET /repositories/{repo_name}/signaturesGet signature information of a repository
HarborApi.ProductsApirepositoriesRepoNameTagsGetGET /repositories/{repo_name}/tagsGet tags of a relevant repository.
HarborApi.ProductsApirepositoriesRepoNameTagsTagDeleteDELETE /repositories/{repo_name}/tags/{tag}Delete a tag in a repository.
HarborApi.ProductsApirepositoriesRepoNameTagsTagManifestGetGET /repositories/{repo_name}/tags/{tag}/manifestGet manifests of a relevant repository.
HarborApi.ProductsApirepositoriesTopGetGET /repositories/topGet public repositories which are accessed most.
HarborApi.ProductsApisearchGetGET /searchSearch for projects and repositories
HarborApi.ProductsApistatisticsGetGET /statisticsGet projects number and repositories number relevant to the user
HarborApi.ProductsApisysteminfoGetGET /systeminfoGet general system info
HarborApi.ProductsApisysteminfoGetcertGetGET /systeminfo/getcertGet default root certificate under OVA deployment.
HarborApi.ProductsApisysteminfoVolumesGetGET /systeminfo/volumesGet system volume info (total/free size).
HarborApi.ProductsApitargetsGetGET /targetsList filters targets by name.
HarborApi.ProductsApitargetsIdDeleteDELETE /targets/{id}Delete specific replication's target.
HarborApi.ProductsApitargetsIdGetGET /targets/{id}Get replication's target.
HarborApi.ProductsApitargetsIdPingPostPOST /targets/{id}/pingPing target.
HarborApi.ProductsApitargetsIdPoliciesGetGET /targets/{id}/policies/List the target relevant policies.
HarborApi.ProductsApitargetsIdPutPUT /targets/{id}Update replication's target.
HarborApi.ProductsApitargetsPingPostPOST /targets/pingPing validates target.
HarborApi.ProductsApitargetsPostPOST /targetsCreate a new replication target.
HarborApi.ProductsApiusersCurrentGetGET /users/currentGet current user info.
HarborApi.ProductsApiusersGetGET /usersGet registered users of Harbor.
HarborApi.ProductsApiusersPostPOST /usersCreates a new user account.
HarborApi.ProductsApiusersUserIdDeleteDELETE /users/{user_id}Mark a registered user as be removed.
HarborApi.ProductsApiusersUserIdPasswordPutPUT /users/{user_id}/passwordChange the password on a user that already exists.
HarborApi.ProductsApiusersUserIdPutPUT /users/{user_id}Update a registered user to change his profile.
HarborApi.ProductsApiusersUserIdSysadminPutPUT /users/{user_id}/sysadminUpdate a registered user to change to be an administrator of Harbor.

Documentation for Models

Documentation for Authorization

All endpoints do not require authorization.

0.3.2

7 years ago

0.3.1

7 years ago

0.3.0

7 years ago