{
  "factory": {
    "parent": "abstract-service",
    "description": "",
    "id": "service-components",
    "label": "service,rest",
    "type": "entaxy.runtime.service.component",
    "category": "",
    "isAbstract": true
  },
  "entaxy.runtime.service.component": {
  },
  "fields": {
  },
  "outputs": {
    "init": {
      "isDefault": true,
      "fields": {
      }
    },
    "schemaBasedService": {
      "fields": {
        "schemaUrl": {
          "displayName": "Schema URL",
          "description": "The resource on which the current service is based.",
          "type": "Url",
          "group": "schema",
          "required": true,
          "@TYPEINFO": {
            "resourceProvider": "schemas",
            "filter": "*.yaml",
            "target": "resource"
          }
        }
      }
    },
    "schemaResourceBasedService": {
      "fields": {
        "@IMPORT": [
          {
            "sourceFactoryId": "#",
            "location": "outputs.schemaBasedService.fields",
            "prefix": ""
          }
        ],
        "schemaUrl": {
          "@TYPEINFO": {
            "resourceProvider": "schemas",
            "filter": "*.schema",
            "target": "resource"
          }
        },
        "##publish": {
          "defaultValue": {
            "@INHERIT": {
              "resources": "append"
            },
            "resources": [
              {
                "@CALCULATED": {
                  "lazy": false,
                  "expression": "${properties.schemaUrl};runtime"
                }
              }
            ]
          }
        }
      }
    },
    "specificProtectedServiceComponents": {
      "fields": {
        "connectorDispatchingBeans": {
          "type": "entaxy.runtime.service.component",
          "isRef": true,
          "required": true,
          "isHidden": true,
          "isRefByValueOnly": true,
          "@INTERNAL": true,
          "defaultValue": {
            "factoryId": "service-components",
            "type": "entaxy.runtime.service.component",
            "outputType": "connectorDispatchingBeans",
            "scope": "private",
            "properties": {
              "serviceId": {
                "@CALCULATED": {
                  "lazy": false,
                  "expression": "${#OWNER#.objectId}"
                }
              }
            }
          }
        }
      }
    },
    "connectorDispatchingBeans": {
      "scopes": [
        "private"
      ],
      "fields": {
        "serviceId": {
          "type": "String"
        }
      },
      "config": {
        "configurable": false,
        "@SKIP_PUBLISH": {}
      }
    },
    "serviceSecurity": {
      "scopes": [
        "private"
      ],
      "fields": {
        "authorizationType": {
          "displayName": "Authorization Type",
          "description": "The type of authorization used to access the service. <br/> JAAS: Provides authorization using Java Authentication and Authorization Service (JAAS), which supports management of multiple realms; <br/> OAUTH STAND ALONE: Provides stand-alone authorization using locally managed keys and settings, independent of external services (OAuth2); <br/> OAUTH INTROSPECT: Provides verification and validation of access tokens by calling the introspection endpoint to obtain information about the token and its state (OAuth2). <br/> For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/security.html\">Entaxy docs</a>",
          "type": "string",
          "required": true,
          "group": "security",
          "defaultValue": "JAAS"
        },
        "authorizationRealm": {
          "displayName": "Authorization realm",
          "type": "entaxy.security.jaas.realm",
          "description": "Defines an authorization realm for the service and associates it with the corresponding security settings. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/security-jaas.html\">Entaxy docs</a>",
          "required": false,
          "group": "security",
          "__defaultValue": "karaf",
          "__filter": {
            "label": "*"
          },
          /* "importPrefix": "camel_", */
          "immutable": false,
          "isRef": true,
          "isRefByValueOnly": true,
          "resolveAlways": true,
          "refField": "objectId",
          "@TYPEINFO": {
            "enablePrivateObjectCreation": false,
            "updateParentFields": true,
            "isEmptyIncluded": true
          },
          "@UI": {
            "displayBlocks": [
              "JAAS"
            ],
            "required": true
          }
        },
        "displayServiceSchema": {
          "description": "Enables public access to the service schema regardless of authentication.",
          "displayName": "Public Service Schema",
          "type": "Boolean",
          "group": "security",
          "required": true,
          "defaultValue": false,
          "@UI": {
            "displayBlocks": [
              "JAAS",
              "OAUTH STAND ALONE",
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "restrictByRoles": {
          "displayName": "Restrict access by roles",
          "description": "Enables to restrict access to the service based on roles. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/security-jaas.html\">Entaxy docs</a>",
          "type": "boolean",
          "required": false,
          "group": "security",
          "defaultValue": false,
          "@UI": {
            "displayBlocks": [
              "JAAS",
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "globalRoles": {
          "displayName": "Roles allowed to access",
          "description": "List of roles that are allowed to access the service. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/security-jaas.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "group": "security",
          "condition": "${restrictByRoles}",
          "defaultValue": "*",
          "@UI": {
            "displayBlocks": [
              "JAAS",
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "jwtAuthzFilterRegexp": {
          "defaultValue": "\\W+",
          "displayName": "Regexp for jwt auth filter",
          "description": "Regexp for jwt auth filter. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "jwtAuthzFilterRoleClaim": {
          "defaultValue": "roles",
          "displayName": "Role claims for jwt auth filter",
          "type": "String",
          "isHidden": true,
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "jwtAuthzFilterValidateAudience": {
          "defaultValue": "false",
          "displayName": "Validate audience for jwt auth filter",
          "type": "Boolean",
          "isHidden": true,
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "jwtKeystore": {
          "displayName": "Keystore",
          "description": "Keystore used for token verification. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/keystores.html\">Entaxy docs</a> and <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "Url",
          "required": false,
          "group": "security",
          "@TYPEINFO": {
            "resourceProvider": "entaxy-keystore",
            "filter": [
              "*.jks",
              "*.pkcs12",
              "*.jwk"
            ],
            "target": "resource"
          },
          "@UI": {
            "displayBlocks": [
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "jwtAlias": {
          "displayName": "Jwt Alias",
          "description": "The alias of the certificate from the selected keystore. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/keystores.html\">Entaxy docs</a> and <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "group": "security",
          "@TYPEINFO": {
            "type": "list",
            "source": {
              "property": "jwtKeystore",
              "sourceType": "resource",
              "path": "#metadata#.keystore.aliases",
              "type": "property"
            },
            "dependsOn": ["jwtKeystore"]
          },
          "@UI": {
            "displayBlocks": [
              "OAUTH STAND ALONE"
            ],
            "required": true
          }
        },
        "audienceIsEndpointAddress": {
          "defaultValue": "false",
          "displayName": "Validate audience endpoint address",
          "type": "Boolean",
          "isHidden": true,
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectContentType": {
          "defaultValue": "application/x-www-form-urlencoded",
          "displayName": "Introspect Content-Type",
          "type": "String",
          "isHidden": true,
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectAuthorizationLogin": {
          "defaultValue": "",
          "displayName": "Introspect Authorization Login",
          "description": "Authorization login used to access the identity provider. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectAuthorizationPasswordVault": {
          "defaultValue": "$ENTAXY_SECRETS{password@for-service}",
          "description": "Authorization password used to access the identity provider. It is possible to use secrets with $ENTAXY_SECRETS{your_alias@your_vault}. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/vaults.html\">Entaxy docs</a> and <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "displayName": "Introspect Authorization Password",
          "type": "String",
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectAccept": {
          "defaultValue": "application/json",
          "displayName": "Introspect Accept",
          "description": "Authorization Accept used to access the identity provider.  For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "isHidden": true,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectAddress": {
          "displayName": "Introspect URL",
          "description": "Authorization URL used to access the identity provider. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "String",
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        },
        "introspectHttpReceiveTimeout": {
          "defaultValue": "60",
          "displayName": "Http receive timeout",
          "description": "Http receive timeout used to access the identity provider. For more details see <a target=\"_blank\" href=\"https://docs.entaxy.ru/entaxy-core/${project.version}/core/security/oauth.html\">Entaxy docs</a>",
          "type": "integer",
          "javaType": "java.lang.Integer",
          "required": false,
          "group": "security",
          "@UI": {
            "displayBlocks": [
              "OAUTH INTROSPECT"
            ],
            "required": true
          }
        }
      },
      "config": {
        "configurable": false,
        "@SKIP_PUBLISH": {}
      }
    }
  }
}
