app/services/external_apis/re3data_service.rb
# Queries the re3data API for the specified repository
Queries the re3data API for the specified repository
Queries the re3data API for the specified repository
def query_re3data_repository(repo_id:)
        return [] unless repo_id.present?
        target = "#{api_base_url}#{repository_path}#{repo_id}"
        resp = http_get(uri: target, additional_headers: {},
                        debug: false)
        unless resp.present? && resp.code == 200
          handle_http_failure(method: "re3data repository #{repo_id}", http_response: resp)
          return []
        end
        Nokogiri.XML(resp.body, nil, "utf8")
      end
def query_re3data_repository ( repo_id : ) return [ ] unless repo_id . present? target = "#{api_base_url}#{repository_path}#{repo_id}" resp = http_get ( uri : target , additional_headers : { } , debug : false ) unless resp . present? && resp . code == 200 handle_http_failure ( method : "re3data repository #{repo_id}" , http_response : resp ) return [ ] end Nokogiri . XML ( resp . body , nil , "utf8" ) end
Queries the re3data API for the specified repository
Queries the re3data API for the specified repository
# Call the ROR API and log any errors
repo_id