restapi.rest.response.ExtendedJSONEncoder.dump

ExtendedJSONEncoder.dump(obj, fp, **kwargs)

Serialize data as JSON and write to a file.

Parameters:
  • obj (Any) – The data to serialize.

  • fp (IO[str]) – A file opened for writing text. Should use the UTF-8 encoding to be valid JSON.

  • kwargs (Any) – May be passed to the underlying JSON library.

Return type:

None