eirtube/api/playlists.js
2024-12-19 01:32:27 -06:00

18 lines
365 B
JavaScript
Executable File

module.exports = [
{
route: "/playlist", methods: ["GET"], code: async ({req, url, res}) => {
let playlistId = url.searchParams.get("list")
if (playlistId) {
const segs = playlistId.split("/")
playlistId = segs[segs.length - 1]
}
return {
statusCode: 200,
contentType: "text/plain;charset=UTF-8",
content: "TODO!",
}
}
}
]