Exact probes of boundary conditions and flows in two-dimensional quantum field theories