{"id":21292017,"url":"https://github.com/johnnythetank/angular-footballdata-api-factory","last_synced_at":"2025-07-11T16:31:05.353Z","repository":{"id":57178425,"uuid":"61585038","full_name":"JohnnyTheTank/angular-footballdata-api-factory","owner":"JohnnyTheTank","description":"AngularJS Factory for the football-data.org JSON REST API","archived":false,"fork":false,"pushed_at":"2016-12-23T08:45:31.000Z","size":16,"stargazers_count":50,"open_issues_count":1,"forks_count":20,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-11-15T08:39:23.591Z","etag":null,"topics":["angular","angular-factory","angularjs","api","factory","football","football-data","footballdata","soccer"],"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":"2016-06-20T22:35:00.000Z","updated_at":"2024-09-10T08:33:13.000Z","dependencies_parsed_at":"2022-08-30T16:11:16.578Z","dependency_job_id":null,"html_url":"https://github.com/JohnnyTheTank/angular-footballdata-api-factory","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2Fangular-footballdata-api-factory","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2Fangular-footballdata-api-factory/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2Fangular-footballdata-api-factory/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JohnnyTheTank%2Fangular-footballdata-api-factory/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JohnnyTheTank","download_url":"https://codeload.github.com/JohnnyTheTank/angular-footballdata-api-factory/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","angular-factory","angularjs","api","factory","football","football-data","footballdata","soccer"],"created_at":"2024-11-21T13:47:13.669Z","updated_at":"2024-11-21T13:47:14.296Z","avatar_url":"https://github.com/JohnnyTheTank.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"**angular-footballdata-api-factory** is an angularjs module with a [football-data.org](http://api.football-data.org) api factory.\n\n[![npm version](https://badge.fury.io/js/angular-footballdata-api-factory.svg)](https://badge.fury.io/js/angular-footballdata-api-factory)\n[![Bower version](https://badge.fury.io/bo/angular-footballdata-api-factory.svg)](https://badge.fury.io/bo/angular-footballdata-api-factory)\n \nAuthor: Jonathan Hornung ([JohnnyTheTank](https://github.com/JohnnyTheTank))\n\n## Usage\n\n1. Install via either [bower](http://bower.io/), [npm](https://www.npmjs.com/) or downloaded files:\n    1. `bower install --save angular-footballdata-api-factory`\n    2. `npm install --save angular-footballdata-api-factory`\n    3. download [angular-footballdata-api-factory.zip](https://github.com/JohnnyTheTank/angular-footballdata-api-factory/zipball/master)\n\n2. Include dependencies in your HTML.\n    1. When using bower:\n    ```html\n    \u003cscript src=\"bower_components/angular-footballdata-api-factory/dist/angular-footballdata-api-factory.min.js\"\u003e\u003c/script\u003e\n    ```\n    2. When using npm:\n    ```html\n    \u003cscript src=\"node_modules/angular-footballdata-api-factory/dist/angular-footballdata-api-factory.min.js\"\u003e\u003c/script\u003e\n    ```\n    3. when using downloaded files\n    ```html\n    \u003cscript src=\"angular-footballdata-api-factory.min.js\"\u003e\u003c/script\u003e\n    ```\n3. Add **`jtt_footballdata`** to your application's module dependencies.\n4. Use the factory `footballdataFactory`\n\n### factory methods\n\n#### getSeason\n\n```js\n//Show one Season\nfootballdataFactory.getSeason({\n    id: '\u003cSEASON_ID\u003e',\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getSeasons\n\n```js\n//List all available soccer seasons\nfootballdataFactory.getSeasons({\n    season: '\u003cSEASON\u003e',       // (optional) Default is the current year (4 digit), e.g: '2015'\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getTeam\n\n```js\n//Show one team.\nfootballdataFactory.getTeam({\n    id: '\u003cTEAM_ID\u003e',\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getTeams\n\n```js\n//List all teams for a certain soccerseason\nfootballdataFactory.getTeamsBySeason({\n    id: '\u003cSEASON_ID\u003e',\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getPlayers\n\n```js\n//Show all players for a certain team.\nfootballdataFactory.getPlayersByTeam({\n    id: '\u003cTEAM_ID\u003e',\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getLeagueTable\n\n```js\n//Show League Table / current standing.\nfootballdataFactory.getLeagueTableBySeason({\n    id: '\u003cSEASON_ID\u003e',\n    matchday: '\u003cMATCHDAY\u003e',   // (optional) The current/last matchday is taken per default\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n\n#### getFixture\n\n```js\n//Show one fixture.\nfootballdataFactory.getFixture({\n    id: '\u003cFIXTURE_ID\u003e',\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n#### getFixtures\n\n```js\n//List fixtures across a set of soccerseasons.\nfootballdataFactory.getFixtures({\n    timeFrame: '\u003cTIMEFRAME\u003e', // (optional) The value of the timeFrame argument must start with either 'p' for past or 'n' for next. It is followed by a number in the range 1-99.\n    league: '\u003cLEAGUE_CODE\u003e',  // (optional) A (list of, comma separated) league-code(s). Default is unset. Get all league codes at http://api.football-data.org/docs/latest/index.html\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n```js\n//List all fixtures for a certain soccerseason.\nfootballdataFactory.getFixturesBySeason({\n    id: '\u003cSEASON_ID\u003e',\n    timeFrame: '\u003cTIMEFRAME\u003e', // (optional) The value of the timeFrame argument must start with either 'p' for past or 'n' for next. It is followed by a number in the range 1-99.\n    matchday: '\u003cMATCHDAY\u003e',   // (optional) The current/last matchday is taken per default\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n```js\n//Show all fixtures for a certain team.\nfootballdataFactory.getFixturesByTeam({\n    id: '\u003cTEAM_ID\u003e',\n    season: '\u003cSEASON\u003e',       // (optional) Defaults to the current year, given as 4 digit like '2015'\n    timeFrame: '\u003cTIMEFRAME\u003e', // (optional) The value of the timeFrame argument must start with either 'p' for past or 'n' for next. It is followed by a number in the range 1-99.\n    venue: '\u003cVENUE\u003e',         // (optional) Valid values: `home` and `away`. Default is unset.\n    protocol: '\u003cPROTOCOL\u003e', // (optional) 'http', 'https', 'auto'\n    apiKey: '\u003cYOUR_API_KEY\u003e', // Register for a free api key: http://api.football-data.org/register\n}).then(function (_data) {\n    //on success\n}).catch(function (_data) {\n    //on error\n});\n```\n\n## football-data.org JSON API\n\n* Docs: http://api.football-data.org/documentation\n\n## More angular-api-factories\n[bandsintown](https://github.com/JohnnyTheTank/angular-bandsintown-api-factory) - [dailymotion](https://github.com/JohnnyTheTank/angular-dailymotion-api-factory) - [facebook](https://github.com/JohnnyTheTank/angular-facebook-api-factory) -  **footballdata** - [flickr](https://github.com/JohnnyTheTank/angular-flickr-api-factory) - [github](https://github.com/JohnnyTheTank/angular-github-api-factory) - [openweathermap](https://github.com/JohnnyTheTank/angular-openweathermap-api-factory) - [tumblr](https://github.com/JohnnyTheTank/angular-tumblr-api-factory) - [vimeo](https://github.com/JohnnyTheTank/angular-vimeo-api-factory) - [wikipedia](https://github.com/JohnnyTheTank/angular-wikipedia-api-factory) - [youtube](https://github.com/JohnnyTheTank/angular-youtube-api-factory)\n\n\n## License\n\nMIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnnythetank%2Fangular-footballdata-api-factory","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnnythetank%2Fangular-footballdata-api-factory","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnnythetank%2Fangular-footballdata-api-factory/lists"}