DEV Community

RSS to JSON Conversion - Solution ?

Sohail Pathan on February 10, 2024

Scenario: A content aggregation platform is exploring the possibility of incorporating a feature that allows for the transformation of RSS feeds i...
Collapse
 
ranjancse profile image
Ranjan Dailata • Edited

I would always go with the custom solution due to the total control based upon the solution or technology which I am working.

What you have provided feedparser is just a tip of the iceberg. Below is the NodeJS Open Source Option. I can achieve the same in just a few lines of code :)

yarn add rss-to-json

const { parse } = require('rss-to-json');
(async () => {
    var rss = await parse('https://blog.ethereum.org/feed.xml');
    console.log(JSON.stringify(rss, null, 3));
})();

Enter fullscreen mode Exit fullscreen mode

Reference -

rss-to-json
github-sample

All of these utility functions or services which you see could be developed in no time. The real value comes with the 3rd parties only if you are providing an exceptional services which the developers are struggling every day and there's no way they could easily accomplish in a given timeframe.

Imagine why would developers or companies insist with the external calls for accomplishing the same?

Collapse
 
iamspathan profile image
Sohail Pathan

Hey @ranjancse, thanks for your input on the strategy. About this post, I wanted from community to hear their thoughts on both methods and to determine which is more sustainable for the future and not to just conclude which is always preferable for developers.

Of course, deciding between a custom solution and a third-party API should involve careful consideration of the project’s needs, available resources, and the ability to maintain the solution over time.

I believe we tend to prefer crafting our solutions if we have enough time and resources to update them with any future changes in the use case. In this case - using the custom library or building your own is good for sure.

However, this isn't always possible, particularly when time is short. For developers who are sometimes dependent on no-code or automation tools, achieving the desired outcome is their main goal. In these situations - using an API service might be the right choice.

Regarding,

The real value comes with the 3rd parties only if you are providing exceptional services which the developers are struggling with every day and there's no way they could easily accomplish in a given timeframe.

I’d love to hear an example if you have one, to better understand this point. Because this will help me to pass the feedback to my team.

Thanks

Collapse
 
ranjancse profile image
Ranjan Dailata • Edited

Consider the following exceptional service example in the field of AI.

  • RAG as a Service
  • Embeddings Service
  • AI Search as a Service
  • LLMOps as a Service
  • MLOps as a Service
  • ML as a Service
Thread Thread
 
iamspathan profile image
Sohail Pathan

Appreciate :)