class Orchestrate::API::Response

Transforms the HTTParty response into a structure that provides ready access to relevant orchestrate.io response data.

Attributes

body[R]
header[R]

Public Class Methods

new(partay) click to toggle source

Creates Header and ResponseBody objects from the HTTParty response. Let's Partay!

# File api/lib/orchestrate_api/response.rb, line 16
def initialize(partay)
  @success = partay.success?
  @header = Header.new partay.headers, partay.code, partay.msg
  @body = ResponseBody.new partay.body
end

Public Instance Methods

success?() click to toggle source

Returns the value of HTTParty.success?

# File api/lib/orchestrate_api/response.rb, line 23
def success?
  @success
end