{"id":21292026,"url":"https://github.com/johnnythetank/aping-plugin-codebird","last_synced_at":"2025-07-11T16:31:10.877Z","repository":{"id":57182141,"uuid":"46656670","full_name":"JohnnyTheTank/apiNG-plugin-codebird","owner":"JohnnyTheTank","description":"Twitter Plugin for apiNG","archived":false,"fork":false,"pushed_at":"2017-09-10T23:13:55.000Z","size":70,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-11T07:42:52.121Z","etag":null,"topics":["angular","api","aping","aping-plugin","codebird","social-wall","twitter"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JohnnyTheTank.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-11-22T10:59:11.000Z","updated_at":"2019-11-03T19:31:26.000Z","dependencies_parsed_at":"2022-08-30T16:11:13.574Z","dependency_job_id":null,"html_url":"https://github.com/JohnnyTheTank/apiNG-plugin-codebird","commit_stats":null,"previous_names":[],"tags_count":21,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2FapiNG-plugin-codebird","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2FapiNG-plugin-codebird/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2FapiNG-plugin-codebird/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2FapiNG-plugin-codebird/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JohnnyTheTank","download_url":"https://codeload.github.com/JohnnyTheTank/apiNG-plugin-codebird/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225741250,"owners_count":17516895,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["angular","api","aping","aping-plugin","codebird","social-wall","twitter"],"created_at":"2024-11-21T13:47:14.581Z","updated_at":"2024-11-21T13:47:15.229Z","avatar_url":"https://github.com/JohnnyTheTank.png","language":"JavaScript","readme":"[logo]: http://aping.io/logo/320/aping-plugin.png \"apiNG Plugin\"\n![apiNG][logo]\n\n**_apiNG-plugin-codebird_** is a [Twitter REST API](https://dev.twitter.com/rest/public) plugin for [**apiNG**](https://github.com/JohnnyTheTank/apiNG).\n\n[![Join the chat at https://gitter.im/JohnnyTheTank/apiNG](https://img.shields.io/badge/GITTER-join%20chat-green.svg)](https://gitter.im/JohnnyTheTank/apiNG?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n[![npm version](https://badge.fury.io/js/aping-plugin-codebird.svg)](https://badge.fury.io/js/aping-plugin-codebird)\n[![Bower version](https://badge.fury.io/bo/apiNG-plugin-codebird.svg)](https://badge.fury.io/bo/apiNG-plugin-codebird)\n\n# Information\n* **Supported apiNG models: `social`, `image`**\n* This plugin supports the [`get-native-data` parameter](https://aping.readme.io/docs/advanced#parameters)\n* This plugin needs an [bearer token](#2-bearer-token) :warning:\n* Used JavaScript library: [codebird-js](https://github.com/jublonet/codebird-js) _(included in distribution files)_\n\n# Documentation\n1. [INSTALLATION](#1-installation)\n    1. Get file\n    2. Include file\n    3. Add dependency\n    4. Add plugin\n2. [BEARER TOKEN](#2-bearer-token)\n    1. Generate your `bearer_token`\n    2. Insert your `bearer_token` into `aping-config.js`\n3. [USAGE](#3-usage)\n    1. Models\n    2. Requests\n    3. Rate limit\n\n## 1. INSTALLATION\n\n### I. Get file\nInstall via either [bower](http://bower.io/), [npm](https://www.npmjs.com/), CDN (jsDelivr) or downloaded files:\n\n* `bower install apiNG-plugin-codebird --save`\n* `npm install aping-plugin-codebird --save`\n* use [CDN file](https://www.jsdelivr.com/projects/aping.plugin-codebird)\n* download [apiNG-plugin-codebird.zip](https://github.com/JohnnyTheTank/apiNG-plugin-codebird/zipball/master)\n\n### II. Include file\nInclude `aping-plugin-codebird.min.js` in your apiNG application\n\n```html\n\u003c!-- when using bower --\u003e\n\u003cscript src=\"bower_components/apiNG-plugin-codebird/dist/aping-plugin-codebird.min.js\"\u003e\u003c/script\u003e\n\n\u003c!-- when using npm --\u003e\n\u003cscript src=\"node_modules/aping-plugin-codebird/dist/aping-plugin-codebird.min.js\"\u003e\u003c/script\u003e\n\n\u003c!-- when using cdn file --\u003e\n\u003cscript src=\"//cdn.jsdelivr.net/npm/aping-plugin-codebird@latest/dist/aping-plugin-codebird.min.js\"\u003e\u003c/script\u003e\n\n\u003c!-- when using downloaded files --\u003e\n\u003cscript src=\"aping-plugin-codebird.min.js\"\u003e\u003c/script\u003e\n```\n\n### III. Add dependency\nAdd the module `jtt_aping_codebird` as a dependency to your app module:\n```js\nangular.module('app', ['jtt_aping', 'jtt_aping_codebird']);\n```\n\n### IV. Add the plugin\nAdd the plugin's directive `aping-codebird=\"[]\"` to your apiNG directive and [configure your requests](#ii-requests)\n```html\n\u003caping\n    template-url=\"templates/social.html\"\n    model=\"social\"\n    items=\"20\"\n    aping-codebird=\"[{'search':'#music'}]\"\u003e\n\u003c/aping\u003e\n```\n\n## 2. BEARER TOKEN\n### I. Generate your `bearer_token`\n1. Login on [dev.twitter.com](https://dev.twitter.com/)\n2. Navigate to [apps.twitter.com](https://apps.twitter.com/)\n    - Create an new app\n    - Navigate to `https://apps.twitter.com/app/\u003cYOUR_APP_ID\u003e/permissions`\n        - Change Access to **Read only** and save\n    - Navigate to `https://apps.twitter.com/app/\u003cYOUR_APP_ID\u003e` \n3. Get your `bearer_token`\n    - Follow this official introductions: https://dev.twitter.com/oauth/reference/post/oauth2/token\n    - OR just use this simple generator: https://gearside.com/nebula/documentation/utilities/twitter-bearer-token-generator/\n\n### II. Insert your `bearer_token` into `aping-config.js`\nCreate and open `js/apiNG/aping-config.js` in your application folder. It should be look like this snippet:\n```js\nangular.module('jtt_aping').config(['$provide', function ($provide) {\n    $provide.value(\"apingDefaultSettings\", {\n        apingApiKeys : {\n            twitter: [\n                {'bearer_token':'\u003cYOUR_TWITTER_BEARER_TOKEN\u003e'}\n            ],\n            //...\n        }\n    });\n}]);\n```\n\n:warning: Replace `\u003cYOUR_TWITTER_BEARER_TOKEN\u003e` with your twitter `bearer_token`\n\n## 3. USAGE\n\n### I. Models\nSupported apiNG models\n\n|  model   | content | support | max items\u003cbr\u003eper request | (native) default items\u003cbr\u003eper request |\n|----------|---------|---------|--------|---------|\n| `social` | recent **tweets**, **videos**, **images** | full    | `100`   | `15`   |\n| `image`  | recent **images** | partly    | `100`   | `15`   |\n\n**support:**\n* full: _the source platform provides a full list with usable results_ \u003cbr\u003e\n* partly: _the source platfrom provides just partly usable results_\n\n\n### II. Requests\nEvery **apiNG plugin** expects an array of **requests** as html attribute.\n\n#### Requests by User\n|  parameter  | sample | default | description | optional |\n|----------|---------|---------|---------|---------|\n| **`user`** | `jquery` |  | The twitter screen name of the user for whom to return results for | no |\n| **`items`**  | `20` | `15` | Items per request (`0`-`100`) |  yes  |\n| **`showAvatar`** | `true` | `false` | Use `true` for show users avatar as image if post has no own image | yes |\n| **`exclude_replies`** | `true` | `false` | This parameter will prevent replies from appearing in the returned timeline. Using exclude_replies with the `items` parameter will mean you will receive up-to count tweets — this is because the `items` parameter retrieves that many tweets before filtering out retweets and replies. | yes |\n| **`include_rts`** | `false` | `true` | When set to `false`, the timeline will strip any native retweets (though they will still count toward both the maximal length of the timeline and the slice selected by the count parameter). | yes |\n\nSample requests:\n* `[{'user':'johnnyzeitlos'}, {'user':'jowe'}, {'user':'angularui'}]`\n* `[{'user':'AngularAir', 'items':10, 'showAvatar':'true', 'exclude_replies':true}]`\n\n#### Requests by Search\n|  parameter  | sample | default | description | optional |\n|----------|---------|---------|---------|---------|\n| **`search`** | `jquery` |  | Searchterm. A UTF-8, URL-encoded [search query](https://dev.twitter.com/rest/public/search) of 500 characters maximum, including operators. Queries may additionally be limited by complexity. | no |\n| **`items`**  | `20` | `15` | Items per request (`0`-`100`) |  yes  |\n| **`showAvatar`** | `true` | `false` | Use `true` for show users avatar as image if post has no own image | yes |\n| **`result_type`** | `recent` | `mixed` | `mixed` include both popular and real time results in the response\u003cbr\u003e`recent` return only the most recent results in the response\u003cbr\u003e`popular` return only the most popular results in the response | yes |\n| **`lat`** | `-13.163333` |  | Returns tweets by users located within a given radius of the given **latitude**/longitude | yes |\n| **`lng`** | `-72.545556` |  | Returns tweets by users located within a given radius of the given latitude/**longitude** | yes |\n| **`distance`** | `5` | `1` | Returns tweets by users located within a given **radius in kilometers** of the given latitude/longitude | yes |\n| **`language`** | `de` | | Restricts tweets to the given language, given by an [ISO 639-1](http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) code | yes |\n\nSample requests:\n* `[{'search':'#eagles', 'result_type':'recent'}, {'search':'Thomas Müller', 'result_type':'popular'}]`\n* `[{'search':'machu picchu', 'lat':'-13.163333', 'lng':'-72.545556', 'distance':5}]`\n\n### III. Rate limit\n\nVisit the official Twitter REST API rate limit documentations\n* [Rate Limits](https://dev.twitter.com/rest/public/rate-limiting)\n* [Rate Limits: Chart](https://dev.twitter.com/rest/public/rate-limits)\n\n# Licence\nMIT\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnnythetank%2Faping-plugin-codebird","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnnythetank%2Faping-plugin-codebird","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnnythetank%2Faping-plugin-codebird/lists"}