# Showcase your 'Medium' Articles in your site !

Let me give you context first, I have my portfolio website [www.summy.dev](http://www.summy.dev) and I write articles in Medium (used to - will let you know where I am doing now at end of this article), and I wanted to showcase those medium articles in my site, but dang ! there aren't any Medium Public Apis from where I can directly fetch from and I was banging my head, after lot of digging I came up with two ways of doing it -

## First way - Unofficial Medium API

Found a [Unofficial Medium API](https://mediumapi.com/), The api is pretty sweet, you get almost everything you want ranging from User Data ( User ID, User Articles, User Followers etc etc) as well as other details of Articles, Publications, List, Platform Details etc, but there's a catch to it !

Though the API is free, its only free for 150 calls per month. Dang ! and their paid version via [Rapid API](https://rapidapi.com/) is ain't cheap either, I'm not a faang employee bro !

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1712818963707/6e0cc8e9-1e5c-42b5-8505-28191c43297d.png align="center")

for my use case, this is not gonna work, not economically viable so lets not dig more into this api and head to next way I found (I agree we can fetch only thrice a day and catch the result but nah, I'm lazy to code that much).

## Second Way - Medium's RSS FEED !

<details data-node-type="hn-details-summary"><summary>Quick info for those who don't know what RSS is</summary><div data-type="detailsContent">RSS is a web feed that allows users and applications to access updates to websites in a standardized, computer-readable format. to put it in laymen terms , its just an XML and the provider (medium) in this case keeps updating it whenever there is an update.</div></details>

Medium provides RSS Feed of your profile at the address of below format

`medium.com/feed/@username` and [`username.medium.com/feed`](http://medium.com/feed/@username)*you can hit a get request on these address and in response you would get the RSS feed in xml.*

> *okay bud, I got the xml, what's now ?*

It's much simple, all you have to do now is to scrape through that xml and fetch out the information you need, it has all your article details, how I did it through was find a npm package which would parse xml-to-json and then consume the data !

keep in mind that the xml part which consists of your article changes the structure when your article structure is changed.

### Voila !

## What I am doing now ?

Well, This fetching of medium rss feed of my profile didn't give me much satisfaction, I just felt its not much stable mainly due to the fact that the structure of the RSS feed xml might change based on the structure of the article I have written.

This is when I discovered [Hashnode.com](https://hashnode.com/) , It is also one of the service like medium but mainly we devs right blogs over it and coolest part if you ask me is - it provides use a way to hook up our profile page of hashnode to our website as a sub domain ! and it even provides apis to fetch our articles and everything !

The current blog which you are reading is written in hashnode itself !

# Fin.
