### Install Livescore API Node.js SDK Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Install the livescoreapi package using npm. This command adds the package as a dependency to your project. ```shell npm install --save livescoreapi ``` -------------------------------- ### getHistoryFromDateLeagueLanguage(date, leagueId, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history starting from a date, for a specific league and language. ```APIDOC ## getHistoryFromDateLeagueLanguage(date, leagueId, language) ### Description Retrieves match history starting from a date, for a specific league and language. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryFromDateLeagueLanguage(date, leagueId, language) ``` ``` -------------------------------- ### getHistoryFromDateLeague(date, leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history starting from a date for a specific league. ```APIDOC ## getHistoryFromDateLeague(date, leagueId) ### Description Retrieves match history starting from a date for a specific league. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. ### Method ``` getHistoryFromDateLeague(date, leagueId) ``` ``` -------------------------------- ### getHistoryFromDateLanguage(date, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history starting from a date in a specific language. ```APIDOC ## getHistoryFromDateLanguage(date, language) ### Description Retrieves match history starting from a date in a specific language. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryFromDateLanguage(date, language) ``` ``` -------------------------------- ### Countries API Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Method to get the list of countries available in the Livescore API. ```APIDOC ## Countries API ### Description Retrieves a list of all countries supported by the Livescore API. ### Method `getAllCountries()` ### Parameters None ### Response Returns a list of countries. ``` -------------------------------- ### Initialize and Use Livescore API Client Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Initialize the LivescoreAPI client with your credentials and base URL, then use it to fetch all live scores. Handles potential errors during the API call. ```javascript const client = require('livescoreapi'); client = livescoreapi.LivescoreAPI("", "", 'http://livescore-api.com/api-client/'); client.getAllLiveScores((err, livescores) => { if (err) { console.log(err); // Print the error if one occurred } else { console.log(livescores); // Print the response of the API } }); ``` -------------------------------- ### getAllFixtures() Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves a list of all available fixtures. ```APIDOC ## getAllFixtures() ### Description Retrieves a list of all available fixtures. ### Method ``` getAllFixtures() ``` ``` -------------------------------- ### getFixturesFromLeague(leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves a list of fixtures for a specific league. ```APIDOC ## getFixturesFromLeague(leagueId) ### Description Retrieves a list of fixtures for a specific league. ### Parameters #### Path Parameters - **leagueId** (string) - Required - The ID of the league. ### Method ``` getFixturesFromLeague(leagueId) ``` ``` -------------------------------- ### getFixturesFromDate(date) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves a list of fixtures from a specific date. ```APIDOC ## getFixturesFromDate(date) ### Description Retrieves a list of fixtures from a specific date. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. ### Method ``` getFixturesFromDate(date) ``` ``` -------------------------------- ### getFixturesDateLanguageLeague(date, language, leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves fixtures based on date, language, and league ID. ```APIDOC ## getFixturesDateLanguageLeague(date, language, leagueId) ### Description Retrieves fixtures based on date, language, and league ID. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). - **leagueId** (string) - Required - The ID of the league. ### Method ``` getFixturesDateLanguageLeague(date, language, leagueId) ``` ``` -------------------------------- ### getFixturesLeagueLanguage(leagueId, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves fixtures based on league ID and language. ```APIDOC ## getFixturesLeagueLanguage(leagueId, language) ### Description Retrieves fixtures based on league ID and language. ### Parameters #### Path Parameters - **leagueId** (string) - Required - The ID of the league. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getFixturesLeagueLanguage(leagueId, language) ``` ``` -------------------------------- ### getFixturesInLanguage(language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves a list of fixtures in a specific language. ```APIDOC ## getFixturesInLanguage(language) ### Description Retrieves a list of fixtures in a specific language. ### Parameters #### Path Parameters - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getFixturesInLanguage(language) ``` ``` -------------------------------- ### getFixturesDateLanguage(date, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves fixtures based on date and language. ```APIDOC ## getFixturesDateLanguage(date, language) ### Description Retrieves fixtures based on date and language. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getFixturesDateLanguage(date, language) ``` ``` -------------------------------- ### getFullHistory() Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves the complete history of matches. ```APIDOC ## getFullHistory() ### Description Retrieves the complete history of matches. ### Method ``` getFullHistory() ``` ``` -------------------------------- ### getFixturesDateLeague(date, leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves fixtures based on date and league ID. ```APIDOC ## getFixturesDateLeague(date, leagueId) ### Description Retrieves fixtures based on date and league ID. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. ### Method ``` getFixturesDateLeague(date, leagueId) ``` ``` -------------------------------- ### getHistoryToDateLeagueLanguage(date, leagueId, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history up to a date, for a specific league and language. ```APIDOC ## getHistoryToDateLeagueLanguage(date, leagueId, language) ### Description Retrieves match history up to a date, for a specific league and language. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryToDateLeagueLanguage(date, leagueId, language) ``` ``` -------------------------------- ### getHistoryBetweenDatesLeague(startDate, endDate, leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history between two dates for a specific league. ```APIDOC ## getHistoryBetweenDatesLeague(startDate, endDate, leagueId) ### Description Retrieves match history between two dates for a specific league. ### Parameters #### Path Parameters - **startDate** (string) - Required - The start date in 'YYYY-MM-DD' format. - **endDate** (string) - Required - The end date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. ### Method ``` getHistoryBetweenDatesLeague(startDate, endDate, leagueId) ``` ``` -------------------------------- ### getHistoryBetweendDatesCountryLanguage(startDate, endDate, leagueId, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history between two dates, for a specific league and language. ```APIDOC ## getHistoryBetweendDatesCountryLanguage(startDate, endDate, leagueId, language) ### Description Retrieves match history between two dates, for a specific league and language. ### Parameters #### Path Parameters - **startDate** (string) - Required - The start date in 'YYYY-MM-DD' format. - **endDate** (string) - Required - The end date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryBetweendDatesCountryLanguage(startDate, endDate, leagueId, language) ``` ``` -------------------------------- ### getHistoryLeagueLanguage(leagueId, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history for a specific league in a specific language. ```APIDOC ## getHistoryLeagueLanguage(leagueId, language) ### Description Retrieves match history for a specific league in a specific language. ### Parameters #### Path Parameters - **leagueId** (string) - Required - The ID of the league. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryLeagueLanguage(leagueId, language) ``` ``` -------------------------------- ### Leagues API Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Methods to retrieve league information from the Livescore API. ```APIDOC ## Leagues API ### Description Provides methods to fetch league data, including all leagues, leagues with fixtures, and leagues filtered by country. ### Methods * `getAllLeagues()`: Retrieves a list of all available leagues. * `getLeaguesWithFixtures()`: Retrieves a list of leagues that have associated fixtures. * `getLeaguesFromCountry(countryId)`: Retrieves a list of leagues from a specific country, identified by `countryId`. ``` -------------------------------- ### getHistoryFromDate(date) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves the history of matches from a specific date onwards. ```APIDOC ## getHistoryFromDate(date) ### Description Retrieves the history of matches from a specific date onwards. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. ### Method ``` getHistoryFromDate(date) ``` ``` -------------------------------- ### getHistoryBetweenDatesLanguage(startDate, endDate, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history between two dates for a specific language. ```APIDOC ## getHistoryBetweenDatesLanguage(startDate, endDate, language) ### Description Retrieves match history between two dates for a specific language. ### Parameters #### Path Parameters - **startDate** (string) - Required - The start date in 'YYYY-MM-DD' format. - **endDate** (string) - Required - The end date in 'YYYY-MM-DD' format. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryBetweenDatesLanguage(startDate, endDate, language) ``` ``` -------------------------------- ### getHistoryToDateLeague(date, leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history up to a date for a specific league. ```APIDOC ## getHistoryToDateLeague(date, leagueId) ### Description Retrieves match history up to a date for a specific league. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **leagueId** (string) - Required - The ID of the league. ### Method ``` getHistoryToDateLeague(date, leagueId) ``` ``` -------------------------------- ### getHistoryByLeague(leagueId) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves the history of matches for a specific league. ```APIDOC ## getHistoryByLeague(leagueId) ### Description Retrieves the history of matches for a specific league. ### Parameters #### Path Parameters - **leagueId** (string) - Required - The ID of the league. ### Method ``` getHistoryByLeague(leagueId) ``` ``` -------------------------------- ### getHistoryBetweenDates(startDate, endDate) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history between two specified dates. ```APIDOC ## getHistoryBetweenDates(startDate, endDate) ### Description Retrieves match history between two specified dates. ### Parameters #### Path Parameters - **startDate** (string) - Required - The start date in 'YYYY-MM-DD' format. - **endDate** (string) - Required - The end date in 'YYYY-MM-DD' format. ### Method ``` getHistoryBetweenDates(startDate, endDate) ``` ``` -------------------------------- ### getHistoryToDateLanguage(date, language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves match history up to a date in a specific language. ```APIDOC ## getHistoryToDateLanguage(date, language) ### Description Retrieves match history up to a date in a specific language. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryToDateLanguage(date, language) ``` ``` -------------------------------- ### Livescores API Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Methods to retrieve live score data from the Livescore API. ```APIDOC ## Livescores API ### Description Provides methods to fetch live score data based on various criteria such as country, league, and language. ### Methods * `getAllLiveScores()`: Retrieves a list of all current live scores. * `getLiveScoresByCountry(countryId)`: Retrieves live scores for a specific country, identified by `countryId`. * `getLiveScoresByLeague(leagueId)`: Retrieves live scores for a specific league, identified by `leagueId`. * `getLiveScoresInLanguage(language)`: Retrieves live scores in a specified language. Supported languages: `[ar, fa, ru]`. * `getLiveScoresCountryLeagueLanguage(countryId, leagueId, language)`: Retrieves live scores for a specific country, league, and language. * `getLiveScoresCountryLanguage(countryId, language)`: Retrieves live scores for a specific country and language. * `getLiveScoresCountryLeague(leagueId, countryId)`: Retrieves live scores for a specific league within a specific country. * `getLiveScoresLeagueLanguage(leagueId, language)`: Retrieves live scores for a specific league in a specific language. ``` -------------------------------- ### getHistoryInLanguage(language) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves the history of matches in a specific language. ```APIDOC ## getHistoryInLanguage(language) ### Description Retrieves the history of matches in a specific language. ### Parameters #### Path Parameters - **language** (string) - Required - The language code (e.g., 'ar', 'fa', 'ru'). ### Method ``` getHistoryInLanguage(language) ``` ``` -------------------------------- ### getHistoryToDate(date) Source: https://github.com/live-scores-api/sdk-nodejs/blob/master/README.md Retrieves past matches up to a specific date. ```APIDOC ## getHistoryToDate(date) ### Description Retrieves past matches up to a specific date. ### Parameters #### Path Parameters - **date** (string) - Required - The date in 'YYYY-MM-DD' format. ### Method ``` getHistoryToDate(date) ``` ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.