pub fn parse_envelope_document_for(
body: &Value,
expected_thread_id: &str,
) -> Option<TrustTask<Value>>Expand description
Parse a DIDComm envelope body into the document it carries, only if
that document is threaded to expected_thread_id.
None covers both “not a Trust Task document” and “a Trust Task document
belonging to some other exchange”; in either case it is not an answer to
the request you are waiting on, and the correct action is to keep waiting.