Skip to main content

Module back_reference

Module back_reference 

Source
Expand description

RFC 8620 §3.7 back-reference resolution for JMAP method call batches.

When a JMAP request contains multiple method calls, later calls may reference the results of earlier calls using ResultReference objects. Any argument value that is a JSON object of the form

{ "#refKey": { "resultOf": "call-id", "name": "Method/name", "path": "/json/pointer" } }

is resolved by the dispatcher before invoking the method. The #refKey argument is replaced with the value extracted from the referenced response body using the RFC 6901 JSON Pointer in path.

Structs§

ResultReference
A RFC 8620 §3.7 result reference embedded inside a method call argument.

Enums§

BackRefError
Error variants returned when a back-reference cannot be resolved.

Functions§

resolve_back_references
Walk args and resolve every #key result-reference in-place.