postman-code-generators icon indicating copy to clipboard operation
postman-code-generators copied to clipboard

No Content-Type header present for POST requests in generated HTML

Open stremovsky opened this issue 5 years ago • 1 comments

Describe the bug Hi, after I publish my API collection, all Content-Type headers are missing in generated HTML, making this HTML document unusable for my users.

You can take look at the resulting HTML here: https://documenter.getpostman.com/view/11310294/Szmcbz32?version=latest

To Reproduce I just created a number of requests including one that does POST request with: 'Content-Type: application/json'. In the resulting HTL, it is missing.

Expected code snippet and corresponding request The header should be present.

Additional context If you have any reference material which might help us debug the problem please add it here: Add any other context about the problem here. Version of postman-code-generators/Postman app: Postman v7.25.2

Thanks

stremovsky avatar Jun 03 '20 14:06 stremovsky

@stremovsky Content-Type seems to be present now in the generated snipped. For example:

PUT /v1/userapp/token/8c8b92b0-58c6-36db-634d-f0b0c798efd8/shipping HTTP/1.1
Host: demo.paranoidguy.com
Content-Type: application/json
X-Bunker-Token: DEMO

{
	"pob": 123
}

Could you confirm if this is still an issue?

webholik avatar Oct 29 '20 03:10 webholik

@stremovsky closing the ticket as the issue is fixed. Please feel free to open the ticket if you are still facing the issue 🙇‍♂

akshaydeo avatar Feb 06 '23 10:02 akshaydeo

Hi,

I can conform that it works correctly now for my project ;-) https://github.com/securitybunker/databunker

stremovsky avatar Feb 06 '23 10:02 stremovsky