Negotiation activity and safe refresh

Pilot 0.6.5. Client-only improvement to the existing seven-second polling loop, not a new transaction service.

Existing authentication, role/case permissions, state transitions, fees and server checks remain authoritative. No API operation, database table, custody or external execution is added.

The source requirements and sequence below supplement the historical 0.5.3 baseline and the previous experience, follow-up, review and position addenda. Cumulative additions: 40 requirements and 4 diagrams; 23 physical tables and 62 API operations, unchanged. The old baseline PDF is not recertified.

ACT-01 · Explicit review of negotiation changes

Changes to an open shared case or contextual request produce a separate, persistent activity notice and a shortcut in the sticky search bar. They do not automatically replace the current terms, accept a proposal, submit a command, overwrite the typed draft or dismiss an operation error. Reviewing updates reuses the existing refresh action and its discard confirmation; cancelling preserves the screen.

ACT-02 · Scope and concurrency protection

Only one activity check runs at a time. The observer captures account, route, navigation epoch and loaded case/request revision. Late success/failure responses are ignored if the captured scope changed, a write/modal is active or the page is hidden. A completed local command changes the captured revision. Old responses must not replace the new account’s CSRF token or clock synchronization. Background list refresh rechecks edit/busy state before applying fetched data. Existing server authorization and atomic revision checks still decide every write.

ACT-03 · Connection failure and recovery

Failed checks show a non-destructive connection notice. Try again performs a read-only check without discarding the draft. Recovery removes the connection warning but leaves genuinely changed terms pending explicit review. Hidden pages, active write/review dialogs and logged-out contexts do not start another check. The nominal interval remains seven seconds, with no delivery or latency SLA; slow responses, paused pages and failures can delay detection. Drafts are browser memory only, not durable saves.

Sequence and evidence

Mermaid · Requirements JSON · QA results

sequenceDiagram
  actor Buyer
  actor Seller
  participant UI as Open negotiation and draft
  participant Observer as Existing periodic read observer
  participant API as Existing authorized API
  Seller->>API: Record a simulated counterproposal or message
  Observer->>Observer: Capture account, route, revision and navigation epoch
  Observer->>API: Authorized read, no user-activity extension
  API-->>Observer: Current permitted revision
  alt Scope changed, page hidden, modal or write active
    Observer->>Observer: Ignore late response; no concurrent check
  else Current context and newer activity
    Observer-->>UI: Notice and review shortcut; preserve draft and old terms
    Buyer->>UI: Choose review
    alt Keep draft
      UI-->>Buyer: Existing screen unchanged
    else Confirm refresh
      UI->>API: Existing fresh authorized reads
      API-->>UI: Latest permitted terms and conversation
    end
  else Read fails
    Observer-->>UI: Connection notice; keep draft
    Buyer->>Observer: Try again, read only
  end
  Note over UI,API: No automatic acceptance, custody, settlement or fee collection

Only matching-version executed results establish what was tested. Native Safari, physical devices, external security and actual participant comprehension require separate validation.