Skip to content

Commit

Permalink
Update Twitter documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
senorprogrammer committed Aug 17, 2018
1 parent eb4f995 commit 3681bea
Show file tree
Hide file tree
Showing 10 changed files with 124 additions and 36 deletions.
9 changes: 7 additions & 2 deletions _site/content/modules/twitter.md
Expand Up @@ -11,8 +11,13 @@ Connects to the Twitter API and displays a single user's tweets.

NOTE: This only works for single-application developer accounts for now.

To get your bearer token, please see:
https://github.com/Trinergy/twitter_bearer_token
To make this work, you'll need a couple of things:

1. A [Twitter developer account](https://developer.twitter.com/content/developer-twitter/en.html)
2. A [Twitter bearer token](https://developer.twitter.com/en/docs/basics/authentication/overview/application-only).

Once you have your developer account, a relatively painless way to get a
bearer token is to use [TBT](https://github.com/Trinergy/twitter_bearer_token).

## Source Code

Expand Down
2 changes: 1 addition & 1 deletion docs/index.json
Expand Up @@ -277,7 +277,7 @@
"title": "Twitter",
"tags": [],
"description": "",
"content": " Added in v0.2.0.\nConnects to the Twitter API and displays a single user\u0026rsquo;s tweets.\nNOTE: This only works for single-application developer accounts for now.\nSource Code wtf/twitter/ Configuration twitter:bearerToken:\u0026#34;3276d7155dd9ee27b8b14f8743a408a9\u0026#34;enabled:trueposition:top:0left:1height:1width:1refreshInterval:20000 Attributes bearerToken Value: Your Twitter single-application Bearer Token\nenabled Whether or not this module is executed and if its data displayed onscreen. Values: true, false.\nposition Defines where in the grid this module\u0026rsquo;s widget will be displayed. refreshInterval How often, in seconds, this module will update its data. Values: Any positive integer, 0..n.\n"
"content": " Added in v0.2.0.\nConnects to the Twitter API and displays a single user\u0026rsquo;s tweets.\nNOTE: This only works for single-application developer accounts for now.\nTo get your bearer token, please see: https://github.com/Trinergy/twitter_bearer_token\nSource Code wtf/twitter/ Configuration twitter:bearerToken:\u0026#34;3276d7155dd9ee27b8b14f8743a408a9\u0026#34;enabled:trueposition:top:0left:1height:1width:1refreshInterval:20000 Attributes bearerToken Value: Your Twitter single-application Bearer Token\nenabled Whether or not this module is executed and if its data displayed onscreen. Values: true, false.\nposition Defines where in the grid this module\u0026rsquo;s widget will be displayed. refreshInterval How often, in seconds, this module will update its data. Values: Any positive integer, 0..n.\n"
},
{
"uri": "https://wtfutil.com/modules/weather_services/",
Expand Down
3 changes: 2 additions & 1 deletion docs/index.xml
Expand Up @@ -475,9 +475,10 @@ board The name of the Trello board. enabled Determines whether or not this modul
<description>Added in v0.2.0.
Connects to the Twitter API and displays a single user&amp;rsquo;s tweets.
NOTE: This only works for single-application developer accounts for now.
To get your bearer token, please see: https://github.com/Trinergy/twitter_bearer_token
Source Code wtf/twitter/ Configuration twitter:bearerToken:&amp;#34;3276d7155dd9ee27b8b14f8743a408a9&amp;#34;enabled:trueposition:top:0left:1height:1width:1refreshInterval:20000 Attributes bearerToken Value: Your Twitter single-application Bearer Token
enabled Whether or not this module is executed and if its data displayed onscreen. Values: true, false.
position Defines where in the grid this module&amp;rsquo;s widget will be displayed. refreshInterval How often, in seconds, this module will update its data.</description>
position Defines where in the grid this module&amp;rsquo;s widget will be displayed.</description>
</item>

<item>
Expand Down
96 changes: 96 additions & 0 deletions docs/modules/cryptocurrencies/bittrex/index.html
Expand Up @@ -141,6 +141,36 @@
CmdRunner
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/cryptocurrencies/" class="dd-item parent haschildren
">
<div>
<a href="/modules/cryptocurrencies/">Crypo Currencies</a>
<i class="fa fa-angle-down fa-lg category-icon"></i><i class="fa fa-circle-thin read-icon"></i>
</div>
<ul>
<li data-nav-id="/modules/cryptocurrencies/bittrex/" class="dd-item active">
<div>
<a href="/modules/cryptocurrencies/bittrex/">
Bittrex
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/cryptocurrencies/blockfolio/" class="dd-item">
<div>
<a href="/modules/cryptocurrencies/blockfolio/">
Blockfolio
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/cryptocurrencies/cryptolive/" class="dd-item">
<div>
<a href="/modules/cryptocurrencies/cryptolive/">
CryptoLive
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
</ul>
</li>
<li data-nav-id="/modules/gerrit/" class="dd-item">
<div>
Expand Down Expand Up @@ -176,13 +206,57 @@
Gitter
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/google/" class="dd-item haschildren
">
<div>
<a href="/modules/google/">Google Apps</a><i class="fa fa-angle-right fa-lg category-icon"></i><i class="fa fa-circle-thin read-icon"></i>
</div>
<ul>
<li data-nav-id="/modules/google/gcal/" class="dd-item">
<div>
<a href="/modules/google/gcal/">
Google Calendar
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/google/gspreadsheet/" class="dd-item">
<div>
<a href="/modules/google/gspreadsheet/">
Google Spreadsheets
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
</ul>
</li>
<li data-nav-id="/modules/hackernews/" class="dd-item">
<div>
<a href="/modules/hackernews/">
Hacker News
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/ipaddress/" class="dd-item haschildren
">
<div>
<a href="/modules/ipaddress/">IP Addresses</a><i class="fa fa-angle-right fa-lg category-icon"></i><i class="fa fa-circle-thin read-icon"></i>
</div>
<ul>
<li data-nav-id="/modules/ipaddress/ipapi/" class="dd-item">
<div>
<a href="/modules/ipaddress/ipapi/">
IP-API
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/ipaddress/ipinfo/" class="dd-item">
<div>
<a href="/modules/ipaddress/ipinfo/">
IPInfo
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
</ul>
</li>
<li data-nav-id="/modules/jenkins/" class="dd-item">
<div>
Expand Down Expand Up @@ -274,6 +348,28 @@
Twitter
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/weather_services/" class="dd-item haschildren
">
<div>
<a href="/modules/weather_services/">Weather Services</a><i class="fa fa-angle-right fa-lg category-icon"></i><i class="fa fa-circle-thin read-icon"></i>
</div>
<ul>
<li data-nav-id="/modules/weather_services/prettyweather/" class="dd-item">
<div>
<a href="/modules/weather_services/prettyweather/">
Pretty Weather
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
<li data-nav-id="/modules/weather_services/weather/" class="dd-item">
<div>
<a href="/modules/weather_services/weather/">
Weather
</a><i class="fa fa-circle-thin read-icon"></i>
</div>
</li>
</ul>
</li>
<li data-nav-id="/modules/zendesk/" class="dd-item">
<div>
Expand Down
15 changes: 0 additions & 15 deletions docs/modules/google/gcal/index.html
Expand Up @@ -404,24 +404,12 @@
<option value="/modules/circleci/" >- CircleCI</option>
<option value="/modules/clocks/" >- Clocks</option>
<option value="/modules/cmdrunner/" >- CmdRunner</option>
<option value="/modules/cryptocurrencies/" >
-
Crypo Currencies</option>
<option value="/modules/gerrit/" >- Gerrit</option>
<option value="/modules/git/" >- Git</option>
<option value="/modules/github/" >- GitHub</option>
<option value="/modules/gitlab/" >- GitLab</option>
<option value="/modules/gitter/" >- Gitter</option>
<option value="/modules/google/" >
-
Google Apps</option>
<option value="/modules/google/gcal/" selected>-- Google Calendar</option>
<option value="/modules/google/gspreadsheet/" >-- Google Spreadsheets</option>

<option value="/modules/hackernews/" >- Hacker News</option>
<option value="/modules/ipaddress/" >
-
IP Addresses</option>
<option value="/modules/jenkins/" >- Jenkins</option>
<option value="/modules/jira/" >- Jira</option>
<option value="/modules/logger/" >- Logger</option>
Expand All @@ -435,9 +423,6 @@
<option value="/modules/travisci/" >- TravisCI</option>
<option value="/modules/trello/" >- Trello</option>
<option value="/modules/twitter/" >- Twitter</option>
<option value="/modules/weather_services/" >
-
Weather Services</option>
<option value="/modules/zendesk/" >- Zendesk</option>


Expand Down
3 changes: 2 additions & 1 deletion docs/modules/index.xml
Expand Up @@ -325,9 +325,10 @@ board The name of the Trello board. enabled Determines whether or not this modul
<description>Added in v0.2.0.
Connects to the Twitter API and displays a single user&amp;rsquo;s tweets.
NOTE: This only works for single-application developer accounts for now.
To get your bearer token, please see: https://github.com/Trinergy/twitter_bearer_token
Source Code wtf/twitter/ Configuration twitter:bearerToken:&amp;#34;3276d7155dd9ee27b8b14f8743a408a9&amp;#34;enabled:trueposition:top:0left:1height:1width:1refreshInterval:20000 Attributes bearerToken Value: Your Twitter single-application Bearer Token
enabled Whether or not this module is executed and if its data displayed onscreen. Values: true, false.
position Defines where in the grid this module&amp;rsquo;s widget will be displayed. refreshInterval How often, in seconds, this module will update its data.</description>
position Defines where in the grid this module&amp;rsquo;s widget will be displayed.</description>
</item>

<item>
Expand Down
15 changes: 0 additions & 15 deletions docs/modules/ipaddress/ipapi/index.html
Expand Up @@ -404,24 +404,12 @@
<option value="/modules/circleci/" >- CircleCI</option>
<option value="/modules/clocks/" >- Clocks</option>
<option value="/modules/cmdrunner/" >- CmdRunner</option>
<option value="/modules/cryptocurrencies/" >
-
Crypo Currencies</option>
<option value="/modules/gerrit/" >- Gerrit</option>
<option value="/modules/git/" >- Git</option>
<option value="/modules/github/" >- GitHub</option>
<option value="/modules/gitlab/" >- GitLab</option>
<option value="/modules/gitter/" >- Gitter</option>
<option value="/modules/google/" >
-
Google Apps</option>
<option value="/modules/hackernews/" >- Hacker News</option>
<option value="/modules/ipaddress/" >
-
IP Addresses</option>
<option value="/modules/ipaddress/ipapi/" selected>-- IP-API</option>
<option value="/modules/ipaddress/ipinfo/" >-- IPInfo</option>

<option value="/modules/jenkins/" >- Jenkins</option>
<option value="/modules/jira/" >- Jira</option>
<option value="/modules/logger/" >- Logger</option>
Expand All @@ -435,9 +423,6 @@
<option value="/modules/travisci/" >- TravisCI</option>
<option value="/modules/trello/" >- Trello</option>
<option value="/modules/twitter/" >- Twitter</option>
<option value="/modules/weather_services/" >
-
Weather Services</option>
<option value="/modules/zendesk/" >- Zendesk</option>


Expand Down
12 changes: 12 additions & 0 deletions docs/modules/jenkins/index.html
Expand Up @@ -403,12 +403,21 @@
<option value="/modules/circleci/" >- CircleCI</option>
<option value="/modules/clocks/" >- Clocks</option>
<option value="/modules/cmdrunner/" >- CmdRunner</option>
<option value="/modules/cryptocurrencies/" >
-
Crypo Currencies</option>
<option value="/modules/gerrit/" >- Gerrit</option>
<option value="/modules/git/" >- Git</option>
<option value="/modules/github/" >- GitHub</option>
<option value="/modules/gitlab/" >- GitLab</option>
<option value="/modules/gitter/" >- Gitter</option>
<option value="/modules/google/" >
-
Google Apps</option>
<option value="/modules/hackernews/" >- Hacker News</option>
<option value="/modules/ipaddress/" >
-
IP Addresses</option>
<option value="/modules/jenkins/" selected>- Jenkins</option>
<option value="/modules/jira/" >- Jira</option>
<option value="/modules/logger/" >- Logger</option>
Expand All @@ -422,6 +431,9 @@
<option value="/modules/travisci/" >- TravisCI</option>
<option value="/modules/trello/" >- Trello</option>
<option value="/modules/twitter/" >- Twitter</option>
<option value="/modules/weather_services/" >
-
Weather Services</option>
<option value="/modules/zendesk/" >- Zendesk</option>


Expand Down
3 changes: 3 additions & 0 deletions docs/modules/twitter/index.html
Expand Up @@ -470,6 +470,9 @@ <h1>Twitter</h1>

<p>NOTE: This only works for single-application developer accounts for now.</p>

<p>To get your bearer token, please see:
<a href="https://github.com/Trinergy/twitter_bearer_token">https://github.com/Trinergy/twitter_bearer_token</a></p>

<h2 id="source-code">Source Code</h2>
<div class="highlight"><pre class="chroma"><code class="language-bash" data-lang="bash">wtf/twitter/</code></pre></div>
<h2 id="configuration">Configuration</h2>
Expand Down
2 changes: 1 addition & 1 deletion twitter/client.go
Expand Up @@ -25,7 +25,7 @@ type Client struct {
func NewClient(url string) *Client {
client := Client{
apiBase: url,
screenName: "wtfutil",
screenName: "senorprogrammer",
count: 5,
}

Expand Down

0 comments on commit 3681bea

Please sign in to comment.