> ## 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.

# Snapshots

> Save environment data and start new environments from it.

export const StateDocs = ({section, title, articles}) => {
  const stateSections = [{
    id: 'get-started',
    title: 'Get started',
    description: 'Create an environment, call Salesforce, and hand the setup to an agent.',
    eyebrow: 'Start here'
  }, {
    id: 'environments',
    title: 'Environments',
    description: 'Create, connect to, pause, and delete environments, and manage access.',
    eyebrow: 'Run app replicas'
  }, {
    id: 'snapshots',
    title: 'Snapshots',
    description: 'Save environment data and start new environments from it.',
    eyebrow: 'Reuse prepared data'
  }, {
    id: 'apps',
    title: 'Apps',
    description: 'Salesforce APIs, records, queries, Bulk API 2.0, and known differences.',
    eyebrow: 'Replica reference'
  }, {
    id: 'sdk-api',
    title: 'SDK and API',
    description: 'Configure the TypeScript client and call the management API.',
    eyebrow: 'Client and endpoints'
  }, {
    id: 'troubleshooting',
    title: 'Troubleshooting',
    description: 'Diagnose access errors, startup failures, failed requests, and missing data.',
    eyebrow: 'Fix a failure'
  }];
  function renderObjects({section}) {
    switch (section) {
      case 'get-started':
        return <g className="state-shelf-object">
            <path d="M68 157V43l72-17 68 17v114" fill="var(--state-surface)" />
            <path d="m68 43 72 18 68-18M140 61v96M79 57v88M91 61v84" />
            <path d="m152 82 35-9m-35 21 35-9m-35 21 24-6" />
            <path d="M113 19h40v26l-20-6-20 6Z" fill="var(--state-background)" />
            <path d="m173 134 8 6 13-20" />
          </g>;
      case 'environments':
        return <g className="state-shelf-object">
            <path d="m65 96 62-32 61 32v64l-61 32-62-32Z" fill="var(--state-surface)" />
            <path d="m65 96 62 32 61-32m-61 32v64M89 84l62 32" />
            <path d="m149 55 38-20 39 20v41l-39 20-38-20Z" fill="var(--state-surface)" />
            <path d="m149 55 38 20 39-20m-39 20v41" />
            <path d="m98 135 14 7v15l-14-7Z" fill="var(--state-foreground)" stroke="none" />
            <path d="m202 81 11-6m-11 13 11-6" />
          </g>;
      case 'snapshots':
        return <g className="state-shelf-object">
            <path d="m55 130 91-33 99 35-90 36Z" fill="var(--state-surface)" />
            <path d="M55 130v17l100 36 90-35v-16m-90 36v15" />
            <path d="m55 104 91-33 99 35-90 36Z" fill="var(--state-surface)" />
            <path d="M55 104v16l100 36 90-35v-15m-90 36v14" />
            <path d="m55 78 91-33 99 35-90 36Z" fill="var(--state-surface)" />
            <path d="M55 78v16l100 36 90-35V80m-90 36v14" />
            <path d="m105 77 40-14 42 15-39 15Z" />
            <path d="m113 81 24-9 30 11" />
            <path d="m68 86 12 5m-12 21 12 5m-12 22 12 5" />
          </g>;
      case 'apps':
        return <g className="state-shelf-object">
            <path d="M68 154V39h70v115Z" fill="var(--state-surface)" />
            <path d="M79 50h47v18H79Zm0 30h47m-47 10h33m-33 10h39m-39 10h24" />
            <path d="m142 154-15-87 65-12 15 99" fill="var(--state-surface)" />
            <path d="m141 82 39-7m-36 21 39-7m-36 21 26-5" />
            <path d="M178 155V94h49v61" fill="var(--state-surface)" />
            <path d="M189 106h26v25h-26Zm0 34h26" />
            <path d="M91 124h23v23H91Z" fill="var(--state-foreground)" stroke="none" />
          </g>;
      case 'sdk-api':
        return <g className="state-shelf-object">
            <path d="M51 153V48h189v105" fill="var(--state-surface)" />
            <path d="M51 67h189M65 58h2m7 0h2m7 0h2" />
            <path d="m91 87-17 17 17 17m109-34 17 17-17 17m-54-36-11 38" strokeWidth="2" />
            <path d="M109 103h13m37 0h15m-95 34h53m12 0h47" />
            <path d="M63 153v-6h164v6" />
          </g>;
      case 'troubleshooting':
        return <g className="state-shelf-object">
            <path d="M70 157V41h112l20 20v96" fill="var(--state-surface)" />
            <path d="M182 41v20h20M86 62h62M86 78h79M86 91h58M86 104h40M86 117h26" />
            <circle cx="167" cy="115" r="32" fill="var(--state-surface)" />
            <circle cx="167" cy="115" r="24" />
            <path d="m190 139 26 26 10-10-26-26" fill="var(--state-surface)" />
            <path d="m154 115 9 9 17-20" />
            <path d="M86 137h33" />
          </g>;
    }
  }
  function renderIllustration({section, cabinet = false}) {
    return <svg className="state-section-illustration" viewBox="0 0 300 220" fill="none" stroke="currentColor" strokeWidth="1.2" strokeLinejoin="round" aria-hidden="true">
        {renderObjects({
      section
    })}
        {cabinet && <g className="state-drawer">
            <path d="m27 153 27-14h192l27 14v58H27Z" fill="var(--state-surface)" />
            <path d="M27 153h93v6h60v-6h93M27 211h246M35 161v41m230-41v41" />
            <path d="M136 170h28" />
          </g>}
      </svg>;
  }
  function renderShelf() {
    return <nav className="state-shelf not-prose" aria-label="Browse documentation">
        <svg className="state-cabinet" viewBox="0 0 960 490" preserveAspectRatio="none" fill="none" stroke="currentColor" strokeWidth="1.1" aria-hidden="true">
          <path d="M1 1h958v488H1Z" />
          <path d="M8 8h944v474H8Z" />
          <path d="m8 8 64 39h832l48-39M64 47v388l-56 47m896-435v388l48 47M64 435h840M8 246h944M8 253h944M64 210h840l48 36M64 210l-56 36" />
        </svg>
        {stateSections.map(section => <a className="state-shelf-link" href={`/${section.id}`} key={section.id}>
            {renderIllustration({
      section: section.id,
      cabinet: true
    })}
            <span className="state-shelf-label">
              {section.title}
              <span aria-hidden="true">↗</span>
            </span>
          </a>)}
      </nav>;
  }
  function renderCategory({section, title, articles}) {
    return <div className="state-category-layout not-prose">
        <div className="state-category-art">
          {renderIllustration({
      section
    })}
          <span className="state-category-art-caption">{title}</span>
        </div>
        <nav className="state-category-articles" aria-label={`${title} articles`}>
          {articles.map(article => <a href={article.href} key={article.href}>
              <div>
                <h2>{article.title}</h2>
                <p>{article.description}</p>
              </div>
              <svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="1.5" aria-hidden="true">
                <path d="M7 17 17 7M7 7h10v10" />
              </svg>
            </a>)}
        </nav>
      </div>;
  }
  return section ? renderCategory({
    section,
    title,
    articles
  }) : renderShelf();
};

<StateDocs section="snapshots" title="Snapshots" description="Save environment data and start new environments from it." articles={[{"title":"Save prepared data in a snapshot","description":"Save all apps in a running environment as reusable starting data.","href":"/snapshots/create"},{"title":"Start tests from the same snapshot","description":"Create independent environments from saved data and manage the fixture lifecycle.","href":"/snapshots/reuse"}]} />


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