> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usestatemachines.com/llms.txt
> Use this file to discover all available pages before exploring further.

# What is State Machines?

> Disposable environments of replica apps for integration tests and agents.

State Machines gives your code an isolated environment of replica apps. A replica implements a vendor's APIs, such as Salesforce. Your integration creates records, reads them, and tests failures against disposable data.

You create an environment, connect to an app, make native API calls, and delete the environment when the task ends. To repeat the task, create a fresh environment or start one from a snapshot of prepared data.

A replica never calls the vendor. Creating a Salesforce app does not connect to your company's Salesforce organization or import its records. [Resources and how they relate](/get-started/concepts) explains environments, apps, actors, and snapshots.

## Two APIs have different jobs

The State Machines management API creates environments, returns credentials, and manages snapshots. Your State Machines API key authenticates those calls within a workspace.

The app's native API handles your integration's work. For Salesforce, that includes record operations, SOQL queries, and supported Bulk and SOAP operations. Credentials identify both the environment and an actor inside the app. Your State Machines API key is never an app credential.

## Match the starting point to the task

| Your task | Start with | Verify |
| - | - | - |
| Make a first native app request | [The SDK quickstart](/get-started/quickstart) | The HTTP response and environment cleanup |
| Run an existing integration test | [An isolated test helper](/sdk-api/testing) | Your integration's assertions, with its base URL and credentials set to the replica |
| Repeat a scenario with prepared records | [A ready snapshot](/snapshots/reuse) | The restored records and independence between test environments |
| Let an agent exercise the integration | [Agent instructions](/get-started/agents) | The executed command, observed result, and cleanup outcome |
| Diagnose a failing run | [Requests and audit events](/environments/observability) | The failing app call separately from the management operation |

To use the same resources through the UI, follow [Run an environment in the dashboard](/get-started/dashboard).

## Know what a passing test proves

A passing test proves the assertions it ran against the selected replica version, settings, actor, and data. It does not prove that every feature of the vendor product behaves the same, or that the replica reproduces a customer's configuration.

Record the replica version, actor, and data with each result. Before testing customer-specific behavior, check [Salesforce known differences](/apps/known-differences) for the features it needs.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.