Is there any support for ByteArray? #1159
Answered
by
srinivasankavitha
shadikkhan
asked this question in
Q&A
-
|
I have REST API which is returning ByteArray (an image). now I am converting that to graphql using DGS but so far did not figure out how to handle this byte array response. Any help is highly appreciated. Thank |
Beta Was this translation helpful? Give feedback.
Answered by
srinivasankavitha
Jul 19, 2022
Replies: 1 comment
-
|
We don't have any special support built into the framework for byte arrays. However, you can implement a custom scalar, e.g. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
shadikkhan
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We don't have any special support built into the framework for byte arrays. However, you can implement a custom scalar, e.g.
ByteArrayand specify how it should be serialized/deserialized: https://netflix.github.io/dgs/scalars/That could work in your case.