Closed
Description
Currently, only type: string
+ format: binary
is supported, and represents raw data (an octet stream).
OpenAPI also supports base64-encoded data, represented as the following JSON schema:
type: string
format: byte
The generated type for it should also be Foundation.Data
(same as for format: binary
), but as part of serialization/deserialization, the extra step of base64 coding needs to be added.
Testing: verify that both a whole request/response body being application/json
with the contents of a base64-encoded string (use case 1), but also as a nested field in a JSON object (use case 2), both are pretty common.