An accepted action is still pending
Handle provider acceptance without reporting completion, and distinguish pending approval from a pending external result.
An API can accept work before the external operation finishes. Your agent should report what is known now, not turn acceptance into a completed refund. Track the existing operation until its supported completion evidence arrives.
There are several kinds of waiting in an action workflow: waiting for approval, waiting for dispatch, and waiting for a provider that accepted the operation but has not finished. Anlyon's effect stage, outcome and grade expose different parts of that state. Pending is not a completed receipt.
Keep waiting states explicit
| State | Useful application message |
|---|---|
| Pending approval | The request needs a decision and has not completed |
| Provider result pending | The provider accepted the operation; completion is not established |
| Unknown | Evidence cannot establish what happened; do not recreate the operation |
| Confirmed | The defined outcome has supporting read-back evidence |
Do not map all four to a boolean success field. A customer-facing message should distinguish "refund requested" from "refund completed."
Poll the record, not the write
Store the invocation or effect identifier in durable application state. Refresh that record with bounded polling or the supported observation mechanism. Repeatedly invoking the action with fresh keys is not polling; it creates new business operations.
Choose an application wait timeout independently from the provider's completion deadline. When your UI stops waiting, preserve the operation and provide an operator route. A closed browser tab should not erase the reconciliation task.
Check the adapter's actual completion model
The Stripe refund adapter tracks a pending refund through bounded read-back attempts. Resend acceptance and send-record confirmation do not establish inbox delivery, bounces or later complaints. A declared action records the HTTP result and any configured verification; it does not automatically understand a provider's asynchronous job lifecycle.
Design your workflow around the evidence the selected adapter supplies. If a business task needs a later state, implement an explicit observation step with its own correlation and failure handling.
Read effect outcomes and receipt grades. Use structured tool results to keep these distinctions visible to the model.
