Forum Discussion

shravani's avatar
8 years ago

API to fetch all the images which are uploaded by the users including users that are not having...

Do we have any API to fetch all the images which are uploaded by the users including users that are not having upload image permission through Admin? Such users (not having upload permission) are able to provide image URL and these images are visible in OOTB components.We have a custom component in which we need to show all the images uploaded including the ones that he/she can upload using URL too. Hence we need such API which retrieves all the images uploaded by the user.

 

Regards,

shravani

    • satya's avatar
      satya
      Expert

      Hi shravani,

       

      Hope this might helps you

       

      /restapi/vc/users/id/[id]/uploads/images

      Here  is the documentation link for your reference.

       

      Thanks,

      Srujana Satya 

       

       

      • shravani's avatar
        shravani
        Guide

        Hi satya and VikasB,

        I do not need user specific images but the images which are posted throughout the community.

        I have tried this api call "/uploads/images". But this api does not return the images which are uploaded by the users who does not have the permission to upload an image.

  • Hi shravani,

     

    Can you be more specific as to where the users are able to provide image URL? Is it in the Rich Text Editor, profile page (Add Image) or else where?

     

    Thanks,

    Srujana.

    • shravani's avatar
      shravani
      Guide

      Hi srujanayeruvaka,

      The user is uploading it in Rich Text Editor even though he does not have any permission and these images are visible in OOTB components. I need an API which will give me these images as well.

      • srujanayeruvaka's avatar
        srujanayeruvaka
        Champion

        shravani - I believe there is no API to retrieve such externally hosted images (to the best of my knowledge). You may have to get the list of all messages posted by the user and parse each message body to fetch the image URL.

         

        I would still wait to hear for a better/correct answer to your query from the other more knowledgeable members of this community! :)

         

        Thanks,

        Srujana.