{
  "artifact": {
    "bytes": 53820,
    "format": "json",
    "mediaType": "application/json",
    "path": "samples/states/stripe/subscription-lifecycle/state.json",
    "sha256": "cbfc7899bcff3e2cb2cf7b5c4c5553348817c92ede6e42f5fc3388e2195dd696"
  },
  "capabilities": {
    "limitations": [
      "No real money movement and no guarantee beyond the published route surface."
    ],
    "required": [
      "state.read",
      "state.load",
      "state.reset",
      "rest.customers"
    ],
    "supportedSurface": "Stateful customers, products, payments, invoices, subscriptions, refunds, and modeled platform resources."
  },
  "category": "workflow",
  "displayName": "Stripe subscription lifecycle workflow",
  "entityCounts": {
    "collections": {
      "accounts": 1,
      "balanceTransactions": 5,
      "charges": 12,
      "checkoutSessions": 0,
      "coupons": 2,
      "customers": 8,
      "disputes": 0,
      "events": 0,
      "invoiceItems": 15,
      "invoices": 10,
      "meterEvents": 0,
      "meters": 0,
      "paymentIntents": 0,
      "paymentLinks": 0,
      "paymentMethods": 8,
      "prices": 6,
      "products": 3,
      "promotionCodes": 2,
      "refunds": 1,
      "setupIntents": 0,
      "subscriptions": 8,
      "taxRates": 0,
      "testClocks": 0,
      "usageRecords": 0,
      "usageRecordSummaries": 0,
      "webhookEndpoints": 1
    },
    "total": 82
  },
  "environmentId": "stripe",
  "expectedDiff": {
    "changedPathsInclude": [
      "refunds",
      "charges",
      "balanceTransactions",
      "events"
    ],
    "exact": false,
    "notes": "Hosted promotion must observe every listed path after the provider-native mutation; dynamic provider ids and timestamps are excluded from exact matching."
  },
  "expectedFirstRead": {
    "body": null,
    "expectedStatus": [
      200
    ],
    "method": "GET",
    "operationId": "getSuccessfulCharge",
    "path": "/v1/charges/ch_happy_apr",
    "transport": "provider-rest"
  },
  "id": "stripe.subscription-lifecycle.v1",
  "provenance": {
    "authoredBy": "archal",
    "kind": "derived-fixture",
    "sanitizationNotes": [
      "Replaced 10 credential-shaped or non-example email value(s).",
      "Replacement paths: accounts.0.email (email-domain), customers.0.email (email-domain), customers.1.email (email-domain), customers.2.email (email-domain), customers.3.email (email-domain), customers.4.email (email-domain), customers.5.email (email-domain), customers.6.email (email-domain), customers.7.email (email-domain), webhookEndpoints.0.secret"
    ],
    "sourcePath": "clones/stripe/seeds/subscription-lifecycle.json",
    "sourceSha256": "e5da6159c25e87e72439b6b7568ed14fd10fdc1cbe2463c6defe3aea0a7bfb92",
    "transformationNotes": [
      "Copied the complete pinned clones/stripe/seeds/subscription-lifecycle.json state without dropping or slicing entities.",
      "Canonicalized object-key ordering for byte-stable public output."
    ]
  },
  "purpose": "Inspect a successful subscription charge, issue a partial customer-requested refund, and verify the related charge and ledger state reset.",
  "qualification": {
    "candidate": {
      "basis": "catalog-admission",
      "status": "passed"
    },
    "certification": {
      "evidencePath": null,
      "lastHostedVerificationAt": null,
      "runtimeBundleDigest": null,
      "sourceCommit": null,
      "status": "unknown"
    },
    "isolation": {
      "lastVerifiedAt": null,
      "status": "unknown"
    },
    "reset": {
      "expected": "restores-loaded-sample",
      "lastVerifiedAt": null,
      "status": "unknown"
    },
    "validation": {
      "checks": [
        "artifact-hash",
        "historical-source-lock",
        "state-contract",
        "scenario-semantics",
        "relationship-closure",
        "secret-scan",
        "size-limit"
      ],
      "status": "passed",
      "validator": "archal.environment-samples.v1"
    }
  },
  "representativeMutation": {
    "body": {
      "amount": 4900,
      "charge": "ch_happy_apr",
      "reason": "requested_by_customer"
    },
    "expectedStatus": [
      200
    ],
    "method": "POST",
    "operationId": "createPartialCustomerRefund",
    "path": "/v1/refunds",
    "transport": "provider-rest"
  },
  "schema": "archal.environment-sample",
  "schemaVersion": 1,
  "slug": "subscription-lifecycle",
  "stateContract": {
    "format": "json",
    "schema": "archal.environment-state.stripe",
    "version": 1
  }
}
