Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Postman SSE Support does not work #47

Closed
hburrichter opened this issue Feb 27, 2023 · 2 comments
Closed

Postman SSE Support does not work #47

hburrichter opened this issue Feb 27, 2023 · 2 comments

Comments

@hburrichter
Copy link

hburrichter commented Feb 27, 2023

First of all, thank you for the great repository!

Postman recently gained support for SSE and it works as expected for some SSE endpoints I found online.

However, I tried to implement a Server-Sent Events endpoint using FastAPI/Starlette with the built-in Starlette StreamingResponse and your SSE-Startlette GitHub repo and neither of them produced the new streaming UI in Postman.

Any Idea on what might be the cause?

(tested it with your "usage" code from the repo readme)

@hburrichter
Copy link
Author

Related to this issue:
postmanlabs/postman-app-support#11753

Setting the header manually to:

return EventSourceResponse(
            content=...,
            headers={
                'content-type': 'text/event-stream',
            }
        )

fixes the issue.

@sysid
Copy link
Owner

sysid commented Feb 27, 2023

Thanks @hburrichter for this insight. I probably should update the README accordingly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants