Secure Source Manager V1 API - Class Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client (v2.2.0)

Reference documentation and code samples for the Secure Source Manager V1 API class Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.

Client for the SecureSourceManager service.

Secure Source Manager API

Access Secure Source Manager instances, resources, and repositories.

Inherits

  • Object

Methods

.configure

def self.configure() { |config| ... } -> Client::Configuration

Configure the SecureSourceManager Client class.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter
Example
# Modify the configuration for all SecureSourceManager clients
::Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.configure do |config|
  config.timeout = 10.0
end

#batch_create_pull_request_comments

def batch_create_pull_request_comments(request, options = nil) -> ::Gapic::Operation
def batch_create_pull_request_comments(parent: nil, requests: nil) -> ::Gapic::Operation

Batch creates pull request comments.

Overloads
def batch_create_pull_request_comments(request, options = nil) -> ::Gapic::Operation
Pass arguments to batch_create_pull_request_comments via a request object, either of type BatchCreatePullRequestCommentsRequest or an equivalent Hash.
Parameters
def batch_create_pull_request_comments(parent: nil, requests: nil) -> ::Gapic::Operation
Pass arguments to batch_create_pull_request_comments via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The pull request in which to create the pull request comments. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • requests (::Array<::Google::Cloud::SecureSourceManager::V1::CreatePullRequestCommentRequest, ::Hash>) — Required. The request message specifying the resources to create. There should be exactly one CreatePullRequestCommentRequest with CommentDetail being REVIEW in the list, and no more than 100 CreatePullRequestCommentRequests with CommentDetail being CODE in the list
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::BatchCreatePullRequestCommentsRequest.new

# Call the batch_create_pull_request_comments method.
result = client.batch_create_pull_request_comments request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#close_issue

def close_issue(request, options = nil) -> ::Gapic::Operation
def close_issue(name: nil, etag: nil) -> ::Gapic::Operation

Closes an issue.

Overloads
def close_issue(request, options = nil) -> ::Gapic::Operation
Pass arguments to close_issue via a request object, either of type CloseIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CloseIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def close_issue(name: nil, etag: nil) -> ::Gapic::Operation
Pass arguments to close_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. Name of the issue to close. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}.
  • etag (::String) — Optional. The current etag of the issue. If the etag is provided and does not match the current etag of the issue, closing will be blocked and an ABORTED error will be returned.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CloseIssueRequest.new

# Call the close_issue method.
result = client.close_issue request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#close_pull_request

def close_pull_request(request, options = nil) -> ::Gapic::Operation
def close_pull_request(name: nil) -> ::Gapic::Operation

Closes a pull request without merging.

Overloads
def close_pull_request(request, options = nil) -> ::Gapic::Operation
Pass arguments to close_pull_request via a request object, either of type ClosePullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ClosePullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def close_pull_request(name: nil) -> ::Gapic::Operation
Pass arguments to close_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The pull request to close. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ClosePullRequestRequest.new

# Call the close_pull_request method.
result = client.close_pull_request request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#configure

def configure() { |config| ... } -> Client::Configuration

Configure the SecureSourceManager Client instance.

The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter

#create_branch_rule

def create_branch_rule(request, options = nil) -> ::Gapic::Operation
def create_branch_rule(parent: nil, branch_rule: nil, branch_rule_id: nil) -> ::Gapic::Operation

CreateBranchRule creates a branch rule in a given repository.

