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

Endpoint returning an image #92

Open
joakim-emagine opened this issue Jul 2, 2020 · 1 comment
Open

Endpoint returning an image #92

joakim-emagine opened this issue Jul 2, 2020 · 1 comment

Comments

@joakim-emagine
Copy link

Has anyone has any luck with an endpoint that returns an image?
I get the error:

Argument 2 passed to Muffin\Webservice\Webservice\Webservice::_transformResource() must be of the type array, null given, called in .../vendor/muffin/webservice/src/Webservice/Webservice.php
@davidyell
Copy link
Collaborator

davidyell commented Jul 3, 2020

You might have more luck returning it as a string. Use something like a base64 encode to convert it to a string and then it could be returned in json, if you're web service responds with json.

Otherwise I think an image would be returned as a response.

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