public
Description: Ruby library for utilizing Gnip services.
Homepage: http://gnipcentral.com
Clone URL: git://github.com/gnip/gnip-ruby.git
gnip-ruby / README
100644 145 lines (104 sloc) 4.51 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
NAME
  gnip
 
SYNOPSIS
  gnip (config|ping|clock_drift|encode|decode|version|publisher|activity|notification|filter) [options]+
 
DESCRIPTION
  gnip.rb is *the* clinically proven, most effective way, to keep your ruby
  codez on the pulse of the freaking interwebs. gnip.rb slings rest-fu
  around like mr.t slings suckas while rocking out to deep-house and pouring
  wine for the ladeez. gnip.rb brings you power and speed with a silkly
  smooth mixture of equal parts restclient, nokogiri, tagz, and threadify.
  sit back and let gnip.rb bring the very tastiest portions of the tubes
  down onto your very own hard drive for your dining pleasure.
  
  we have what you are looking for.
 
PARAMETERS
  --username=[username], -U (0 ~> username)
  --password=[password], -P (0 ~> password)
  --scope=[scope], -S (0 ~> scope=gnip)
  --name=[name], -N (0 ~> name)
  --ago=[ago], -a (0 ~> integer(ago))
  --thru=[thru], -t (0 ~> thru)
  --bucket=[bucket], -b (0 ~> bucket)
  --filter=[filter], -f (0 ~> filter)
  --style=[style], -s (0 ~> style)
  --force=[force] (0 ~> boolean(force))
  --log=[log], -l (0 ~> log)
  --input=[input], -i (0 ~> input)
  --help, -h
 
AUTHOR
  ara.t.howard@gmail.com
 
EXAMPLES
  @quick
    . sup on digg recently?
        gnip notification digg --ago=30 --thru=now
  
    . and twitter right now?
        gnip notification twitter
  
    . stalk someone on tumblr
        gnip filter rule create tumblr catch-him-in-the-act actor:boyfriend
        gnip activity digg --filter=catch-him-in-the-act --bucket=all
  
  @setup
    . dump the current gnip config
        gnip config
  
    . create a ~/.gnip.yml config file
        gnip config generate
    
    . ping gnip to verify your config
        gnip ping
  
    . show gnip clock shift from your local time
        gnip clock_drift
  
  @publisher
    . list gnip publishers
        gnip publisher list
  
    . list publishers in the /my scope
        gnip publisher list --scope=my
  
    . create a publisher name 'publisher-name' in the /my scope with actor and keyword rules
        gnip publisher create my-publisher actor keyword --scope=my
  
    . show a publisher by name
        gnip publisher show my-publisher
  
    . delete a publisher in the /my scope
        gnip publisher delete my-publisher --scope=my
  
  
  @activity | @notification
    . list the activity stream of a publisher
        gnip notification stream digg
  
    . list the activity of a publisher
        gnip notification list digg
  
    . list the activity of a publisher 10 minutes ago
        gnip notification list digg --ago=10
  
    . list all activity of a publisher starting 60-10 minutes (parallel requests)
        gnip notification list digg --ago=60 --thru=10
  
    . list all possible activity of a publisher
        gnip notification list digg --bucket=all
  
    . list the filtered activity of a publisher
        gnip activity list digg --filter=my-filter-name --ago=60 --thru=42
  
  @filter
    . create a publisher filter for two actors
        gnip filter create digg my-filter-name --full_data=true actor:mohadata actor:livefree12
  
    . create a publisher filter from a file full of many rules (same format as command-line, one per line)
        gnip filter create digg my-filter-name --input=file-full-of-rules.txt
  
    . append rules to an existing publisher filter
        gnip filter rule create digg my-filter-name actor:foobar actor:barfoo
  
    . append rules to an existing publisher filter in bulk
        gnip filter rule create digg my-filter-name --input=input
  
    . list a specific rule for a publisher's filter
        gnip filter rule list digg my-filter-name actor:livefree12
  
    . delete a specific rule from an existing publisher filter
        gnip filter rule delete digg my-filter-name actor:barfoo
  
    . list your filters on a publisher
        gnip filter list digg
  
  @publish
    . push a yml activity to a publisher
        gnip activity publish my-publisher ./sample/data/activity.yml --scope=my
  
    . scan for what you just posted (roughly)
        gnip activity list my-publisher --scope=my --ago=2 --thru=now
  
  @utility
    . encode data
        gnip encode 'some content'
  
    . decode data
        gnip encode 'some content' | gnip decode -
  
    . round trip data
        echo 'some content' | gnip encode - | gnip decode -
 
LIBRARY
  see this program, samples/*, and test/**/**, for usage
 
URI
  http://gnip.com
 
INSTALL
  $sudo gem install gnip