{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/apptio/json-schema/apptio-customer-schema.json",
  "title": "Customer",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/apptio-frontdoor-api-openapi.yml#/components/schemas/Customer",
  "required": [
    "name"
  ],
  "type": "object",
  "properties": {
    "domain": {
      "type": "string"
    },
    "createdBy": {
      "type": "string"
    },
    "updatedBy": {
      "type": "string"
    },
    "adDomain": {
      "type": "string"
    },
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "name": {
      "maxLength": 80,
      "minLength": 1,
      "type": "string"
    },
    "environments": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/Environment"
      }
    },
    "applications": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/CustomerApplication"
      }
    },
    "domainType": {
      "type": "string"
    },
    "external": {
      "type": "boolean"
    },
    "salesforce_id": {
      "type": "string"
    },
    "salesforce_name": {
      "type": "string"
    },
    "region": {
      "type": "string"
    },
    "csOwners": {
      "maxItems": 1,
      "minItems": 0,
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/User"
      }
    },
    "cso": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/CSContact"
      }
    },
    "csa": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/CSContact"
      }
    },
    "csm": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "$ref": "#/$defs/CSContact"
      }
    },
    "geo_location_block": {
      "uniqueItems": true,
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "ibm_identifiers": {
      "$ref": "#/$defs/IbmIdentifiers"
    },
    "customAuthAccessGroup": {
      "type": "string"
    }
  },
  "$defs": {
    "ApplicationEndpoint": {
      "type": "object",
      "properties": {
        "visibleDefaultRoles": {
          "uniqueItems": true,
          "type": "array",
          "writeOnly": true,
          "items": {
            "$ref": "#/$defs/Role"
          }
        },
        "visibleCustomRoles": {
          "uniqueItems": true,
          "type": "array",
          "writeOnly": true,
          "items": {
            "$ref": "#/$defs/CustomRole"
          }
        },
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "url": {
          "type": "string"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "environment_application_id": {
          "type": "string",
          "format": "uuid"
        },
        "environment_id": {
          "type": "string",
          "format": "uuid"
        },
        "application_id": {
          "type": "string",
          "format": "uuid"
        },
        "sequence": {
          "type": "integer",
          "format": "int32"
        },
        "visibleRoles": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "hiddenFromNav": {
          "type": "boolean"
        },
        "endpointGroup": {
          "$ref": "#/$defs/ApplicationEndpointGroup"
        }
      }
    },
    "ApplicationEndpointGroup": {
      "required": [
        "environmentId",
        "id",
        "name"
      ],
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "environmentId": {
          "type": "string",
          "format": "uuid"
        }
      }
    },
    "CSContact": {
      "type": "object",
      "properties": {
        "email": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      }
    },
    "CustomRole": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 50,
          "minLength": 1,
          "type": "string"
        },
        "permissions": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/Permission"
          }
        },
        "description": {
          "type": "string"
        },
        "environment": {
          "type": "string",
          "format": "uuid"
        }
      }
    },
    "CustomerApplication": {
      "type": "object",
      "properties": {
        "application": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "features": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/Feature"
          }
        }
      }
    },
    "Environment": {
      "type": "object",
      "properties": {
        "updatedBy": {
          "type": "string"
        },
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "applications": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/EnvironmentApplication"
          }
        },
        "customRoles": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/CustomRole"
          }
        },
        "customer": {
          "type": "string"
        },
        "createdBy": {
          "type": "string"
        },
        "external": {
          "type": "boolean"
        },
        "production": {
          "type": "boolean"
        },
        "ignoreDomainDefaultRole": {
          "type": "boolean"
        },
        "endpointGroups": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/ApplicationEndpointGroup"
          }
        },
        "environment_category": {
          "type": "string"
        },
        "category": {
          "type": "string"
        },
        "supportedLangs": {
          "uniqueItems": true,
          "type": "array",
          "readOnly": true,
          "items": {
            "type": "string"
          }
        },
        "lastAccessed": {
          "type": "string",
          "format": "date-time"
        },
        "oauthEnabled": {
          "type": "boolean"
        },
        "preventAuthorizedAccess": {
          "type": "boolean"
        }
      }
    },
    "EnvironmentApplication": {
      "type": "object",
      "properties": {
        "internalName": {
          "type": "string"
        },
        "applicationEntitlementStatus": {
          "type": "string"
        },
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "applicationId": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "applicationType": {
          "type": "string"
        },
        "applicationEndpoints": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/ApplicationEndpoint"
          }
        },
        "endpointGroup": {
          "$ref": "#/$defs/ApplicationEndpointGroup"
        },
        "entitlement_status": {
          "type": "string"
        },
        "provisioningMetadata": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          }
        },
        "hideNoAccess": {
          "type": "boolean"
        },
        "softDeleteDate": {
          "type": "string",
          "format": "date-time"
        },
        "features": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/Feature"
          }
        }
      }
    },
    "Feature": {
      "required": [
        "name"
      ],
      "type": "object",
      "properties": {
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "applicationTypes": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "IbmIdentifiers": {
      "type": "object",
      "properties": {
        "ICNs": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "mpp_ids": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "Permission": {
      "type": "object",
      "properties": {
        "validBefore": {
          "type": "string"
        },
        "name": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "validFrom": {
          "type": "string"
        },
        "applicationTypes": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "external": {
          "type": "boolean"
        },
        "defaultRoleOnly": {
          "type": "boolean"
        }
      }
    },
    "Role": {
      "required": [
        "name"
      ],
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "maxLength": 50,
          "minLength": 1,
          "type": "string"
        },
        "permissions": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/Permission"
          }
        },
        "description": {
          "type": "string"
        },
        "external": {
          "type": "boolean"
        },
        "grantable_by": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "$ref": "#/$defs/Role"
          }
        },
        "role_filtering": {
          "type": "string"
        },
        "roleAlwaysShown": {
          "type": "boolean"
        },
        "applicationTypes": {
          "uniqueItems": true,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "oauthSupportedScope": {
          "type": "string",
          "enum": [
            "ROLE_ONLY",
            "ROLE_AND_SCOPE"
          ]
        }
      }
    },
    "User": {
      "required": [
        "domain",
        "email",
        "login"
      ],
      "type": "object",
      "properties": {
        "accountTypeEnum": {
          "type": "string",
          "writeOnly": true,
          "enum": [
            "SERVICE",
            "STANDARD",
            "LOCAL",
            "OAUTH_CLIENT",
            "UNKNOWN"
          ]
        },
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "login": {
          "maxLength": 80,
          "minLength": 1,
          "type": "string"
        },
        "active": {
          "type": "boolean"
        },
        "full": {
          "type": "string"
        },
        "email": {
          "type": "string"
        },
        "persona": {
          "type": "string"
        },
        "forcePwdChange": {
          "type": "boolean"
        },
        "domain": {
          "type": "string"
        },
        "failedLoginCount": {
          "type": "integer",
          "format": "int32"
        },
        "lastSuccessfulLogin": {
          "type": "string",
          "format": "date-time"
        },
        "lastPasswordChange": {
          "type": "string",
          "format": "date-time"
        },
        "lastFailedLogin": {
          "type": "string",
          "format": "date-time"
        },
        "lastLoginOrApiKeyLogin": {
          "type": "string",
          "format": "date-time"
        },
        "createdBy": {
          "type": "string"
        },
        "createdOn": {
          "type": "string",
          "format": "date-time"
        },
        "updatedBy": {
          "type": "string"
        },
        "accountType": {
          "type": "string"
        },
        "external": {
          "type": "boolean"
        },
        "lockedUntil": {
          "type": "string",
          "format": "date-time"
        },
        "accountStatus": {
          "type": "string"
        },
        "ssoGroups": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "userEntitlements": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/UserEntitlement"
          }
        }
      }
    },
    "UserEntitlement": {
      "required": [
        "entitlementType",
        "entitlementValue"
      ],
      "type": "object",
      "properties": {
        "login": {
          "type": "string"
        },
        "entitlementType": {
          "type": "string"
        },
        "entitlementValue": {
          "type": "string"
        }
      }
    }
  }
}