Sha256: 97a3b762a0a7c16e9920275a7468bac32b5ac97a7590a5e7e2922bbc5d941aef

Contents?: true

Size: 553 Bytes

Versions: 1

Compression:

Stored size: 553 Bytes

Contents

# frozen_string_literal: true

module Tikkie
  module Api
    module Resources
      # Error object in non-successful responses.
      class Error
        attr_reader :data

        def initialize(data)
          @data = data
        end

        def code
          data[:code]
        end

        def message
          data[:message]
        end

        def reference
          data[:reference]
        end

        def status
          data[:status]
        end

        def trace_id
          data[:traceId]
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
tikkie-api-2.0.0 lib/tikkie/api/resources/error.rb