Clarity Service Management

Expand all | Collapse all

Get attachment using WS

Jump to Best Answer
  • 1.  Get attachment using WS

    Posted 03-11-2016 09:58 AM

    Hi community,


    I just wondering if any of you know how to get an image from SDM using Web Services or CA PAM, I am working with that images for profile picture in CA SDM, but the administrator need to upload the pics in the repository so it changes the extension to .GZ and my script can't read it...

    I want to know if is possible download a image from SDM repository in a specific folder through Web Services/PAM, or Upload the images with the original extension, without ".GZ":


    Thanks in advance, I appreciate your help.


  • 2.  Re: Get attachment using WS

    Posted 03-11-2016 10:01 AM


    partially answering your question, as I know .gz is an archive file type, so you can disable archiving in Repository settings in SDM. (Admin tab -> Attachments -> Repositories -> [Edit] -> Archive Type : None).



  • 3.  Re: Get attachment using WS

    Posted 03-11-2016 10:55 AM

    Hi cdtj


    This options didn't work, the SDM Repository is already configured like that. anyway this continues attaching with the .GZ extension.



  • 4.  Re: Get attachment using WS
    Best Answer

    Posted 03-11-2016 11:22 AM


    The attachments are simple files on the system.

    So you can retrieve the path to that specific attachment and repository using web service method:





    and then grab/construct the physical path to the file on the system itself.

    Of course if the file is compressed your script will need to decompress it before reading/displaying the content.

    Many compressing tools like Gzip.exe can be used command line to do that.


  • 5.  Re: Get attachment using WS

    Posted 03-14-2016 03:23 AM

    Hi you can use upload servlet to get attachments from SDM. Check the following thread Downloading attachment using CA Upload servlet using following link

    You can aslo use REST API to get attachments

  • 6.  Re: Get attachment using WS

    Posted 03-14-2016 04:19 AM

    Thanks Gutis . I didn't think to use the upload servlet directly and we tried with REST but this was buggy at this time. I think CA have now corrected it with patch. Didn't have give it a try since then.


  • 7.  Re: Get attachment using WS

    Posted 03-14-2016 10:43 AM

    Thanks so much for all your help Gutis and Jmayer, I did use command line for decompressing, and it works

  • 8.  Re: Get attachment using WS

    Posted 03-14-2016 12:02 PM

    Virtual Team Work