Skip to content

Make expand instantiate classes within the calling object #30

Description

@cathoderay

Currently, if we do

product = builton.product().get(id="5d67c87ad661690e5f6250a6", expand="company")

we get

type(product.company) == dict

We could instantiate a new object instead of treating it like a dict. For that, we could use the _cls key in the dict expanded to decide which model we should use.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions