How to fetch contract with contract id or key using GRPC java
EDIT: my answer is wrong, see the following one for the correct approach.
Correction to @stefanobaghino-da 's reply: In Daml 2.5 we introduced two new API methods GetEventsByContractId
and GetEventsByContractKey
which allow you to query a contract by Id or Key. These are currently only exposed by the lower level gPRC bindings for Java, not the rx-java layer. See getEventsByContractKey - #2 by bernhard.
See API reference docs here.