diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/components/connector_flyout/index.tsx b/x-pack/legacy/plugins/siem/public/lib/connectors/components/connector_flyout/index.tsx index 57c41a74a0ccf26..71461bed6a3b649 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/components/connector_flyout/index.tsx +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/components/connector_flyout/index.tsx @@ -114,7 +114,7 @@ export const withConnectorFlyout = ({ name="apiUrl" value={apiUrl || ''} // Needed to prevent uncontrolled input error when value is undefined data-test-subj="apiUrlFromInput" - placeholder="https://.service-now.com" + placeholder="https://" onChange={handleOnChangeActionConfig.bind(null, 'apiUrl')} onBlur={handleOnBlurActionConfig.bind(null, 'apiUrl')} /> diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/config.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/config.ts index ddc557d57abd95c..339d6551ad0428c 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/config.ts +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/config.ts @@ -8,7 +8,7 @@ import { CasesConfigurationMapping } from '../../containers/case/configure/types import { Connector } from './types'; import { connector as serviceNowConnectorConfig } from './servicenow/config'; -import { connector as resilientConnectorConfig } from './resilient/config'; +import { connector as resilientConnectorConfig } from './jira/config'; export const connectorsConfiguration: Record = { '.servicenow': serviceNowConnectorConfig, diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/index.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/index.ts index d95e73dfeeced91..a3af0b700b97d96 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/index.ts +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/index.ts @@ -5,4 +5,4 @@ */ export { getActionType as serviceNowActionType } from './servicenow'; -export { getActionType as resilientActionType } from './resilient'; +export { getActionType as resilientActionType } from './jira'; diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/config.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/config.ts similarity index 83% rename from x-pack/legacy/plugins/siem/public/lib/connectors/resilient/config.ts rename to x-pack/legacy/plugins/siem/public/lib/connectors/jira/config.ts index 950ad96f4ed7f76..42bd1b9cdc19153 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/config.ts +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/config.ts @@ -6,12 +6,12 @@ import { Connector } from '../types'; -import { RESILIENT_TITLE } from './translations'; +import { JIRA_TITLE } from './translations'; import logo from './logo.svg'; export const connector: Connector = { - id: '.resilient', - name: RESILIENT_TITLE, + id: '.jira', + name: JIRA_TITLE, logo, enabled: true, enabledInConfig: true, diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/jira/flyout.tsx b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/flyout.tsx new file mode 100644 index 000000000000000..6b6908adb683e25 --- /dev/null +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/flyout.tsx @@ -0,0 +1,83 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License; + * you may not use this file except in compliance with the Elastic License. + */ +import React from 'react'; +import { + EuiFieldText, + EuiFlexGroup, + EuiFlexItem, + EuiFormRow, + EuiFieldPassword, + EuiSpacer, +} from '@elastic/eui'; + +import * as i18n from './translations'; +import { ConnectorFlyoutFormProps } from '../types'; +import { JiraActionConnector } from './types'; +import { withConnectorFlyout } from '../components/connector_flyout'; + +const JiraConnectorForm: React.FC> = ({ + errors, + action, + onChangeSecret, + onBlurSecret, +}) => { + const { email, apiToken } = action.secrets; + const isEmailInvalid: boolean = errors.email.length > 0 && email != null; + const isApiTokenInvalid: boolean = errors.apiToken.length > 0 && apiToken != null; + + return ( + <> + + + + onChangeSecret('email', evt.target.value)} + onBlur={() => onBlurSecret('email')} + /> + + + + + + + + onChangeSecret('apiToken', evt.target.value)} + onBlur={() => onBlurSecret('apiToken')} + /> + + + + + ); +}; + +export const JiraConnectorFlyout = withConnectorFlyout({ + ConnectorFormComponent: JiraConnectorForm, + secretKeys: ['email', 'apiToken'], +}); diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/jira/index.tsx b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/index.tsx new file mode 100644 index 000000000000000..c6797858d2f619e --- /dev/null +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/index.tsx @@ -0,0 +1,48 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License; + * you may not use this file except in compliance with the Elastic License. + */ + +import { + ValidationResult, + // eslint-disable-next-line @kbn/eslint/no-restricted-paths +} from '../../../../../../../plugins/triggers_actions_ui/public/types'; + +import { connector } from './config'; +import { createActionType } from '../utils'; +import logo from './logo.svg'; +import { JiraActionConnector } from './types'; +import { JiraConnectorFlyout } from './flyout'; +import * as i18n from './translations'; + +interface Errors { + email: string[]; + apiToken: string[]; +} + +const validateConnector = (action: JiraActionConnector): ValidationResult => { + const errors: Errors = { + email: [], + apiToken: [], + }; + + if (!action.secrets.email) { + errors.email = [...errors.email, i18n.EMAIL_REQUIRED]; + } + + if (!action.secrets.apiToken) { + errors.apiToken = [...errors.apiToken, i18n.API_TOKEN_REQUIRED]; + } + + return { errors }; +}; + +export const getActionType = createActionType({ + id: connector.id, + iconClass: logo, + selectMessage: i18n.JIRA_DESC, + actionTypeTitle: connector.name, + validateConnector, + actionConnectorFields: JiraConnectorFlyout, +}); diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/logo.svg b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/logo.svg similarity index 100% rename from x-pack/legacy/plugins/siem/public/lib/connectors/resilient/logo.svg rename to x-pack/legacy/plugins/siem/public/lib/connectors/jira/logo.svg diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/jira/translations.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/translations.ts new file mode 100644 index 000000000000000..2d2df6739f5fe43 --- /dev/null +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/translations.ts @@ -0,0 +1,17 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License; + * you may not use this file except in compliance with the Elastic License. + */ + +import { i18n } from '@kbn/i18n'; + +export * from '../translations'; + +export const JIRA_DESC = i18n.translate('xpack.siem.case.connectors.jira.selectMessageText', { + defaultMessage: 'Push or update SIEM case data to a new issue in Jira', +}); + +export const JIRA_TITLE = i18n.translate('xpack.siem.case.connectors.jira.actionTypeTitle', { + defaultMessage: 'Jira', +}); diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/types.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/types.ts similarity index 63% rename from x-pack/legacy/plugins/siem/public/lib/connectors/resilient/types.ts rename to x-pack/legacy/plugins/siem/public/lib/connectors/jira/types.ts index 8c299b1ef379e2f..d0732954bccd6b8 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/types.ts +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/jira/types.ts @@ -8,11 +8,11 @@ /* eslint-disable @kbn/eslint/no-restricted-paths */ import { - ResilientPublicConfigurationType, - ResilientSecretConfigurationType, -} from '../../../../../../../plugins/actions/server/builtin_action_types/connectors/resilient/types'; + JiraPublicConfigurationType, + JiraSecretConfigurationType, +} from '../../../../../../../plugins/actions/server/builtin_action_types/connectors/jira/types'; -export interface ResilientActionConnector { - config: ResilientPublicConfigurationType; - secrets: ResilientSecretConfigurationType; +export interface JiraActionConnector { + config: JiraPublicConfigurationType; + secrets: JiraSecretConfigurationType; } diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/index.tsx b/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/index.tsx deleted file mode 100644 index 61d4e20e68e6e5c..000000000000000 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/index.tsx +++ /dev/null @@ -1,278 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License; - * you may not use this file except in compliance with the Elastic License. - */ -import React, { useCallback, ChangeEvent, useEffect } from 'react'; -import { - EuiFieldText, - EuiFlexGroup, - EuiFlexItem, - EuiFormRow, - EuiSpacer, - EuiFieldPassword, -} from '@elastic/eui'; - -import { isEmpty, get } from 'lodash/fp'; - -import { - ActionConnectorFieldsProps, - ActionTypeModel, - ValidationResult, - ActionParamsProps, - // eslint-disable-next-line @kbn/eslint/no-restricted-paths -} from '../../../../../../../plugins/triggers_actions_ui/public/types'; - -import { FieldMapping } from '../../../pages/case/components/configure_cases/field_mapping'; - -import * as i18n from './translations'; - -import { ResilientActionConnector } from './types'; -import { isUrlInvalid } from '../validators'; - -import { defaultMapping } from '../config'; -import { CasesConfigurationMapping } from '../../../containers/case/configure/types'; - -import { connector } from './config'; - -interface ResilientActionParams { - message: string; -} - -interface Errors { - apiUrl: string[]; - orgId: string[]; - apiKey: string[]; - apiSecret: string[]; -} - -export function getActionType(): ActionTypeModel { - return { - id: connector.id, - iconClass: connector.logo, - selectMessage: i18n.RESILIENT_DESC, - actionTypeTitle: connector.name, - validateConnector: (action: ResilientActionConnector): ValidationResult => { - const errors: Errors = { - apiUrl: [], - orgId: [], - apiKey: [], - apiSecret: [], - }; - - if (!action.config.apiUrl) { - errors.apiUrl = [...errors.apiUrl, i18n.API_URL_REQUIRED]; - } - - if (isUrlInvalid(action.config.apiUrl)) { - errors.apiUrl = [...errors.apiUrl, i18n.API_URL_INVALID]; - } - - if (!action.config.orgId) { - errors.orgId = [...errors.orgId, i18n.RESILIENT_ORG_ID_REQUIRED]; - } - - if (!action.secrets.apiKey) { - errors.apiKey = [...errors.apiKey, i18n.API_KEY_REQUIRED]; - } - - if (!action.secrets.apiSecret) { - errors.apiSecret = [...errors.apiSecret, i18n.API_SECRET_REQUIRED]; - } - - return { errors }; - }, - validateParams: (actionParams: ResilientActionParams): ValidationResult => { - return { errors: {} }; - }, - actionConnectorFields: ResilientConnectorFields, - actionParamsFields: ResilientParamsFields, - }; -} - -const ResilientConnectorFields: React.FunctionComponent> = ({ action, editActionConfig, editActionSecrets, errors }) => { - /* We do not provide defaults values to the fields (like empty string for apiUrl) intentionally. - * If we do, errors will be shown the first time the flyout is open even though the user did not - * interact with the form. Also, we would like to show errors for empty fields provided by the user. - /*/ - const { apiUrl, orgId, casesConfiguration: { mapping = [] } = {} } = action.config; - const { apiKey, apiSecret } = action.secrets; - - const isApiUrlInvalid: boolean = errors.apiUrl.length > 0 && apiUrl != null; - const isOrgIdInvalid: boolean = errors.orgId.length > 0 && orgId != null; - const isApiKeyInvalid: boolean = errors.apiKey.length > 0 && apiKey != null; - const isApiSecretInvalid: boolean = errors.apiSecret.length > 0 && apiSecret != null; - - /** - * We need to distinguish between the add flyout and the edit flyout. - * useEffect will run only once on component mount. - * This guarantees that the function below will run only once. - * On the first render of the component the apiUrl can be either undefined or filled. - * If it is filled then we are on the edit flyout. Otherwise we are on the add flyout. - */ - - useEffect(() => { - if (!isEmpty(apiUrl)) { - editActionSecrets('apiKey', ''); - editActionSecrets('apiSecret', ''); - } - }, []); - - if (isEmpty(mapping)) { - editActionConfig('casesConfiguration', { - ...action.config.casesConfiguration, - mapping: defaultMapping, - }); - } - - const handleOnChangeActionConfig = useCallback( - (key: string, evt: ChangeEvent) => editActionConfig(key, evt.target.value), - [] - ); - - const handleOnBlurActionConfig = useCallback( - (key: string) => { - if (['apiUrl', 'orgId'].includes(key) && get(key, action.config) == null) { - editActionConfig(key, ''); - } - }, - [action.config] - ); - - const handleOnChangeSecretConfig = useCallback( - (key: string, evt: ChangeEvent) => editActionSecrets(key, evt.target.value), - [] - ); - - const handleOnBlurSecretConfig = useCallback( - (key: string) => { - if (['apiKey', 'apiSecret'].includes(key) && get(key, action.secrets) == null) { - editActionSecrets(key, ''); - } - }, - [action.secrets] - ); - - const handleOnChangeMappingConfig = useCallback( - (newMapping: CasesConfigurationMapping[]) => - editActionConfig('casesConfiguration', { - ...action.config.casesConfiguration, - mapping: newMapping, - }), - [action.config] - ); - - return ( - <> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ); -}; - -const ResilientParamsFields: React.FunctionComponent> = ({ - actionParams, - editAction, - index, - errors, -}) => { - return null; -}; diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/translations.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/translations.ts deleted file mode 100644 index e4dd8cd5400dfcb..000000000000000 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/resilient/translations.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License; - * you may not use this file except in compliance with the Elastic License. - */ - -import { i18n } from '@kbn/i18n'; - -export * from '../translations'; - -export const RESILIENT_DESC = i18n.translate( - 'xpack.siem.case.connectors.resilient.selectMessageText', - { - defaultMessage: 'Push or update IBM Resilient case data to a new incident in ServiceNow', - } -); - -export const RESILIENT_TITLE = i18n.translate( - 'xpack.siem.case.connectors.resilient.actionTypeTitle', - { - defaultMessage: 'IBM Resilient', - } -); - -export const RESILIENT_ORG_ID = i18n.translate('xpack.siem.case.connectors.resilient.orgId', { - defaultMessage: 'Organization ID', -}); - -export const RESILIENT_ORG_ID_REQUIRED = i18n.translate( - 'xpack.siem.case.connectors.common.requiredOrgIdTextField', - { - defaultMessage: 'Organization ID is required', - } -); diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/servicenow/index.tsx b/x-pack/legacy/plugins/siem/public/lib/connectors/servicenow/index.tsx index a8aab7e74bc6496..e1e2ea05f51fd65 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/servicenow/index.tsx +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/servicenow/index.tsx @@ -4,8 +4,6 @@ * you may not use this file except in compliance with the Elastic License. */ -import React from 'react'; - import { ValidationResult, // eslint-disable-next-line @kbn/eslint/no-restricted-paths diff --git a/x-pack/legacy/plugins/siem/public/lib/connectors/translations.ts b/x-pack/legacy/plugins/siem/public/lib/connectors/translations.ts index abd4c04c7e8bc39..b9c1d0fa2a17fa8 100644 --- a/x-pack/legacy/plugins/siem/public/lib/connectors/translations.ts +++ b/x-pack/legacy/plugins/siem/public/lib/connectors/translations.ts @@ -55,30 +55,27 @@ export const PASSWORD_REQUIRED = i18n.translate( } ); -export const API_KEY_LABEL = i18n.translate( - 'xpack.siem.case.connectors.common.apiKeyTextFieldLabel', +export const API_TOKEN_LABEL = i18n.translate( + 'xpack.siem.case.connectors.common.apiTokenTextFieldLabel', { - defaultMessage: 'Api key', + defaultMessage: 'Api token', } ); -export const API_KEY_REQUIRED = i18n.translate( - 'xpack.siem.case.connectors.common.requiredApiKeyTextField', +export const API_TOKEN_REQUIRED = i18n.translate( + 'xpack.siem.case.connectors.common.requiredApiTokenTextField', { - defaultMessage: 'Api key is required', + defaultMessage: 'Api token is required', } ); -export const API_SECRET_LABEL = i18n.translate( - 'xpack.siem.case.connectors.common.apiSecretTextFieldLabel', - { - defaultMessage: 'Api secret', - } -); +export const EMAIL_LABEL = i18n.translate('xpack.siem.case.connectors.common.emailTextFieldLabel', { + defaultMessage: 'Email', +}); -export const API_SECRET_REQUIRED = i18n.translate( - 'xpack.siem.case.connectors.common.requiredApiSecretTextField', +export const EMAIL_REQUIRED = i18n.translate( + 'xpack.siem.case.connectors.common.requiredEmailTextField', { - defaultMessage: 'Api secret is required', + defaultMessage: 'Email is required', } ); diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/config.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/config.ts similarity index 100% rename from x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/config.ts rename to x-pack/plugins/actions/server/builtin_action_types/connectors/jira/config.ts diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/schema.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/schema.ts similarity index 51% rename from x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/schema.ts rename to x-pack/plugins/actions/server/builtin_action_types/connectors/jira/schema.ts index 936a17a6a1fedd0..3ef780b0d7290ad 100644 --- a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/schema.ts +++ b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/schema.ts @@ -7,16 +7,15 @@ import { schema } from '@kbn/config-schema'; import { ConnectorPublicConfiguration } from '../schema'; -export const ResilientPublicConfiguration = { - orgId: schema.number(), +export const JiraPublicConfiguration = { ...ConnectorPublicConfiguration, }; -export const ResilientPublicConfigurationSchema = schema.object(ResilientPublicConfiguration); +export const JiraPublicConfigurationSchema = schema.object(JiraPublicConfiguration); -export const ResilientSecretConfiguration = { - apiKey: schema.string(), - apiSecret: schema.string(), +export const JiraSecretConfiguration = { + email: schema.string(), + apiToken: schema.string(), }; -export const ResilientSecretConfigurationSchema = schema.object(ResilientSecretConfiguration); +export const JiraSecretConfigurationSchema = schema.object(JiraSecretConfiguration); diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/service.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/service.ts similarity index 55% rename from x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/service.ts rename to x-pack/plugins/actions/server/builtin_action_types/connectors/jira/service.ts index 29473942ed69147..779966865530e3e 100644 --- a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/service.ts +++ b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/service.ts @@ -7,14 +7,14 @@ import axios from 'axios'; import { ExternalServiceCredential, ExternalService, ExternalServiceParams } from '../types'; -import { addTimeZoneToDate, patch, request, getErrorMessage } from '../utils'; -import { ResilientPublicConfigurationType, ResilientSecretConfigurationType } from './types'; +import { JiraPublicConfigurationType, JiraSecretConfigurationType } from './types'; import * as i18n from './translations'; -const BASE_URL = 'rest/orgs/'; -const INCIDENT_URL = `incidents`; -const COMMENT_URL = `tasks`; +const VERSION = '2'; +const BASE_URL = `rest/api/${VERSION}`; +const INCIDENT_URL = `issue`; +const COMMENT_URL = `comment`; const VIEW_INCIDENT_URL = `#incidents`; @@ -22,37 +22,24 @@ export const createExternalService = ({ config, secrets, }: ExternalServiceCredential): ExternalService => { - const { apiUrl: url, orgId } = config as ResilientPublicConfigurationType; - const { apiKey, apiSecret } = secrets as ResilientSecretConfigurationType; - let apiKeyHandle; + const { apiUrl: url } = config as JiraPublicConfigurationType; + const { apiKey, email } = secrets as JiraSecretConfigurationType; - if (!url || !apiKey || !apiSecret) { + if (!url || !apiKey || !email) { throw Error(`[Action]${i18n.NAME}: Wrong configuration.`); } - const incidentUrl = `${url}/${BASE_URL}/${orgId}/${INCIDENT_URL}`; - const commentUrl = `${url}/${BASE_URL}/${orgId}/${COMMENT_URL}`; + const incidentUrl = `${url}/${BASE_URL}/${INCIDENT_URL}`; + const commentUrl = `${url}/${BASE_URL}/{issueId}/${COMMENT_URL}`; const sessionUrl = `${url}/rest/session`; const axiosInstance = axios.create({ - auth: { username: apiKey, password: apiSecret }, + auth: { username: email, password: apiKey }, }); const getIncidentViewURL = (id: string) => { return `${url}/${VIEW_INCIDENT_URL}/${id}`; }; - const getApiKeyHandle = async (): Promise => { - try { - const res = await request({ - axios: axiosInstance, - url: sessionUrl, - }); - - return res.data.api_key_handle; - } catch (error) { - throw new Error(getErrorMessage(i18n.NAME, `Unable to authenticate user`)); - } - }; const getIncident = async (id: string) => {}; const createIncident = async ({ incident }: ExternalServiceParams) => {}; diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/translations.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/translations.ts similarity index 100% rename from x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/translations.ts rename to x-pack/plugins/actions/server/builtin_action_types/connectors/jira/translations.ts diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/types.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/types.ts new file mode 100644 index 000000000000000..0051ef6c70b2c65 --- /dev/null +++ b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/types.ts @@ -0,0 +1,11 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License; + * you may not use this file except in compliance with the Elastic License. + */ + +import { TypeOf } from '@kbn/config-schema'; +import { JiraPublicConfigurationSchema, JiraSecretConfigurationSchema } from './schema'; + +export type JiraPublicConfigurationType = TypeOf; +export type JiraSecretConfigurationType = TypeOf; diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/validators.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/jira/validators.ts similarity index 100% rename from x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/validators.ts rename to x-pack/plugins/actions/server/builtin_action_types/connectors/jira/validators.ts diff --git a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/types.ts b/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/types.ts deleted file mode 100644 index 29c02c183dbf836..000000000000000 --- a/x-pack/plugins/actions/server/builtin_action_types/connectors/resilient/types.ts +++ /dev/null @@ -1,11 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License; - * you may not use this file except in compliance with the Elastic License. - */ - -import { TypeOf } from '@kbn/config-schema'; -import { ResilientPublicConfigurationSchema, ResilientSecretConfigurationSchema } from './schema'; - -export type ResilientPublicConfigurationType = TypeOf; -export type ResilientSecretConfigurationType = TypeOf;