feed

Add and Delete RSS Feeds for Automated Posting

post
Add an RSS Feed

https://app.ayrshare.com/api/feed
Add a new RSS feed for automated posting of new articles.
Request
Response
Request
Headers
Authentication
required
string
Format: Authorization: Bearer API_KEY. See Overview for more information.
Body Parameters
type
optional
string
Value: "rss" or "substack". If not present, default to "rss"
url
required
string
URL of RSS feed
Response
200: OK
Successfull addition of RSS feed.
{
"status": "success",
"id": "4HZhptaD5",
"title": "Pulte's Money and Life Thoughts",
"websiteLink": "https://pulte.substack.com",
"rssURL": "https://pulte.substack.com/feed"
}

Request Example

cURL
Node.js
Python
cURL
curl \
-H "Authorization: Bearer API_KEY" \
-H 'Content-Type: application/json' \
-d '{"url": "https://www.nytimes.com"}' \
-X POST https://app.ayrshare.com/api/feed
Node.js
const fetch = require("node-fetch");
const API_KEY = "API_KEY";
const url = "https:///www.nytimes.com";
fetch("https://app.ayrshare.com/api/feed", {
method: "DELETE",
headers: {
"Content-Type": "application/json",
"Authorization": `Bearer ${API_KEY}`
},
body: JSON.stringify({ url }),
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
Python
import requests
payload = {'url': 'https://www.nytimes.com'}
headers = {'Content-Type': 'application/json',
'Authorization': 'Bearer API_KEY'}
r = requests.delete('https://app.ayrshare.com/api/feed',
json=payload,
headers=headers)
print(r.json())

delete
Delete RSS Feed

https://app.ayrshare.com/api/feed
Delete an RSS Feed that was previously added
Request
Response
Request
Headers
Authorization
optional
string
Format: Authorization: Bearer API Key. See Overview for more information.
Body Parameters
id
optional
string
ID of the RSS Feed returned when adding
Response
200: OK
Successful deletion of RSS Feed
{
"status": "success"
}

Request Example

cURL
Node.js
Python
cURL
curl \
-H "Authorization: Bearer API_KEY" \
-H 'Content-Type: application/json' \
-d '{"id": "4HZhptaD5"}' \
-X DELETE https://app.ayrshare.com/api/feed
Node.js
const fetch = require("node-fetch");
const API_KEY = "API_KEY";
const id = "4HZhptaD5";
fetch("https://app.ayrshare.com/api/feed", {
method: "DELETE",
headers: {
"Content-Type": "application/json",
"Authorization": `Bearer ${API_KEY}`
},
body: JSON.stringify({ id }),
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
Python
import requests
payload = {'id': '4HZhptaD5'}
headers = {'Content-Type': 'application/json',
'Authorization': 'Bearer API_KEY'}
r = requests.delete('https://app.ayrshare.com/api/feed',
json=payload,
headers=headers)
print(r.json())