Skip to content
This repository was archived by the owner on Apr 6, 2026. It is now read-only.
This repository was archived by the owner on Apr 6, 2026. It is now read-only.

Provide dumps() method #99

Description

@krismeister

The current docs do not give an example of serialization support for JSON.

I attempted to use Marshmallow's dumps feature

db.MyModel.Schema.dumps(someInstanceOfMyModel)
# throws this error:
TypeError: dumps() missing 1 required positional argument: 'obj' marshmallow

But received an error. I am currently using someInstanceOfMyModel._raw to get the data for JSON output.

Feature Request
Add a expose a dumps method to get a dict.

db.MyModel.dumps(someInstanceOfMyModel)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions