Class: Ovh::Api::Api::OvhCloudConnect::Migration
- Inherits:
-
Object
- Object
- Ovh::Api::Api::OvhCloudConnect::Migration
- Defined in:
- lib/ovh-api/api/ovh_cloud_connect/migration.rb
Instance Method Summary collapse
- #create(service_name:) ⇒ Object
-
#initialize(connection) ⇒ Migration
constructor
A new instance of Migration.
- #list(service_name:) ⇒ Object
Constructor Details
#initialize(connection) ⇒ Migration
Returns a new instance of Migration.
6 7 8 |
# File 'lib/ovh-api/api/ovh_cloud_connect/migration.rb', line 6 def initialize(connection) @connection = connection end |
Instance Method Details
#create(service_name:) ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/ovh-api/api/ovh_cloud_connect/migration.rb', line 10 def create(service_name:) raise ArgumentError, 'service_name is required' if service_name.nil? @connection.call( :POST, '/ovhCloudConnect/{serviceName}/migration' .gsub('{serviceName}', ERB::Util.url_encode(service_name.to_s)), type: nil, auth: [] ) end |
#list(service_name:) ⇒ Object
22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/ovh-api/api/ovh_cloud_connect/migration.rb', line 22 def list(service_name:) raise ArgumentError, 'service_name is required' if service_name.nil? @connection.call( :GET, '/ovhCloudConnect/{serviceName}/migration' .gsub('{serviceName}', ERB::Util.url_encode(service_name.to_s)), type: nil, auth: [] ) end |