--- title: Stateful Scenarios shortTitle: Stateful Scenarios description: Model multi-step, stateful API behaviour in MockServer - state-machine scenarios, sequential / cycling responses, timed and externally-triggered transitions, and cross-protocol correlation - with runnable examples for every client. layout: page pageOrder: 2 section: 'Creating Mocks' subsection: true sitemap: priority: 0.8 changefreq: 'monthly' lastmod: 2026-06-24T00:00:00+00:00 keywords: stateful mock, scenario, state machine, capture rule, persist value across requests, sequential responses, cycling responses, responseMode, timed transition, trigger scenario, cross-protocol scenario, mockserver scenario, multi-step api mock --- {% include_subpage _includes/stateful_scenarios.html %}