Making Requests
URL Structure
To make API Calls, you'll need to perform a GET or POST request to api.rssapi.net. All requests should be performed with SSL (HTTPS).
The URL always consist of the following structure:
https://api.rssapi.net/version/apikey/endpointThe current API Version is v1, so an example request could look like this:
https://api.rssapi.net/v1/APIKEY-ABC-123/endpointAuthentication
All API requests must be authenticated with a valid API Key. API Keys are bound to a specific Application. Create a new Application to get an API Key.
There are two ways you can authenticate your API Requests:
1. API Key in URL
The simplest way to authenticate your API calls is by putting your API Key in each Request URL, after the API Version, like this:
https://api.rssapi.net/v1/SECRET-APIKEY-ABC-123/endpoint2. API Key in Header
Another way to authenticate your API calls is by putting your API Key in a header called X-API-KEY and replacing the part in the URL where your API Key would normally be with "header". Here's how such an API call would look like with cURL:
curl -H "X-API-KEY:SECRET-APIKEY-ABC-123" https://api.rssapi.net/v1/header/endpointParameters
Most API Endpoints require one or more parameters. You can either set those parameters as GET parameters in the URL or by sending them as POST parameters in the body.
Please make sure that all your data is properly urlencoded and UTF-8 encoded to avoid issues with special characters.
Example with GET parameters:
curl "https://api.rssapi.net/v1/apikey/get?url=https%3A%2F%2Fwww.nasa.gov%2Frss%2Fdyn%2Fbreaking_news.rss&limit=5"The same request with POST parameters (cURL urlencodes the values for you):
curl -X POST "https://api.rssapi.net/v1/apikey/get" \
--data-urlencode "url=https://www.nasa.gov/rss/dyn/breaking_news.rss" \
--data-urlencode "limit=5"Response
All API responses will be in JSON format.
Every response will have an ok key, which will be either true or false, depending on the state of the API call. If the API call failed, ok will be false and there will be an error key which contains details on why the API call failed.
Example of a failed API call:
{
"ok": false,
"error": "Invalid Feed URL"
}Example of a successful API call:
{
"ok": true,
"result": {
"abc": "some data"
}
}