Skip to main content

Notifications

Community site session details

Community site session details

Session Id : WKV8TTwbmR0ol1aBnnw6ES
Power Apps - Power Apps Pro Dev & ISV
Answered

HTTP post request asking for length

Like (0) ShareShare
ReportReport
Posted on 3 Apr 2025 09:47:31 by 33
So I am trying to make an HTTP post request to a service bus queue.
I have construct JSON payload action:



However I am getting "HTTP Error 411. The request must be chunked or have a content length"

I have tried turning on chunking. Didn't work
Have tried specifing a Content-Length header:


Then adding that value to the my Http post, as per below:
But keep getting the HTTP 411 error and Length Required error on the Http Post action
Any ideas how to resolve?
  • Verified answer
    sandeepstw Profile Picture
    293 Super User 2025 Season 1 on 03 Apr 2025 at 10:03:04
    HTTP post request asking for length
    You are getting "HTTP Error 411 Length Required" because the server (like Azure Service Bus) needs a Content-Length header, and Power Automate is not sending it properly when the request is not formed right.
    1. Use HTTP method as POST
    2. Do not manually add Content-Length header
    3. In headers, only use content type as below
        {
          "Content-Type": "application/json"
        }
        and make sure your body is not empty, even send {} if you have nothing
    4. if you are sending dynamic content, wrap it using string()
        example:
        {
          "data": "@{string(variables('yourJsonVariable'))}"
        }
    5. Do not add Transfer-Encoding: chunked header
    6. Let Power Automate calculate body size on its own
    This should fix the 411 error.

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,518 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,692 Most Valuable Professional

Leaderboard
Loading started