Sha256: bfdf7928b3cae6ea40db2f3934500b86c2efe6efcc2e1dc38d8817ccd89140a5
Contents?: true
Size: 817 Bytes
Versions: 10
Compression:
Stored size: 817 Bytes
Contents
# typed: strict # frozen_string_literal: true require_relative "data_response" module WhatsappSdk module Api module Responses class ErrorResponse < DataResponse sig { returns(T.nilable(T::Boolean)) } attr_accessor :error sig { returns(T.nilable(Integer)) } attr_accessor :status sig { params(response: T::Hash[T.untyped, T.untyped]).void } def initialize(response:) @error = response["error"] @status = response["status"] super(response) end sig { override.params(response: T::Hash[T.untyped, T.untyped]).returns(T.nilable(ErrorResponse)) } def self.build_from_response(response:) return unless response["error"] new(response: response) end end end end end
Version data entries
10 entries across 10 versions & 1 rubygems