0 Replies Latest reply on Feb 23, 2018 1:56 AM by reeceseymour

    Uploading profile images using invoke-webrequest in powershell

    reeceseymour Novice

      I have found the below curl commands but I am having trouble getting the syntax right in PowerShell


      Update profile picture

      curl -i -u user:pass -X POST -F "file=@your_file.jpg;type=image/jpg" "https://your_jive_instance/api/core/v3/profileImages/temporary"



      Note:  When uploading images for other assets (non-profile) you can use the following end-point instead: POST https://your_jive_instance/api/core/v3/images

      Per this document: Jive REST Rest API v3.7 → Image service check for 201 status code and look at the Location header for the URL of the new Jive image that you can pass to:

      curl -i -u user:pass -X POST -F "imageURI=https%3A%2F%2Fyour_jive_instance%2Fapi%2Fcore%2Fv3%2FprofileImages%2Ftemporary%2FXXXXX" "https://your_jive_instance/api/core/v3/people/xxxx/images"




      PowerShell I am using