Forum Discussion

Inactive User's avatar
Inactive User
5 years ago

Get cover image using API V1?

Is there a way to select the cover image using API v1?

There's the images array, and I can obviously select the [0] image -- if the cover image is the first one. What if it's not?

https://devdocportal.lithium.com/t5/Community-API-v1-Reference/bd-p/restv1docs?section=commv1&leaf-id=Message.images#Message.images

5 Replies

  • Inactive User, Its difficult to use that using V1, since V1 treat cover image and body images in same API. Also there is no difference in there node.

    I would suggest its better to use API V2 in this case, to get specific cover image of messages using API below.

     

    SELECT cover_image FROM messages WHERE id='2366'

     

  • Inactive User's avatar
    Inactive User
    5 years ago

    Parshant Thank you, however I need to use v1 for this particular project. Is it impossible or just difficult? 

  • Parshant's avatar
    Parshant
    Boss
    5 years ago

    Its seems to be impossible, since it doesn't make any differences in node or attributes with other images in array. 

  • Inactive User's avatar
    Inactive User
    5 years ago

    Parshant wrote:

    mcdvoice, Its difficult to use that using V1, since V1 treat cover image and body images in same API. Also there is no difference in there node.

    I would suggest its better to use API V2 in this case, to get specific cover image of messages using API below.

     

     

     

    SELECT cover_image FROM messages WHERE id='2366'

     

     

     


    I got really good information from this content.thanks for sharing.