Skip to content
This repository was archived by the owner on Oct 27, 2022. It is now read-only.

Latest commit

 

History

History
58 lines (39 loc) · 1.8 KB

File metadata and controls

58 lines (39 loc) · 1.8 KB

VSphereAutomation::VAPI::VcenterActivationApi

All URIs are relative to https://<vcenter>/rest

Method HTTP request Description
cancel POST /com/vmware/vapi/vcenter/activation/id:{activation_id}?~action=cancel Sends a request to cancel the task associated with the provided {@param.name activationId}.

cancel

cancel(activation_id)

Sends a request to cancel the task associated with the provided {@param.name activationId}.

Example

# load the gem
require 'vsphere-automation-vapi'
# setup authorization
VSphereAutomation::Configuration.new.tap do |config|
  # Configure API key authorization: api_key
  config.api_key['vmware-api-session-id'] = 'YOUR API KEY'
  # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
  #config.api_key_prefix['vmware-api-session-id'] = 'Bearer'
end

api_instance = VSphereAutomation::VAPI::VcenterActivationApi.new
activation_id = 'activation_id_example' # String | the {@param.name activationId} associated with a vCenter Server task to be canceled.

begin
  #Sends a request to cancel the task associated with the provided {@param.name activationId}.
  api_instance.cancel(activation_id)
rescue VSphereAutomation::ApiError => e
  puts "Exception when calling VcenterActivationApi->cancel: #{e}"
end

Parameters

Name Type Description Notes
activation_id String the {@param.name activationId} associated with a vCenter Server task to be canceled.

Return type

nil (empty response body)

Authorization

api_key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json