web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Send an HTTP Request t...
Power Automate
Unanswered

Send an HTTP Request to Azure DevOps giving error

(1) ShareShare
ReportReport
Posted on by

Hi Team,

 

So till last week the step was working fine and good but suddenly it started failing without any changes made.

 

So what I was doing in below step is basically hosting an image or any other attachment to Azure DevOps as per Azure DevOps API documentation. The content bytes i'm sending is in Base64 so i've set "Body is Base64" to yes

 

21.png

 

As you can see in the above picture I'm passing the content bytes in the body which are in base64 encoded string and i've set body is base64 to yes also.

The step was good and working as expected but suddenly started giving me the following error :

 

errer.PNG

 

The request indicated a Content-Type of "" for method type "POST" which is not supported. Valid content types for this method are: application/json, application/json-patch+json, application/octet-stream.
clientRequestId: 7917cf84-34ab-4fa9-afdd-758da12ff963

 

From the error it seems like I am passing the wrong content-type , but for base64 we generally use "application/octet-stream" which I'm actually passing in the request as you can see in the 1st image. Still its not taking my content.
 
Can someone please help me in this? its really blocking my already

 

Categories:
I have the same question (0)
  • ka05th30ry Profile Picture
    10 on at

    @Anonymous I am experiencing the same issue and it appears that @kubalaml is also having the same problem.

     

    See details here:

    https://powerusers.microsoft.com/t5/I-Found-A-Bug/Send-an-HTTP-request-to-Azure-DevOps-errors-on-Content-Type/m-p/475179/highlight/true#M6333

     

    So far no solution...

  • t-tatoku Profile Picture
    on at

    @Anonymous 

    It seems several users experiencing similar problem.

    I have checked if there is any similar cases reported, but could not find.

    Please open a service request.

     

  • Community Power Platform Member Profile Picture
    on at

    @t-tatokuJust to be clear by service request you mean to say a request to Azure DevOps Services to Microsof Support at below link 

    https://azure.microsoft.com/en-us/support/devops/

     

  • t-tatoku Profile Picture
    on at

    @Anonymous 

    I meant the support request from the Power Automate.

    SupportRequest.png

    It will lead to the the same page as the Power Platform Help and support site as follows. 

    https://admin.powerplatform.microsoft.com/support 

  • Community Power Platform Member Profile Picture
    on at

    No Luck 😞

     

    I think I need a different plan for that 😞

     

    plan.PNG

  • ka05th30ry Profile Picture
    10 on at

    After some more research and different attempts I found a solution, which was to use an Azure Function to execute the image upload and attaching to the specified Work Item. See @hammer 's comment in this thread

    https://powerusers.microsoft.com/t5/Building-Flows/Create-work-item-at-Azure-DevOps-from-an-email-with-attachments/td-p/176019

     

    Also I believe I found the reason why the DevOps connector for "Send an HTTP request to Azure DevOps" is yielding a corrupted image. See my comment in the same thread for details. 

     

    I have created a support ticket for this but at least have a working solution in the meantime. 

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    Hi Team,

     

    So I finally found the solution to the problem. But somehow its still not working with the actual step "Send an HTTP Request to Azure DevOps" but instead of that I have used a normal "HTTP" post step.

     

    There's a change in which you need to pass the contents of the attachments in the body as you can see in the image below you need to add : "$content-type": "application/octet-stream; api-version=5.1" in the body of the request.

     

    Also you are not able to pass the attachment content directly so you need to tweak it a little as I have done in the compose 14 step mentioned in the pic , the function inside goes like this : 

    base64(base64ToBinary( body('Get_Attachment_(V2)')?['contentBytes'] ))
     
    At last pass the correct body and authenticate the step with a PATS token from Azure DevOps
    (choose basic authentication and then type your Organizational Username in Username and PATS token in Password)
    upload.PNG
  • t-tatoku Profile Picture
    on at

    @Anonymous

    Sorry, you need to have security roles such as Office 365 Global admin or Service support admin.

    https://docs.microsoft.com/en-us/power-platform/admin/get-help-support  

  • dbrown Profile Picture
    2 on at

    Has anyone been able to get this working with Node? I am able to get the byte array from the base64 string of the attachment sent from the flow but I am still getting corrupted contents.

  • t-tatoku Profile Picture
    on at

    @dbrown , @kubalaml might know more about the problem since he has also experienced similar problem and submitted SR.

    https://powerusers.microsoft.com/t5/I-Found-A-Bug/Send-an-HTTP-request-to-Azure-DevOps-errors-on-Content-Type/m-p/475179/highlight/true#M6333 

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard