Class: BatchlyApi::AddAwsAccountRequest

Inherits:
Object
  • Object
show all
Defined in:
lib/batchly_api/models/add_aws_account_request.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method_name) ⇒ Object



24
25
26
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 24

def method_missing (method_name)
  puts "there's no method called '#{method_name}'"
end

Instance Attribute Details

#access_keyString

AWS Access key with “IAMFullAccess” permissions

Returns:

  • (String)


12
13
14
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 12

def access_key
  @access_key
end

#base_regionString

Default aws region for storing configuration and processors

Value should equal aws region identifier. e.g. us-east-1, ap-southeast-2

Returns:

  • (String)


21
22
23
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 21

def base_region
  @base_region
end

#nameString

A name to identify the account

Returns:

  • (String)


8
9
10
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 8

def name
  @name
end

#secret_keyString

AWS Secret key of the corresponding Access Key

Returns:

  • (String)


16
17
18
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 16

def secret_key
  @secret_key
end

Instance Method Details

#key_mapObject

Defines the key map for json serialization



35
36
37
38
39
40
41
42
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 35

def key_map
  hash = {}
  hash['Name'] = self.name
  hash['AccessKey'] = self.access_key
  hash['SecretKey'] = self.secret_key
  hash['BaseRegion'] = self.base_region
  hash
end

#to_jsonObject

Creates JSON of the curent object



29
30
31
32
# File 'lib/batchly_api/models/add_aws_account_request.rb', line 29

def to_json
  hash = self.key_map()
  hash.to_json
end