Sha256: eb5bf9bbe39803f76752aad8b8ab4c48225de2c994a60791167ef347b33f46f6

Contents?: true

Size: 366 Bytes

Versions: 4

Compression:

Stored size: 366 Bytes

Contents

# frozen_string_literal: true

module NovaposhtaApi
  module Resources
    class TrackingDocumentResource < Resource
      def track(number)
        response = post(
          'TrackingDocument/getStatusDocuments', documents: [{document_number: number}]
        )

        NovaposhtaApi::Models::TrackingDocument.extract_single(response)
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
novaposhta_api-0.1.7 lib/novaposhta_api/resources/tracking_document_resource.rb
novaposhta_api-0.1.5 lib/novaposhta_api/resources/tracking_document_resource.rb
novaposhta_api-0.1.4 lib/novaposhta_api/resources/tracking_document_resource.rb
novaposhta_api-0.1.3 lib/novaposhta_api/resources/tracking_document_resource.rb