Last active
December 16, 2020 10:14
-
-
Save ntkog/1e4f348c99f4fba559072e005396f95a to your computer and use it in GitHub Desktop.
IVOOX RSS feed fixer for Spotify
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": 2, | |
"builds": [{ "src": "server.js", "use": "@now/node-server" }], | |
"routes": [ | |
{ | |
"src": "/", | |
"dest": "/server.js", | |
"methods": ["GET"] | |
} | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "ivoox-fixer", | |
"version": "1.0.0", | |
"description": "", | |
"main": "server.js", | |
"scripts": { | |
"start": "node server.js" | |
}, | |
"keywords": [], | |
"author": "Jorge Barrachina", | |
"license": "MIT", | |
"dependencies": { | |
"express": "^4.17.1", | |
"replacestream": "^4.0.3", | |
"request": "^2.88.0" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require("express"); | |
const app = express(); | |
const replaceStream = require('replacestream'); | |
const request = require('request'); | |
const port = 5000; | |
// Body parser | |
app.use(express.urlencoded({ extended: false })); | |
// Home route | |
app.get("/", (req, res) => { | |
res.status(200); | |
request.get(req.query.podcastUrl) | |
.pipe(replaceStream(`<itunes:author><![CDATA[${req.query.podcastName}]]></itunes:author>`, | |
`<itunes:author><![CDATA[${req.query.podcastName}]]></itunes:author><itunes:owner><itunes:email>${req.query.podcastEmail}</itunes:email></itunes:owner>`)) | |
.pipe(res); | |
}); | |
// Listen on port 5000 | |
app.listen(port, () => { | |
console.log(`Server is booming on port 5000 | |
Visit http://localhost:5000`); | |
}); |
This solution is no longer needed. It seems now RSS feed from Ivoox, adds "itunes:email" tag properly (But be aware that's is not a mandatory field when you create your Ivoox podcast, so put something there)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you prefer deploy your instance with netlify , here is a repo you can look at :
https://gitlab.com/aguacates.mutantes/ivoox_rss