sportsdaily

免费增值
通过 dailybuzz | 已更新 hace un mes | News, Media
人气

8.3 / 10

延迟

521ms

服务等级

98%

Health Check

N/A

README

Sports News API

Welcome to the Sports API documentation. This API provides information about sports news, including titles, publication dates, content, and more.

Overview

This API is designed to offer access to sports-related news articles. It supports pagination to allow users to navigate through the available data efficiently.

Endpoints

Get Sports News

  • Endpoint: /api/sports/news/
  • Method: GET
  • Parameters:
    • page (optional): Page number for pagination. Default is 1.
    • page_size (optional): Number of items per page. Default is 10.

Example Request:

const axios = require('axios');

const options = {
  method: 'GET',
  url: 'https://sportsdaily.p.rapidapi.com/api/sports/news/',
  params: {
    page: '1',
    page_size: '15'
  },
  headers: {
    'X-RapidAPI-Key': '230591214amsh0833b9d51efdf1fp164645jsn88c0132afe71',
    'X-RapidAPI-Host': 'sportsdaily.p.rapidapi.com'
  }
};

try {
	const response = await axios.request(options);
	console.log(response.data);
} catch (error) {
	console.error(error);
}

Authentication

To use this API, you need to include the following headers in your request:

X-RapidAPI-Key: Your Rapid API key.

X-RapidAPI-Host: Hostname for the Rapid API service (sportsdaily.p.rapidapi.com).

Pagination
Pagination is supported using the page parameter in the query string. You can specify the page number to retrieve different sets of sports news.

Example for Page 2:

const options = {
  method: 'GET',
  url: 'https://sportsdaily.p.rapidapi.com/api/sports/news/',
  params: { page: '2' },
  headers: {
    'X-RapidAPI-Key': 'YOUR_RAPID_API_KEY',
    'X-RapidAPI-Host': 'sportsdaily.p.rapidapi.com'
  }
};

Additional Notes

Ensure you have a valid Rapid API key for authentication.
Refer to the Rapid API documentation for any updates or changes.
Feel free to reach out for any questions or support related to this API.

关注者:0
API 创建者:
Rapid account: Dailybuzz
dailybuzz
dailybuzzus
登录并给 API 打分
打分:5 - 投票:1