{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "@context": [
    "https://schemas.meta-aiml.org/v3.0.0/context.jsonld"
  ],
  "@id": "https://schemas.meta-aiml.org/v3.0.0/entity/business_services.json",
  "$id": "https://schemas.meta-aiml.org/v3.0.0/entity/business_services.json",
  "@type": "BusinessServices",
  "schemaVersion": "3.0.0",
  "aimlVersion": "3.0.0",
  "title": "Business Services Entity Schema",
  "description": "v3 schema for digital B2B service platforms that provide operational business workflows directly to organizations through managed software and process automation.",
  "examples": [
    {
      "description": "Business operations platform with vendor onboarding and workflow automation",
      "reference": "business_services_example_operations"
    },
    {
      "description": "B2B back-office services platform with analytics and enterprise integrations",
      "reference": "business_services_example_backoffice"
    }
  ],
  "type": "object",
  "additionalProperties": false,
  "allOf": [
    {
      "$ref": "../ontology/digital_entity.json"
    },
    {
      "$ref": "../archetypes/direct_service.json"
    }
  ],
  "properties": {
    "@type": {
      "const": "BusinessServices"
    },
    "ontologicalMode": {
      "const": "DigitalEntity"
    },
    "interactionArchetype": {
      "type": "array",
      "contains": {
        "const": "DirectService"
      },
      "items": {
        "type": "string",
        "enum": [
          "DirectService"
        ]
      }
    },
    "domain": {
      "const": "B2B"
    },
    "businessModel": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "Subscription",
          "EnterpriseLicense",
          "UsageBased"
        ]
      }
    },
    "deliveryFormat": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "WebApp",
          "API",
          "MobileApp"
        ]
      }
    },
    "name": {
      "$ref": "../components/multilingual_format.json#/$defs/LocalizedText"
    },
    "description": {
      "$ref": "../components/multilingual_format.json#/$defs/LocalizedText"
    },
    "shortDescription": {
      "$ref": "../components/multilingual_format.json#/$defs/LocalizedTextOrString"
    },
    "url": {
      "type": "string",
      "format": "uri"
    },
    "foundingDate": {
      "type": "string",
      "format": "date"
    },
    "properties": {
      "type": "object",
      "properties": {
        "serviceCategory": {
          "type": "string",
          "enum": [
            "operations",
            "procurement",
            "finance",
            "hr",
            "compliance"
          ]
        },
        "tenantModel": {
          "type": "string",
          "enum": [
            "single_tenant",
            "multi_tenant",
            "hybrid"
          ]
        },
        "supportsSso": {
          "type": "boolean"
        },
        "supportsRoleBasedAccess": {
          "type": "boolean"
        },
        "supportsAuditLogging": {
          "type": "boolean"
        },
        "dataResidencySupport": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "contactPoints": {
          "type": "array",
          "items": {
            "$ref": "../components/common_defs.json#/$defs/ContactPoint"
          }
        },
        "socialProfiles": {
          "type": "array",
          "items": {
            "$ref": "../components/common_defs.json#/$defs/SocialProfile"
          }
        },
        "identifiers": {
          "type": "array",
          "items": {
            "$ref": "../components/common_defs.json#/$defs/Identifier"
          }
        }
      }
    },
    "capabilities": {
      "type": "object",
      "required": [
        "interaction"
      ],
      "properties": {
        "interaction": {
          "$ref": "../components/capability_groups.json#/$defs/InteractionCapabilities"
        },
        "content": {
          "$ref": "../components/capability_groups.json#/$defs/ContentCapabilities"
        },
        "financial": {
          "$ref": "../components/capability_groups.json#/$defs/FinancialCapabilities"
        },
        "commerce": {
          "$ref": "../components/capability_groups.json#/$defs/CommerceCapabilities"
        }
      }
    },
    "modules": {
      "type": "object",
      "properties": {
        "onboarding": {
          "type": "object",
          "properties": {
            "migrationToolsEnabled": {
              "type": "boolean"
            },
            "guidedSetupEnabled": {
              "type": "boolean"
            }
          }
        },
        "integrations": {
          "type": "object",
          "properties": {
            "prebuiltConnectorsCount": {
              "type": "integer",
              "minimum": 0
            },
            "webhookSupport": {
              "type": "boolean"
            },
            "apiRateLimitTiering": {
              "type": "boolean"
            }
          }
        },
        "reporting": {
          "type": "object",
          "properties": {
            "dashboardTemplatesCount": {
              "type": "integer",
              "minimum": 0
            },
            "scheduledReportsEnabled": {
              "type": "boolean"
            },
            "dataExportFormats": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          }
        }
      }
    },
    "structuralMetadata": {
      "type": "object",
      "properties": {
        "topology": {
          "const": "binary"
        },
        "roles": {
          "const": [
            "user",
            "platform"
          ]
        },
        "valueSource": {
          "const": "platform_provided"
        },
        "transactionFlow": {
          "const": "direct"
        },
        "networkEffects": {
          "const": "none"
        },
        "deliveryOrientation": {
          "type": "string",
          "enum": [
            "self_service",
            "assisted_service",
            "managed_service"
          ]
        }
      }
    },
    "targetAudience": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "siteCapabilities": {
      "type": "object",
      "properties": {
        "supportedDevices": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "desktop",
              "mobile",
              "tablet"
            ]
          }
        },
        "languages": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "accessibilityFeatures": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    }
  },
  "required": [
    "@type",
    "ontologicalMode",
    "interactionArchetype",
    "domain",
    "name",
    "description",
    "deliveryFormat",
    "capabilities",
    "structuralMetadata",
    "modules"
  ],
  "validationMetadata": {
    "schemaVersion": "3.0.0",
    "phase": "entity",
    "status": "draft",
    "lastValidated": "2026-02-20T12:00:00Z",
    "validator": "META-AIML QA"
  },
  "semanticAnnotations": {
    "classificationRationale": "BusinessServices is DigitalEntity because service delivery occurs through software channels independent of physical location. DirectService applies because the platform directly provides workflows and tooling to business users.",
    "disambiguationNotes": "Different from marketplace-style B2B exchanges where platform mediates third-party transactions. This schema models first-party service delivery."
  },
  "governanceMetadata": {
    "entityVersion": "3.0.0",
    "introducedIn": "META-AIML v3.0.0",
    "stabilityLevel": "draft",
    "sdkValidationRules": [
      "RULE-BSERV-001: @type MUST equal \"BusinessServices\"",
      "RULE-BSERV-002: ontologicalMode MUST equal \"DigitalEntity\"",
      "RULE-BSERV-003: interactionArchetype MUST contain \"DirectService\"",
      "RULE-BSERV-004: capabilities.interaction MUST be present",
      "RULE-BSERV-005: structuralMetadata.topology MUST equal \"binary\"",
      "RULE-BSERV-006: structuralMetadata.valueSource MUST equal \"platform_provided\""
    ]
  }
}
