Firestore doesn't support so-called update queries, where you pass the conditions and the new values in a single API call. So you'll have to indeed first execute the query, and then update each document as you do now.
Also see: