Class: Datarobot::AiApi::Deployment

Inherits:
Object
  • Object
show all
Defined in:
lib/datarobot/ai_api/deployment.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Deployment

Takes a response body from the API. Will set all deployment attributes from the response body

Parameters:

  • options (Hash) (defaults to: {})

    A parsed response body



10
11
12
13
14
15
16
17
# File 'lib/datarobot/ai_api/deployment.rb', line 10

def initialize(options={})
  options = options.collect{|k,v| [k.to_s, v]}.to_h

  @datarobotKey ||= options.dig("datarobot-key")
  @deploymentId ||= options.dig("deploymentId")
  @url ||= options.dig("url")
  @target ||= options.dig("target")
end

Instance Attribute Details

#datarobotKeyObject (readonly)

Returns the value of attribute datarobotKey.



4
5
6
# File 'lib/datarobot/ai_api/deployment.rb', line 4

def datarobotKey
  @datarobotKey
end

#deployment_idObject (readonly)

Returns the value of attribute deployment_id.



4
5
6
# File 'lib/datarobot/ai_api/deployment.rb', line 4

def deployment_id
  @deployment_id
end

#targetObject (readonly)

Returns the value of attribute target.



4
5
6
# File 'lib/datarobot/ai_api/deployment.rb', line 4

def target
  @target
end

#urlObject (readonly)

Returns the value of attribute url.



4
5
6
# File 'lib/datarobot/ai_api/deployment.rb', line 4

def url
  @url
end