Agent-js raw response and certificate

Hey there!
I’m looking for a js code snippet to call a canister’s update method with agent-js and then retrieve both:

  • the response in raw format (non-parsed cbor encoded response);
  • the certificate (this is an update call, the response should be signed with a BLS signature).

(or maybe the certificate is a part of the response, idk)

My use-case is to let the user call one canister, then retrieve the response and let the user submit this response to another canister, so the latter could verify that the computations were performed.

Basically this is an inter-canister call but performed by an external client.

Thanks in advance!

See actor.ts in the agent source at line 354:

There you can see how the update call is made and the polling to get the response. As far as I can see all methods you need are public and exported.