Overloads
def create_branch_rule(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_branch_rule via a request object, either of type CreateBranchRuleRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateBranchRuleRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_branch_rule(parent: nil, branch_rule: nil, branch_rule_id: nil) -> ::Gapic::Operation
Pass arguments to create_branch_rule via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateBranchRuleRequest.new

# Call the create_branch_rule method.
result = client.create_branch_rule request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_hook

def create_hook(request, options = nil) -> ::Gapic::Operation
def create_hook(parent: nil, hook: nil, hook_id: nil) -> ::Gapic::Operation

Creates a new hook in a given repository.

Overloads
def create_hook(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_hook via a request object, either of type CreateHookRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateHookRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_hook(parent: nil, hook: nil, hook_id: nil) -> ::Gapic::Operation
Pass arguments to create_hook via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The repository in which to create the hook. Values are of the form projects/{project_number}/locations/{location_id}/repositories/{repository_id}
  • hook (::Google::Cloud::SecureSourceManager::V1::Hook, ::Hash) — Required. The resource being created.
  • hook_id (::String) — Required. The ID to use for the hook, which will become the final component of the hook's resource name. This value restricts to lower-case letters, numbers, and hyphen, with the first character a letter, the last a letter or a number, and a 63 character maximum.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateHookRequest.new

# Call the create_hook method.
result = client.create_hook request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_instance

def create_instance(request, options = nil) -> ::Gapic::Operation
def create_instance(parent: nil, instance_id: nil, instance: nil, request_id: nil) -> ::Gapic::Operation

Creates a new instance in a given project and location.

Overloads
def create_instance(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_instance via a request object, either of type CreateInstanceRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateInstanceRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_instance(parent: nil, instance_id: nil, instance: nil, request_id: nil) -> ::Gapic::Operation
Pass arguments to create_instance via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Value for parent.
  • instance_id (::String) — Required. ID of the instance to be created.
  • instance (::Google::Cloud::SecureSourceManager::V1::Instance, ::Hash) — Required. The resource being created.
  • request_id (::String) — Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

    For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

    The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateInstanceRequest.new

# Call the create_instance method.
result = client.create_instance request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_issue

def create_issue(request, options = nil) -> ::Gapic::Operation
def create_issue(parent: nil, issue: nil) -> ::Gapic::Operation

Creates an issue.

Overloads
def create_issue(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_issue via a request object, either of type CreateIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_issue(parent: nil, issue: nil) -> ::Gapic::Operation
Pass arguments to create_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The repository in which to create the issue. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}
  • issue (::Google::Cloud::SecureSourceManager::V1::Issue, ::Hash) — Required. The issue to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateIssueRequest.new

# Call the create_issue method.
result = client.create_issue request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_issue_comment

def create_issue_comment(request, options = nil) -> ::Gapic::Operation
def create_issue_comment(parent: nil, issue_comment: nil) -> ::Gapic::Operation

Creates an issue comment.

Overloads
def create_issue_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_issue_comment via a request object, either of type CreateIssueCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateIssueCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_issue_comment(parent: nil, issue_comment: nil) -> ::Gapic::Operation
Pass arguments to create_issue_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The issue in which to create the issue comment. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}
  • issue_comment (::Google::Cloud::SecureSourceManager::V1::IssueComment, ::Hash) — Required. The issue comment to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateIssueCommentRequest.new

# Call the create_issue_comment method.
result = client.create_issue_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_pull_request

def create_pull_request(request, options = nil) -> ::Gapic::Operation
def create_pull_request(parent: nil, pull_request: nil) -> ::Gapic::Operation

Creates a pull request.

Overloads
def create_pull_request(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_pull_request via a request object, either of type CreatePullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreatePullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_pull_request(parent: nil, pull_request: nil) -> ::Gapic::Operation
Pass arguments to create_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The repository that the pull request is created from. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}
  • pull_request (::Google::Cloud::SecureSourceManager::V1::PullRequest, ::Hash) — Required. The pull request to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreatePullRequestRequest.new

# Call the create_pull_request method.
result = client.create_pull_request request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_pull_request_comment

def create_pull_request_comment(request, options = nil) -> ::Gapic::Operation
def create_pull_request_comment(parent: nil, pull_request_comment: nil) -> ::Gapic::Operation

Creates a pull request comment.

Overloads
def create_pull_request_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_pull_request_comment via a request object, either of type CreatePullRequestCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreatePullRequestCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_pull_request_comment(parent: nil, pull_request_comment: nil) -> ::Gapic::Operation
Pass arguments to create_pull_request_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The pull request in which to create the pull request comment. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • pull_request_comment (::Google::Cloud::SecureSourceManager::V1::PullRequestComment, ::Hash) — Required. The pull request comment to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreatePullRequestCommentRequest.new

# Call the create_pull_request_comment method.
result = client.create_pull_request_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#create_repository

def create_repository(request, options = nil) -> ::Gapic::Operation
def create_repository(parent: nil, repository: nil, repository_id: nil) -> ::Gapic::Operation

Creates a new repository in a given project and location.

The Repository.Instance field is required in the request body for requests using the securesourcemanager.googleapis.com endpoint.

Overloads
def create_repository(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_repository via a request object, either of type CreateRepositoryRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::CreateRepositoryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_repository(parent: nil, repository: nil, repository_id: nil) -> ::Gapic::Operation
Pass arguments to create_repository via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The project in which to create the repository. Values are of the form projects/{project_number}/locations/{location_id}
  • repository (::Google::Cloud::SecureSourceManager::V1::Repository, ::Hash) — Required. The resource being created.
  • repository_id (::String) — Required. The ID to use for the repository, which will become the final component of the repository's resource name. This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::CreateRepositoryRequest.new

# Call the create_repository method.
result = client.create_repository request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_branch_rule

def delete_branch_rule(request, options = nil) -> ::Gapic::Operation
def delete_branch_rule(name: nil, allow_missing: nil) -> ::Gapic::Operation

DeleteBranchRule deletes a branch rule.

Overloads
def delete_branch_rule(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_branch_rule via a request object, either of type DeleteBranchRuleRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteBranchRuleRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_branch_rule(name: nil, allow_missing: nil) -> ::Gapic::Operation
Pass arguments to delete_branch_rule via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String)
  • allow_missing (::Boolean) — Optional. If set to true, and the branch rule is not found, the request will succeed but no action will be taken on the server.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteBranchRuleRequest.new

# Call the delete_branch_rule method.
result = client.delete_branch_rule request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_hook

def delete_hook(request, options = nil) -> ::Gapic::Operation
def delete_hook(name: nil) -> ::Gapic::Operation

Deletes a Hook.

Overloads
def delete_hook(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_hook via a request object, either of type DeleteHookRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteHookRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_hook(name: nil) -> ::Gapic::Operation
Pass arguments to delete_hook via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the hook to delete. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/hooks/{hook_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteHookRequest.new

# Call the delete_hook method.
result = client.delete_hook request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_instance

def delete_instance(request, options = nil) -> ::Gapic::Operation
def delete_instance(name: nil, request_id: nil) -> ::Gapic::Operation

Deletes a single instance.

Overloads
def delete_instance(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_instance via a request object, either of type DeleteInstanceRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteInstanceRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_instance(name: nil, request_id: nil) -> ::Gapic::Operation
Pass arguments to delete_instance via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. Name of the resource.
  • request_id (::String) — Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request.

    For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

    The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteInstanceRequest.new

# Call the delete_instance method.
result = client.delete_instance request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_issue

def delete_issue(request, options = nil) -> ::Gapic::Operation
def delete_issue(name: nil, etag: nil) -> ::Gapic::Operation

Deletes an issue.

Overloads
def delete_issue(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_issue via a request object, either of type DeleteIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_issue(name: nil, etag: nil) -> ::Gapic::Operation
Pass arguments to delete_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. Name of the issue to delete. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}.
  • etag (::String) — Optional. The current etag of the issue. If the etag is provided and does not match the current etag of the issue, deletion will be blocked and an ABORTED error will be returned.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteIssueRequest.new

# Call the delete_issue method.
result = client.delete_issue request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_issue_comment

def delete_issue_comment(request, options = nil) -> ::Gapic::Operation
def delete_issue_comment(name: nil) -> ::Gapic::Operation

Deletes an issue comment.

Overloads
def delete_issue_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_issue_comment via a request object, either of type DeleteIssueCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteIssueCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_issue_comment(name: nil) -> ::Gapic::Operation
Pass arguments to delete_issue_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the issue comment to delete. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}/issueComments/{comment_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteIssueCommentRequest.new

# Call the delete_issue_comment method.
result = client.delete_issue_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_pull_request_comment

def delete_pull_request_comment(request, options = nil) -> ::Gapic::Operation
def delete_pull_request_comment(name: nil) -> ::Gapic::Operation

Deletes a pull request comment.

Overloads
def delete_pull_request_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_pull_request_comment via a request object, either of type DeletePullRequestCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeletePullRequestCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_pull_request_comment(name: nil) -> ::Gapic::Operation
Pass arguments to delete_pull_request_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the pull request comment to delete. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}/pullRequestComments/{comment_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeletePullRequestCommentRequest.new

# Call the delete_pull_request_comment method.
result = client.delete_pull_request_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_repository

def delete_repository(request, options = nil) -> ::Gapic::Operation
def delete_repository(name: nil, allow_missing: nil) -> ::Gapic::Operation

Deletes a Repository.

Overloads
def delete_repository(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_repository via a request object, either of type DeleteRepositoryRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::DeleteRepositoryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_repository(name: nil, allow_missing: nil) -> ::Gapic::Operation
Pass arguments to delete_repository via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. Name of the repository to delete. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}.
  • allow_missing (::Boolean) — Optional. If set to true, and the repository is not found, the request will succeed but no action will be taken on the server.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::DeleteRepositoryRequest.new

# Call the delete_repository method.
result = client.delete_repository request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#fetch_blob

def fetch_blob(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::FetchBlobResponse
def fetch_blob(repository: nil, sha: nil) -> ::Google::Cloud::SecureSourceManager::V1::FetchBlobResponse

Fetches a blob from a repository.

Overloads
def fetch_blob(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::FetchBlobResponse
Pass arguments to fetch_blob via a request object, either of type FetchBlobRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::FetchBlobRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def fetch_blob(repository: nil, sha: nil) -> ::Google::Cloud::SecureSourceManager::V1::FetchBlobResponse
Pass arguments to fetch_blob via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • repository (::String) — Required. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}. Specifies the repository containing the blob.
  • sha (::String) — Required. The SHA-1 hash of the blob to retrieve.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::FetchBlobRequest.new

# Call the fetch_blob method.
result = client.fetch_blob request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::FetchBlobResponse.
p result

#fetch_tree

def fetch_tree(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::TreeEntry>
def fetch_tree(repository: nil, ref: nil, recursive: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::TreeEntry>

Fetches a tree from a repository.

Overloads
def fetch_tree(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::TreeEntry>
Pass arguments to fetch_tree via a request object, either of type FetchTreeRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::FetchTreeRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def fetch_tree(repository: nil, ref: nil, recursive: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::TreeEntry>
Pass arguments to fetch_tree via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • repository (::String) — Required. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}. Specifies the repository to fetch the tree from.
  • ref (::String) — Optional. ref can be a SHA-1 hash, a branch name, or a tag. Specifies which tree to fetch. If not specified, the default branch will be used.
  • recursive (::Boolean) — Optional. If true, include all subfolders and their files in the response. If false, only the immediate children are returned.
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, at most 10,000 items will be returned.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::FetchTreeRequest.new

# Call the fetch_tree method.
result = client.fetch_tree request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::TreeEntry.
  p item
end

#get_branch_rule

def get_branch_rule(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::BranchRule
def get_branch_rule(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::BranchRule

GetBranchRule gets a branch rule.

Overloads
def get_branch_rule(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::BranchRule
Pass arguments to get_branch_rule via a request object, either of type GetBranchRuleRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetBranchRuleRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_branch_rule(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::BranchRule
Pass arguments to get_branch_rule via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the repository to retrieve. The format is projects/{project}/locations/{location}/repositories/{repository}/branchRules/{branch_rule}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetBranchRuleRequest.new

# Call the get_branch_rule method.
result = client.get_branch_rule request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::BranchRule.
p result

#get_hook

def get_hook(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Hook
def get_hook(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Hook

Gets metadata of a hook.

Overloads
def get_hook(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Hook
Pass arguments to get_hook via a request object, either of type GetHookRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetHookRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_hook(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Hook
Pass arguments to get_hook via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the hook to retrieve. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/hooks/{hook_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetHookRequest.new

# Call the get_hook method.
result = client.get_hook request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::Hook.
p result

#get_iam_policy_repo

def get_iam_policy_repo(request, options = nil) -> ::Google::Iam::V1::Policy
def get_iam_policy_repo(resource: nil, options: nil) -> ::Google::Iam::V1::Policy

Get IAM policy for a repository.

Overloads
def get_iam_policy_repo(request, options = nil) -> ::Google::Iam::V1::Policy
Pass arguments to get_iam_policy_repo via a request object, either of type Iam::V1::GetIamPolicyRequest or an equivalent Hash.
Parameters
  • request (::Google::Iam::V1::GetIamPolicyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_iam_policy_repo(resource: nil, options: nil) -> ::Google::Iam::V1::Policy
Pass arguments to get_iam_policy_repo via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • resource (::String) — REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.
  • options (::Google::Iam::V1::GetPolicyOptions, ::Hash) — OPTIONAL: A GetPolicyOptions object for specifying options to GetIamPolicy.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Google::Iam::V1::Policy)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Google::Iam::V1::Policy)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Iam::V1::GetIamPolicyRequest.new

# Call the get_iam_policy_repo method.
result = client.get_iam_policy_repo request

# The returned object is of type Google::Iam::V1::Policy.
p result

#get_instance

def get_instance(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Instance
def get_instance(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Instance

Gets details of a single instance.

Overloads
def get_instance(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Instance
Pass arguments to get_instance via a request object, either of type GetInstanceRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetInstanceRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_instance(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Instance
Pass arguments to get_instance via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the resource.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetInstanceRequest.new

# Call the get_instance method.
result = client.get_instance request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::Instance.
p result

#get_issue

def get_issue(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Issue
def get_issue(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Issue

Gets an issue.

Overloads
def get_issue(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Issue
Pass arguments to get_issue via a request object, either of type GetIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_issue(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Issue
Pass arguments to get_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the issue to retrieve. The format is projects/{project}/locations/{location}/repositories/{repository}/issues/{issue_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetIssueRequest.new

# Call the get_issue method.
result = client.get_issue request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::Issue.
p result

#get_issue_comment

def get_issue_comment(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::IssueComment
def get_issue_comment(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::IssueComment

Gets an issue comment.

Overloads
def get_issue_comment(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::IssueComment
Pass arguments to get_issue_comment via a request object, either of type GetIssueCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetIssueCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_issue_comment(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::IssueComment
Pass arguments to get_issue_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the issue comment to retrieve. The format is projects/{project}/locations/{location}/repositories/{repository}/issues/{issue_id}/issueComments/{comment_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetIssueCommentRequest.new

# Call the get_issue_comment method.
result = client.get_issue_comment request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::IssueComment.
p result

#get_pull_request

def get_pull_request(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequest
def get_pull_request(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequest

Gets a pull request.

Overloads
def get_pull_request(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequest
Pass arguments to get_pull_request via a request object, either of type GetPullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetPullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_pull_request(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequest
Pass arguments to get_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the pull request to retrieve. The format is projects/{project}/locations/{location}/repositories/{repository}/pullRequests/{pull_request}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetPullRequestRequest.new

# Call the get_pull_request method.
result = client.get_pull_request request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::PullRequest.
p result

#get_pull_request_comment

def get_pull_request_comment(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequestComment
def get_pull_request_comment(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequestComment

Gets a pull request comment.

Overloads
def get_pull_request_comment(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequestComment
Pass arguments to get_pull_request_comment via a request object, either of type GetPullRequestCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetPullRequestCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_pull_request_comment(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::PullRequestComment
Pass arguments to get_pull_request_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the pull request comment to retrieve. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}/pullRequestComments/{comment_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetPullRequestCommentRequest.new

# Call the get_pull_request_comment method.
result = client.get_pull_request_comment request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::PullRequestComment.
p result

#get_repository

def get_repository(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Repository
def get_repository(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Repository

Gets metadata of a repository.

Overloads
def get_repository(request, options = nil) -> ::Google::Cloud::SecureSourceManager::V1::Repository
Pass arguments to get_repository via a request object, either of type GetRepositoryRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::GetRepositoryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_repository(name: nil) -> ::Google::Cloud::SecureSourceManager::V1::Repository
Pass arguments to get_repository via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Name of the repository to retrieve. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::GetRepositoryRequest.new

# Call the get_repository method.
result = client.get_repository request

# The returned object is of type Google::Cloud::SecureSourceManager::V1::Repository.
p result

#iam_policy_client

def iam_policy_client() -> Google::Iam::V1::IAMPolicy::Client

Get the associated client for mix-in of the IAMPolicy.

Returns
  • (Google::Iam::V1::IAMPolicy::Client)

#initialize

def initialize() { |config| ... } -> Client

Create a new SecureSourceManager client object.

Yields
  • (config) — Configure the SecureSourceManager client.
Yield Parameter
Returns
  • (Client) — a new instance of Client
Example
# Create a client using the default configuration
client = ::Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a client using a custom configuration
client = ::Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new do |config|
  config.timeout = 10.0
end

#list_branch_rules

def list_branch_rules(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::BranchRule>
def list_branch_rules(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::BranchRule>

ListBranchRules lists branch rules in a given repository.

Overloads
def list_branch_rules(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::BranchRule>
Pass arguments to list_branch_rules via a request object, either of type ListBranchRulesRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListBranchRulesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_branch_rules(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::BranchRule>
Pass arguments to list_branch_rules via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String)
  • page_size (::Integer)
  • page_token (::String)
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListBranchRulesRequest.new

# Call the list_branch_rules method.
result = client.list_branch_rules request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::BranchRule.
  p item
end

#list_hooks

def list_hooks(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Hook>
def list_hooks(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Hook>

Lists hooks in a given repository.

Overloads
def list_hooks(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Hook>
Pass arguments to list_hooks via a request object, either of type ListHooksRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListHooksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_hooks(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Hook>
Pass arguments to list_hooks via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Parent value for ListHooksRequest.
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListHooksRequest.new

# Call the list_hooks method.
result = client.list_hooks request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::Hook.
  p item
end

#list_instances

def list_instances(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Instance>
def list_instances(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Instance>

Lists Instances in a given project and location.

Overloads
def list_instances(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Instance>
Pass arguments to list_instances via a request object, either of type ListInstancesRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListInstancesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_instances(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Instance>
Pass arguments to list_instances via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Parent value for ListInstancesRequest.
  • page_size (::Integer) — Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — A token identifying a page of results the server should return.
  • filter (::String) — Filter for filtering results.
  • order_by (::String) — Hint for how to order the results.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListInstancesRequest.new

# Call the list_instances method.
result = client.list_instances request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::Instance.
  p item
end

#list_issue_comments

def list_issue_comments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::IssueComment>
def list_issue_comments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::IssueComment>

Lists comments in an issue.

Overloads
def list_issue_comments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::IssueComment>
Pass arguments to list_issue_comments via a request object, either of type ListIssueCommentsRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListIssueCommentsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_issue_comments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::IssueComment>
Pass arguments to list_issue_comments via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The issue in which to list the comments. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListIssueCommentsRequest.new

# Call the list_issue_comments method.
result = client.list_issue_comments request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::IssueComment.
  p item
end

#list_issues

def list_issues(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Issue>
def list_issues(parent: nil, page_size: nil, page_token: nil, filter: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Issue>

Lists issues in a repository.

Overloads
def list_issues(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Issue>
Pass arguments to list_issues via a request object, either of type ListIssuesRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListIssuesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_issues(parent: nil, page_size: nil, page_token: nil, filter: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Issue>
Pass arguments to list_issues via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The repository in which to list issues. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
  • filter (::String) — Optional. Used to filter the resulting issues list.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListIssuesRequest.new

# Call the list_issues method.
result = client.list_issues request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::Issue.
  p item
end

#list_pull_request_comments

def list_pull_request_comments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequestComment>
def list_pull_request_comments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequestComment>

Lists pull request comments.

Overloads
def list_pull_request_comments(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequestComment>
Pass arguments to list_pull_request_comments via a request object, either of type ListPullRequestCommentsRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListPullRequestCommentsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_pull_request_comments(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequestComment>
Pass arguments to list_pull_request_comments via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The pull request in which to list pull request comments. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • page_size (::Integer) — Optional. Requested page size. If unspecified, at most 100 pull request comments will be returned. The maximum value is 100; values above 100 will be coerced to 100.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListPullRequestCommentsRequest.new

# Call the list_pull_request_comments method.
result = client.list_pull_request_comments request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::PullRequestComment.
  p item
end

#list_pull_request_file_diffs

def list_pull_request_file_diffs(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::FileDiff>
def list_pull_request_file_diffs(name: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::FileDiff>

Lists a pull request's file diffs.

Overloads
def list_pull_request_file_diffs(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::FileDiff>
Pass arguments to list_pull_request_file_diffs via a request object, either of type ListPullRequestFileDiffsRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListPullRequestFileDiffsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_pull_request_file_diffs(name: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::FileDiff>
Pass arguments to list_pull_request_file_diffs via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. The pull request to list file diffs for. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListPullRequestFileDiffsRequest.new

# Call the list_pull_request_file_diffs method.
result = client.list_pull_request_file_diffs request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::FileDiff.
  p item
end

#list_pull_requests

def list_pull_requests(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequest>
def list_pull_requests(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequest>

Lists pull requests in a repository.

Overloads
def list_pull_requests(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequest>
Pass arguments to list_pull_requests via a request object, either of type ListPullRequestsRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListPullRequestsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_pull_requests(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::PullRequest>
Pass arguments to list_pull_requests via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The repository in which to list pull requests. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — Optional. A token identifying a page of results the server should return.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListPullRequestsRequest.new

# Call the list_pull_requests method.
result = client.list_pull_requests request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::PullRequest.
  p item
end

#list_repositories

def list_repositories(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Repository>
def list_repositories(parent: nil, page_size: nil, page_token: nil, filter: nil, instance: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Repository>

Lists Repositories in a given project and location.

The instance field is required in the query parameter for requests using the securesourcemanager.googleapis.com endpoint.

Overloads
def list_repositories(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Repository>
Pass arguments to list_repositories via a request object, either of type ListRepositoriesRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ListRepositoriesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_repositories(parent: nil, page_size: nil, page_token: nil, filter: nil, instance: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::SecureSourceManager::V1::Repository>
Pass arguments to list_repositories via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Parent value for ListRepositoriesRequest.
  • page_size (::Integer) — Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
  • page_token (::String) — A token identifying a page of results the server should return.
  • filter (::String) — Optional. Filter results.
  • instance (::String) — Optional. The name of the instance in which the repository is hosted, formatted as projects/{project_number}/locations/{location_id}/instances/{instance_id}. When listing repositories via securesourcemanager.googleapis.com, this field is required. When listing repositories via *.sourcemanager.dev, this field is ignored.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ListRepositoriesRequest.new

# Call the list_repositories method.
result = client.list_repositories request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::SecureSourceManager::V1::Repository.
  p item
end

#location_client

def location_client() -> Google::Cloud::Location::Locations::Client

Get the associated client for mix-in of the Locations.

Returns
  • (Google::Cloud::Location::Locations::Client)

#logger

def logger() -> Logger

The logger used for request/response debug logging.

Returns
  • (Logger)

#merge_pull_request

def merge_pull_request(request, options = nil) -> ::Gapic::Operation
def merge_pull_request(name: nil) -> ::Gapic::Operation

Merges a pull request.

Overloads
def merge_pull_request(request, options = nil) -> ::Gapic::Operation
Pass arguments to merge_pull_request via a request object, either of type MergePullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::MergePullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def merge_pull_request(name: nil) -> ::Gapic::Operation
Pass arguments to merge_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The pull request to merge. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::MergePullRequestRequest.new

# Call the merge_pull_request method.
result = client.merge_pull_request request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#open_issue

def open_issue(request, options = nil) -> ::Gapic::Operation
def open_issue(name: nil, etag: nil) -> ::Gapic::Operation

Opens an issue.

Overloads
def open_issue(request, options = nil) -> ::Gapic::Operation
Pass arguments to open_issue via a request object, either of type OpenIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::OpenIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def open_issue(name: nil, etag: nil) -> ::Gapic::Operation
Pass arguments to open_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • name (::String) — Required. Name of the issue to open. The format is projects/{project_number}/locations/{location_id}/repositories/{repository_id}/issues/{issue_id}.
  • etag (::String) — Optional. The current etag of the issue. If the etag is provided and does not match the current etag of the issue, opening will be blocked and an ABORTED error will be returned.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::OpenIssueRequest.new

# Call the open_issue method.
result = client.open_issue request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#open_pull_request

def open_pull_request(request, options = nil) -> ::Gapic::Operation
def open_pull_request(name: nil) -> ::Gapic::Operation

Opens a pull request.

Overloads
def open_pull_request(request, options = nil) -> ::Gapic::Operation
Pass arguments to open_pull_request via a request object, either of type OpenPullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::OpenPullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def open_pull_request(name: nil) -> ::Gapic::Operation
Pass arguments to open_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The pull request to open. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::OpenPullRequestRequest.new

# Call the open_pull_request method.
result = client.open_pull_request request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#operations_client

def operations_client() -> ::Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Operations

Get the associated client for long-running operations.

#resolve_pull_request_comments

def resolve_pull_request_comments(request, options = nil) -> ::Gapic::Operation
def resolve_pull_request_comments(parent: nil, names: nil, auto_fill: nil) -> ::Gapic::Operation

Resolves pull request comments.

Overloads
def resolve_pull_request_comments(request, options = nil) -> ::Gapic::Operation
Pass arguments to resolve_pull_request_comments via a request object, either of type ResolvePullRequestCommentsRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::ResolvePullRequestCommentsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def resolve_pull_request_comments(parent: nil, names: nil, auto_fill: nil) -> ::Gapic::Operation
Pass arguments to resolve_pull_request_comments via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The pull request in which to resolve the pull request comments. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • names (::Array<::String>) — Required. The names of the pull request comments to resolve. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}/pullRequestComments/{comment_id} Only comments from the same threads are allowed in the same request.
  • auto_fill (::Boolean) — Optional. If set, at least one comment in a thread is required, rest of the comments in the same thread will be automatically updated to resolved. If unset, all comments in the same thread need be present.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::ResolvePullRequestCommentsRequest.new

# Call the resolve_pull_request_comments method.
result = client.resolve_pull_request_comments request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#set_iam_policy_repo

def set_iam_policy_repo(request, options = nil) -> ::Google::Iam::V1::Policy
def set_iam_policy_repo(resource: nil, policy: nil, update_mask: nil) -> ::Google::Iam::V1::Policy

Set IAM policy on a repository.

Overloads
def set_iam_policy_repo(request, options = nil) -> ::Google::Iam::V1::Policy
Pass arguments to set_iam_policy_repo via a request object, either of type Iam::V1::SetIamPolicyRequest or an equivalent Hash.
Parameters
  • request (::Google::Iam::V1::SetIamPolicyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def set_iam_policy_repo(resource: nil, policy: nil, update_mask: nil) -> ::Google::Iam::V1::Policy
Pass arguments to set_iam_policy_repo via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • resource (::String) — REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.
  • policy (::Google::Iam::V1::Policy, ::Hash) — REQUIRED: The complete policy to be applied to the resource. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only the fields in the mask will be modified. If no mask is provided, the following default mask is used:

    paths: "bindings, etag"

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Google::Iam::V1::Policy)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Google::Iam::V1::Policy)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Iam::V1::SetIamPolicyRequest.new

# Call the set_iam_policy_repo method.
result = client.set_iam_policy_repo request

# The returned object is of type Google::Iam::V1::Policy.
p result

#test_iam_permissions_repo

def test_iam_permissions_repo(request, options = nil) -> ::Google::Iam::V1::TestIamPermissionsResponse
def test_iam_permissions_repo(resource: nil, permissions: nil) -> ::Google::Iam::V1::TestIamPermissionsResponse

Test IAM permissions on a repository. IAM permission checks are not required on this method.

Overloads
def test_iam_permissions_repo(request, options = nil) -> ::Google::Iam::V1::TestIamPermissionsResponse
Pass arguments to test_iam_permissions_repo via a request object, either of type Iam::V1::TestIamPermissionsRequest or an equivalent Hash.
Parameters
  • request (::Google::Iam::V1::TestIamPermissionsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def test_iam_permissions_repo(resource: nil, permissions: nil) -> ::Google::Iam::V1::TestIamPermissionsResponse
Pass arguments to test_iam_permissions_repo via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • resource (::String) — REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.
  • permissions (::Array<::String>) — The set of permissions to check for the resource. Permissions with wildcards (such as '' or 'storage.') are not allowed. For more information see IAM Overview.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Google::Iam::V1::TestIamPermissionsResponse)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Google::Iam::V1::TestIamPermissionsResponse)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Iam::V1::TestIamPermissionsRequest.new

# Call the test_iam_permissions_repo method.
result = client.test_iam_permissions_repo request

# The returned object is of type Google::Iam::V1::TestIamPermissionsResponse.
p result

#universe_domain

def universe_domain() -> String

The effective universe domain

Returns
  • (String)

#unresolve_pull_request_comments

def unresolve_pull_request_comments(request, options = nil) -> ::Gapic::Operation
def unresolve_pull_request_comments(parent: nil, names: nil, auto_fill: nil) -> ::Gapic::Operation

Unresolves pull request comment.

Overloads
def unresolve_pull_request_comments(request, options = nil) -> ::Gapic::Operation
Pass arguments to unresolve_pull_request_comments via a request object, either of type UnresolvePullRequestCommentsRequest or an equivalent Hash.
Parameters
def unresolve_pull_request_comments(parent: nil, names: nil, auto_fill: nil) -> ::Gapic::Operation
Pass arguments to unresolve_pull_request_comments via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The pull request in which to resolve the pull request comments. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}
  • names (::Array<::String>) — Required. The names of the pull request comments to unresolve. Format: projects/{project_number}/locations/{location_id}/repositories/{repository_id}/pullRequests/{pull_request_id}/pullRequestComments/{comment_id} Only comments from the same threads are allowed in the same request.
  • auto_fill (::Boolean) — Optional. If set, at least one comment in a thread is required, rest of the comments in the same thread will be automatically updated to unresolved. If unset, all comments in the same thread need be present.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UnresolvePullRequestCommentsRequest.new

# Call the unresolve_pull_request_comments method.
result = client.unresolve_pull_request_comments request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_branch_rule

def update_branch_rule(request, options = nil) -> ::Gapic::Operation
def update_branch_rule(branch_rule: nil, validate_only: nil, update_mask: nil) -> ::Gapic::Operation

UpdateBranchRule updates a branch rule.

Overloads
def update_branch_rule(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_branch_rule via a request object, either of type UpdateBranchRuleRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdateBranchRuleRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_branch_rule(branch_rule: nil, validate_only: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_branch_rule via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • branch_rule (::Google::Cloud::SecureSourceManager::V1::BranchRule, ::Hash)
  • validate_only (::Boolean) — Optional. If set, validate the request and preview the review, but do not actually post it. (https://google.aip.dev/163, for declarative friendly)
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. Field mask is used to specify the fields to be overwritten in the branchRule resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The special value "*" means full replacement.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdateBranchRuleRequest.new

# Call the update_branch_rule method.
result = client.update_branch_rule request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_hook

def update_hook(request, options = nil) -> ::Gapic::Operation
def update_hook(update_mask: nil, hook: nil) -> ::Gapic::Operation

Updates the metadata of a hook.

Overloads
def update_hook(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_hook via a request object, either of type UpdateHookRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdateHookRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_hook(update_mask: nil, hook: nil) -> ::Gapic::Operation
Pass arguments to update_hook via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. Field mask is used to specify the fields to be overwritten in the hook resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The special value "*" means full replacement.
  • hook (::Google::Cloud::SecureSourceManager::V1::Hook, ::Hash) — Required. The hook being updated.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdateHookRequest.new

# Call the update_hook method.
result = client.update_hook request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_issue

def update_issue(request, options = nil) -> ::Gapic::Operation
def update_issue(issue: nil, update_mask: nil) -> ::Gapic::Operation

Updates a issue.

Overloads
def update_issue(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_issue via a request object, either of type UpdateIssueRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdateIssueRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_issue(issue: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_issue via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • issue (::Google::Cloud::SecureSourceManager::V1::Issue, ::Hash) — Required. The issue to update.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Optional. Field mask is used to specify the fields to be overwritten in the issue resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The special value "*" means full replacement.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdateIssueRequest.new

# Call the update_issue method.
result = client.update_issue request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_issue_comment

def update_issue_comment(request, options = nil) -> ::Gapic::Operation
def update_issue_comment(issue_comment: nil, update_mask: nil) -> ::Gapic::Operation

Updates an issue comment.

Overloads
def update_issue_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_issue_comment via a request object, either of type UpdateIssueCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdateIssueCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_issue_comment(issue_comment: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_issue_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • issue_comment (::Google::Cloud::SecureSourceManager::V1::IssueComment, ::Hash) — Required. The issue comment to update.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Optional. Field mask is used to specify the fields to be overwritten in the issue comment resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The special value "*" means full replacement.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdateIssueCommentRequest.new

# Call the update_issue_comment method.
result = client.update_issue_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_pull_request

def update_pull_request(request, options = nil) -> ::Gapic::Operation
def update_pull_request(pull_request: nil, update_mask: nil) -> ::Gapic::Operation

Updates a pull request.

Overloads
def update_pull_request(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_pull_request via a request object, either of type UpdatePullRequestRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdatePullRequestRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_pull_request(pull_request: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_pull_request via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • pull_request (::Google::Cloud::SecureSourceManager::V1::PullRequest, ::Hash) — Required. The pull request to update.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Optional. Field mask is used to specify the fields to be overwritten in the pull request resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The special value "*" means full replacement.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdatePullRequestRequest.new

# Call the update_pull_request method.
result = client.update_pull_request request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_pull_request_comment

def update_pull_request_comment(request, options = nil) -> ::Gapic::Operation
def update_pull_request_comment(pull_request_comment: nil, update_mask: nil) -> ::Gapic::Operation

Updates a pull request comment.

Overloads
def update_pull_request_comment(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_pull_request_comment via a request object, either of type UpdatePullRequestCommentRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdatePullRequestCommentRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_pull_request_comment(pull_request_comment: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_pull_request_comment via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdatePullRequestCommentRequest.new

# Call the update_pull_request_comment method.
result = client.update_pull_request_comment request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#update_repository

def update_repository(request, options = nil) -> ::Gapic::Operation
def update_repository(update_mask: nil, repository: nil, validate_only: nil) -> ::Gapic::Operation

Updates the metadata of a repository.

Overloads
def update_repository(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_repository via a request object, either of type UpdateRepositoryRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::SecureSourceManager::V1::UpdateRepositoryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_repository(update_mask: nil, repository: nil, validate_only: nil) -> ::Gapic::Operation
Pass arguments to update_repository via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Optional. Field mask is used to specify the fields to be overwritten in the repository resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
  • repository (::Google::Cloud::SecureSourceManager::V1::Repository, ::Hash) — Required. The repository being updated.
  • validate_only (::Boolean) — Optional. False by default. If set to true, the request is validated and the user is provided with an expected result, but no actual change is made.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/secure_source_manager/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::SecureSourceManager::V1::SecureSourceManager::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::SecureSourceManager::V1::UpdateRepositoryRequest.new

# Call the update_repository method.
result = client.update_repository request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end