@classmethod
def parse(cls, json):
    """ Parse a JSON object into a model instance. """
    model = cls()
    for key, val in json.items():
        if key in cls._valid_properties:
            setattr(model, key, val)
    return model
