gasp / instatom_node

simple nodejs atom feed providers for instagram
5 stars 2 forks source link

No original post link, images linked instead #3

Closed KillyMXI closed 5 years ago

KillyMXI commented 5 years ago

There is no instagram.com/p/... links - all feed items have images linked instead of posts.

gasp commented 5 years ago

I think it depends on the feed reader client, vienna app it works perfectly. How would you change in the atom feed ?

KillyMXI commented 5 years ago

What I have now by opening instatom.freelancis.net/anomalytowncomic url (no feed reader involved):

<?xml version="1.0" encoding="utf-8" ?>
<feed xmlns="http://www.w3.org/2005/Atom" 
    xmlns:dc="http://purl.org/dc/elements/1.1/" 
    xmlns:media="http://search.yahoo.com/mrss/">
    <title>Pictures from instagram anomalytowncomic</title>
    <link rel="alternate" type="text/html" href="http://instagram.com/anomalytowncomic"></link>
    <id>tag:instatom:/anomalytowncomic</id>    <!-- icon= thumbnail_url-->
    <subtitle></subtitle>
    <updated></updated>
    <generator uri="http://instatom.freelancis.net/">instatom</generator>
    <entry>
        <title></title>
        <link rel="alternate" type="text/html" href="https://scontent-cdt1-1.cdninstagram.com/vp/553c5029a10efe43c99b72ccd3093e24/5D148F60/t51.2885-15/e35/51443740_816131178727899_6625891955052716993_n.jpg?_nc_ht=scontent-cdt1-1.cdninstagram.com"></link>
        <id>tag:instagram.com,2019-02-25T15:55:58.000Z</id>
        <published>2019-02-25T15:55:58.000Z</published>
        <updated>2019-02-25T15:55:58.000Z</updated>
        <content type="image">&lt;img src=&quot;https://scontent-cdt1-1.cdninstagram.com/vp/553c5029a10efe43c99b72ccd3093e24/5D148F60/t51.2885-15/e35/51443740_816131178727899_6625891955052716993_n.jpg?_nc_ht=scontent-cdt1-1.cdninstagram.com&quot; width=&quot;640&quot; height=&quot;640&quot; alt=&quot;&quot; /&gt; </content>
        <author>
            <name>Anomaly town</name>
            <uri>http://instagram.com/anomalytowncomic</uri>
        </author>
        <link rel="enclosure" type="image/jpeg" href="https://scontent-cdt1-1.cdninstagram.com/vp/553c5029a10efe43c99b72ccd3093e24/5D148F60/t51.2885-15/e35/51443740_816131178727899_6625891955052716993_n.jpg?_nc_ht=scontent-cdt1-1.cdninstagram.com"></link>
    </entry>
...

Within an entry, there are two link tags, both pointing to an image. And content also contains the same link. Correct link https://www.instagram.com/p/BuT4FFHgt3S/ can't be seen anywhere.

If I understand Atom standard right, I would expect these link tags inside an entry:

    <link href="https://www.instagram.com/p/BuT4FFHgt3S/" />
    <link rel="enclosure" type="image/jpeg" href="https://scontent-cdt1-1.cdninstagram.com/vp/553c5029a10efe43c99b72ccd3093e24/5D148F60/t51.2885-15/e35/51443740_816131178727899_6625891955052716993_n.jpg?_nc_ht=scontent-cdt1-1.cdninstagram.com"/>

Your feed, on the other hand:

  1. missing the base links for entries;
  2. includes questionable link rel="alternate" type="text/html" pointing to images;
  3. has also rel="alternate" for the link tag of the feed itself - I would question the need of including this for default link.

I'm using TTRSS. And I can't see how any feed reader can deduce the correct link from given feed.

gasp commented 5 years ago

Thank you for the very high quality feedback, this should be an easy fix, working on it !

gasp commented 5 years ago

Fixed and deployed