Update query to add new attribute and its value in existing document

Not sure what do u mean pass. I am not expert on those tools. cc @binh.le

There is many ways to do this. Even you can insert your input into bucket as temporary key.
USE MERGE option from temp key and actual documents

Best approach is described here Query to insert new document from an existing document through named parameter

Got you.

By pass through, I meant calling Couchbase REST API and pass the named parameter as API Input parameter.

Thanks

REST API you can do. My only concern is your use case of 3M+ documents, the parameter size can be 20M+ bytes. Mutating may take long time, may get errors, timeouts. Don’t want to try already mutated documents.
Keep in all these approach suggested in other post will be reasonable.