Automatically Adding `_tag` Field in Schema with TaggedClass

Is there a way of automagically adding a
_tag
field to a decoded response with Schema?
I thought that a schema like the following would have do it automatically but I'm getting a UserProofOfIdentity (Encoded side)\n └─ [\"_tag\"]\n └─ is missing"} fiber failure so I guess not 🤦‍♂️
export class UserProofOfIdentity extends Schema.TaggedClass<UserProofOfIdentity>()("UserProofOfIdentity", {
    proofType: ProofURNToType.members[4],
    id: Schema.String.pipe(Schema.brand("ProofId")),
    status: UserProofStatus,
    createdAt: Schema.Date,
    updatedAt: Schema.Date,
    workflows: Schema.NonEmptyArray(UserWorkflow),
}) {}
Was this page helpful?