async def METHOD_NAME(
    app: web.Application,
    wallet_id: WalletID,
    group_id: GroupID,
    *,
    read: bool,
    write: bool,
    delete: bool,
) -> WalletGroupGetDB:
    async with get_database_engine(app).acquire() as conn:
        result = await conn.execute(
            wallet_to_groups.update()
            .values(
                read=read,
                write=write,
                delete=delete,
            )
            .where(
                (wallet_to_groups.c.wallet_id == wallet_id)
                & (wallet_to_groups.c.gid == group_id)
            )
            .returning(literal_column("*"))
        )
        row = await result.first()
        if row is None:
            raise WalletGroupNotFoundError(
                reason=f"Wallet {wallet_id} group {group_id} not found"
            )
        return parse_obj_as(WalletGroupGetDB, row)