{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/remote-com/json-schema/remote-com-subscription-envelope-schema.json",
  "title": "SubscriptionEnvelope",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/remote-com-contractor-subscriptions-api-openapi.yml#/components/schemas/SubscriptionEnvelope",
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "subscription": {
          "$ref": "#/$defs/Subscription"
        }
      }
    }
  },
  "$defs": {
    "Subscription": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "employment_id": {
          "type": "string",
          "format": "uuid"
        },
        "plan": {
          "type": "string",
          "enum": [
            "standard",
            "plus",
            "cor"
          ]
        },
        "status": {
          "type": "string",
          "enum": [
            "pending",
            "active",
            "canceled",
            "terminated"
          ]
        },
        "starts_on": {
          "type": "string",
          "format": "date"
        },
        "ends_on": {
          "type": [
            "string",
            "null"
          ],
          "format": "date"
        }
      }
    }
  }
}