All URIs are relative to http://localhost/api
Method | HTTP request | Description |
---|---|---|
projects_project_id_robots_get | GET /projects/{project_id}/robots | Get all robot accounts of specified project |
projects_project_id_robots_post | POST /projects/{project_id}/robots | Create a robot account for project |
projects_project_id_robots_robot_id_delete | DELETE /projects/{project_id}/robots/{robot_id} | Delete the specified robot account |
projects_project_id_robots_robot_id_get | GET /projects/{project_id}/robots/{robot_id} | Return the infor of the specified robot account. |
projects_project_id_robots_robot_id_put | PUT /projects/{project_id}/robots/{robot_id} | Update status of robot account. |
Array<RobotAccount> projects_project_id_robots_get(project_id)
Get all robot accounts of specified project
Get all robot accounts of specified project
# load the gem
require 'harbor1_client'
# setup authorization
Harbor1Client.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR USERNAME'
config.password = 'YOUR PASSWORD'
end
api_instance = Harbor1Client::RobotAccountApi.new
project_id = 789 # Integer | Relevant project ID.
begin
#Get all robot accounts of specified project
result = api_instance.projects_project_id_robots_get(project_id)
p result
rescue Harbor1Client::ApiError => e
puts "Exception when calling RobotAccountApi->projects_project_id_robots_get: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
project_id | Integer | Relevant project ID. |
- Content-Type: application/json
- Accept: application/json, text/plain
RobotAccountPostRep projects_project_id_robots_post(project_id, robot)
Create a robot account for project
Create a robot account for project
# load the gem
require 'harbor1_client'
# setup authorization
Harbor1Client.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR USERNAME'
config.password = 'YOUR PASSWORD'
end
api_instance = Harbor1Client::RobotAccountApi.new
project_id = 789 # Integer | Relevant project ID.
robot = Harbor1Client::RobotAccountCreate.new # RobotAccountCreate | Request body of creating a robot account.
begin
#Create a robot account for project
result = api_instance.projects_project_id_robots_post(project_id, robot)
p result
rescue Harbor1Client::ApiError => e
puts "Exception when calling RobotAccountApi->projects_project_id_robots_post: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
project_id | Integer | Relevant project ID. | |
robot | RobotAccountCreate | Request body of creating a robot account. |
- Content-Type: application/json
- Accept: application/json, text/plain
projects_project_id_robots_robot_id_delete(project_id, robot_id)
Delete the specified robot account
Delete the specified robot account
# load the gem
require 'harbor1_client'
# setup authorization
Harbor1Client.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR USERNAME'
config.password = 'YOUR PASSWORD'
end
api_instance = Harbor1Client::RobotAccountApi.new
project_id = 789 # Integer | Relevant project ID.
robot_id = 789 # Integer | The ID of robot account.
begin
#Delete the specified robot account
api_instance.projects_project_id_robots_robot_id_delete(project_id, robot_id)
rescue Harbor1Client::ApiError => e
puts "Exception when calling RobotAccountApi->projects_project_id_robots_robot_id_delete: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
project_id | Integer | Relevant project ID. | |
robot_id | Integer | The ID of robot account. |
nil (empty response body)
- Content-Type: application/json
- Accept: application/json, text/plain
RobotAccount projects_project_id_robots_robot_id_get(project_id, robot_id)
Return the infor of the specified robot account.
Return the infor of the specified robot account.
# load the gem
require 'harbor1_client'
# setup authorization
Harbor1Client.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR USERNAME'
config.password = 'YOUR PASSWORD'
end
api_instance = Harbor1Client::RobotAccountApi.new
project_id = 789 # Integer | Relevant project ID.
robot_id = 789 # Integer | The ID of robot account.
begin
#Return the infor of the specified robot account.
result = api_instance.projects_project_id_robots_robot_id_get(project_id, robot_id)
p result
rescue Harbor1Client::ApiError => e
puts "Exception when calling RobotAccountApi->projects_project_id_robots_robot_id_get: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
project_id | Integer | Relevant project ID. | |
robot_id | Integer | The ID of robot account. |
- Content-Type: application/json
- Accept: application/json, text/plain
projects_project_id_robots_robot_id_put(project_id, robot_id, robot)
Update status of robot account.
Used to disable/enable a specified robot account.
# load the gem
require 'harbor1_client'
# setup authorization
Harbor1Client.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR USERNAME'
config.password = 'YOUR PASSWORD'
end
api_instance = Harbor1Client::RobotAccountApi.new
project_id = 789 # Integer | Relevant project ID.
robot_id = 789 # Integer | The ID of robot account.
robot = Harbor1Client::RobotAccountUpdate.new # RobotAccountUpdate | Request body of enable/disable a robot account.
begin
#Update status of robot account.
api_instance.projects_project_id_robots_robot_id_put(project_id, robot_id, robot)
rescue Harbor1Client::ApiError => e
puts "Exception when calling RobotAccountApi->projects_project_id_robots_robot_id_put: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
project_id | Integer | Relevant project ID. | |
robot_id | Integer | The ID of robot account. | |
robot | RobotAccountUpdate | Request body of enable/disable a robot account. |
nil (empty response body)
- Content-Type: application/json
- Accept: application/json, text/plain