Sha256: 91ea234a1a84e89c791aa4e74e38a788ec46e07974c3eaff531cec17d30487eb

Contents?: true

Size: 1.25 KB

Versions: 12

Compression:

Stored size: 1.25 KB

Contents

module GnipApi
  class Endpoints
    class << self
      def powertrack_rules label
        URI("https://gnip-api.twitter.com/rules/powertrack/accounts/#{account}/publishers/twitter/#{label}.json")
      end

      def powertrack_stream label
        URI("https://gnip-stream.twitter.com/stream/powertrack/accounts/#{account}/publishers/twitter/#{label}.json")
      end

      def powertrack_rule_validator label
        URI("https://gnip-api.twitter.com/rules/powertrack/accounts/#{account}/publishers/twitter/#{label}/validation.json")
      end

      def powertrack_stream_replay label
        URI("https://gnip-stream.twitter.com/replay/powertrack/accounts/#{account}/publishers/twitter/#{label}.json")
      end

      def powertrack_rule_replay label
        URI("https://gnip-api.twitter.com/rules/powertrack-replay/accounts/#{account}/publishers/twitter/#{label}.json")
      end

      def search_activities label
        URI("https://gnip-api.twitter.com/search/fullarchive/accounts/#{account}/#{label}.json")
      end
      
      def search_counts label
        URI("https://gnip-api.twitter.com/search/fullarchive/accounts/#{account}/#{label}/counts.json")
      end

      private
      def account
        GnipApi.configuration.account
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
gnip_api-1.2.0 lib/gnip_api/endpoints.rb
gnip_api-1.1.3 lib/gnip_api/endpoints.rb
gnip_api-1.1.2 lib/gnip_api/endpoints.rb
gnip_api-1.1.1 lib/gnip_api/endpoints.rb
gnip_api-1.1.0 lib/gnip_api/endpoints.rb
gnip_api-1.0.6 lib/gnip_api/endpoints.rb
gnip_api-1.0.5 lib/gnip_api/endpoints.rb
gnip_api-1.0.4 lib/gnip_api/endpoints.rb
gnip_api-1.0.3 lib/gnip_api/endpoints.rb
gnip_api-1.0.2 lib/gnip_api/endpoints.rb
gnip_api-1.0.1 lib/gnip_api/endpoints.rb
gnip_api-1.0.0 lib/gnip_api/endpoints.rb