All Actions URI routes support returning data to the sender via callback URLs. You can specify these by passing x-success and x-error parameters in your initial request.
When the requested action completes, Actions URI will construct a new URL using the base URL provided in your parameter, appending any existing path or parameters, and then adding the result data as new search parameters prefixed with result-.
Success Callbacks
- Base URL: Provided via the
x-success parameter. - Data Payload: Parameters are prefixed with
result- (e.g., result-body, result-filepath). Note that the specific keys returned depend on the endpoint being called.
Error Callbacks
- Base URL: Provided via the
x-error parameter. - Error Payload: Always contains
errorCode (an HTTP status) and errorMessage (a descriptive string).
To correlate callbacks with specific requests in production, include a unique identifier (like a request-id) in your x-success or x-error base URL.
obsidian://actions-uri/note/get
?file=My%20super%20note
&x-success=my-app%3A%2F%2Fsuccess%3Frequest-id%3D123456789
&x-error=my-app%3A%2F%2Ferror