{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.Kendra.Types.GitHubConfiguration
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Kendra.Types.GitHubConfiguration where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Kendra.Types.DataSourceToIndexFieldMapping
import Amazonka.Kendra.Types.DataSourceVpcConfiguration
import Amazonka.Kendra.Types.GitHubDocumentCrawlProperties
import Amazonka.Kendra.Types.OnPremiseConfiguration
import Amazonka.Kendra.Types.SaaSConfiguration
import Amazonka.Kendra.Types.Type
import qualified Amazonka.Prelude as Prelude

-- | Provides the configuration information to connect to GitHub as your data
-- source.
--
-- /See:/ 'newGitHubConfiguration' smart constructor.
data GitHubConfiguration = GitHubConfiguration'
  { -- | A list of regular expression patterns to exclude certain file names in
    -- your GitHub repository or repositories. File names that match the
    -- patterns are excluded from the index. File names that don\'t match the
    -- patterns are included in the index. If a file matches both an exclusion
    -- and inclusion pattern, the exclusion pattern takes precedence and the
    -- file isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
exclusionFileNamePatterns :: Prelude.Maybe [Prelude.Text],
    -- | A list of regular expression patterns to exclude certain file types in
    -- your GitHub repository or repositories. File types that match the
    -- patterns are excluded from the index. File types that don\'t match the
    -- patterns are included in the index. If a file matches both an exclusion
    -- and inclusion pattern, the exclusion pattern takes precedence and the
    -- file isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
exclusionFileTypePatterns :: Prelude.Maybe [Prelude.Text],
    -- | A list of regular expression patterns to exclude certain folder names in
    -- your GitHub repository or repositories. Folder names that match the
    -- patterns are excluded from the index. Folder names that don\'t match the
    -- patterns are included in the index. If a folder matches both an
    -- exclusion and inclusion pattern, the exclusion pattern takes precedence
    -- and the folder isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
exclusionFolderNamePatterns :: Prelude.Maybe [Prelude.Text],
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub commits to Amazon Kendra index field names. To
    -- create custom fields, use the @UpdateIndex@ API before you map to GitHub
    -- fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | Configuration information to include certain types of GitHub content.
    -- You can configure to index repository files only, or also include issues
    -- and pull requests, comments, and comment attachments.
    GitHubConfiguration -> Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties :: Prelude.Maybe GitHubDocumentCrawlProperties,
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub issue attachments to Amazon Kendra index field
    -- names. To create custom fields, use the @UpdateIndex@ API before you map
    -- to GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub issue comments to Amazon Kendra index field names.
    -- To create custom fields, use the @UpdateIndex@ API before you map to
    -- GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub issues to Amazon Kendra index field names. To
    -- create custom fields, use the @UpdateIndex@ API before you map to GitHub
    -- fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub pull request comments to Amazon Kendra index field
    -- names. To create custom fields, use the @UpdateIndex@ API before you map
    -- to GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub pull request attachments to Amazon Kendra index
    -- field names. To create custom fields, use the @UpdateIndex@ API before
    -- you map to GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
    -- field names of GitHub pull requests to Amazon Kendra index field names.
    -- To create custom fields, use the @UpdateIndex@ API before you map to
    -- GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of @DataSourceToIndexFieldMapping@ objects that map GitHub
    -- repository attributes or field names to Amazon Kendra index field names.
    -- To create custom fields, use the @UpdateIndex@ API before you map to
    -- GitHub fields. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
    -- The GitHub data source field names must exist in your GitHub custom
    -- metadata.
    GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings :: Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping),
    -- | A list of regular expression patterns to include certain file names in
    -- your GitHub repository or repositories. File names that match the
    -- patterns are included in the index. File names that don\'t match the
    -- patterns are excluded from the index. If a file matches both an
    -- inclusion and exclusion pattern, the exclusion pattern takes precedence
    -- and the file isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
inclusionFileNamePatterns :: Prelude.Maybe [Prelude.Text],
    -- | A list of regular expression patterns to include certain file types in
    -- your GitHub repository or repositories. File types that match the
    -- patterns are included in the index. File types that don\'t match the
    -- patterns are excluded from the index. If a file matches both an
    -- inclusion and exclusion pattern, the exclusion pattern takes precedence
    -- and the file isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
inclusionFileTypePatterns :: Prelude.Maybe [Prelude.Text],
    -- | A list of regular expression patterns to include certain folder names in
    -- your GitHub repository or repositories. Folder names that match the
    -- patterns are included in the index. Folder names that don\'t match the
    -- patterns are excluded from the index. If a folder matches both an
    -- inclusion and exclusion pattern, the exclusion pattern takes precedence
    -- and the folder isn\'t included in the index.
    GitHubConfiguration -> Maybe [Text]
inclusionFolderNamePatterns :: Prelude.Maybe [Prelude.Text],
    -- | Configuration information to connect to GitHub Enterprise Server (on
    -- premises).
    GitHubConfiguration -> Maybe OnPremiseConfiguration
onPremiseConfiguration :: Prelude.Maybe OnPremiseConfiguration,
    -- | A list of names of the specific repositories you want to index.
    GitHubConfiguration -> Maybe [Text]
repositoryFilter :: Prelude.Maybe [Prelude.Text],
    -- | Configuration information to connect to GitHub Enterprise Cloud (SaaS).
    GitHubConfiguration -> Maybe SaaSConfiguration
saaSConfiguration :: Prelude.Maybe SaaSConfiguration,
    -- | The type of GitHub service you want to connect to—GitHub Enterprise
    -- Cloud (SaaS) or GitHub Enterprise Server (on premises).
    GitHubConfiguration -> Maybe Type
type' :: Prelude.Maybe Type,
    -- | @TRUE@ to use the GitHub change log to determine which documents require
    -- updating in the index. Depending on the GitHub change log\'s size, it
    -- may take longer for Amazon Kendra to use the change log than to scan all
    -- of your documents in GitHub.
    GitHubConfiguration -> Maybe Bool
useChangeLog :: Prelude.Maybe Prelude.Bool,
    -- | Configuration information of an Amazon Virtual Private Cloud to connect
    -- to your GitHub. For more information, see
    -- <https://docs.aws.amazon.com/kendra/latest/dg/vpc-configuration.html Configuring a VPC>.
    GitHubConfiguration -> Maybe DataSourceVpcConfiguration
vpcConfiguration :: Prelude.Maybe DataSourceVpcConfiguration,
    -- | The Amazon Resource Name (ARN) of an Secrets Manager secret that
    -- contains the key-value pairs required to connect to your GitHub. The
    -- secret must contain a JSON structure with the following keys:
    --
    -- -   personalToken—The access token created in GitHub. For more
    --     information on creating a token in GitHub, see
    --     <https://docs.aws.amazon.com/kendra/latest/dg/data-source-github.html Using a GitHub data source>.
    GitHubConfiguration -> Text
secretArn :: Prelude.Text
  }
  deriving (GitHubConfiguration -> GitHubConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GitHubConfiguration -> GitHubConfiguration -> Bool
$c/= :: GitHubConfiguration -> GitHubConfiguration -> Bool
== :: GitHubConfiguration -> GitHubConfiguration -> Bool
$c== :: GitHubConfiguration -> GitHubConfiguration -> Bool
Prelude.Eq, ReadPrec [GitHubConfiguration]
ReadPrec GitHubConfiguration
Int -> ReadS GitHubConfiguration
ReadS [GitHubConfiguration]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GitHubConfiguration]
$creadListPrec :: ReadPrec [GitHubConfiguration]
readPrec :: ReadPrec GitHubConfiguration
$creadPrec :: ReadPrec GitHubConfiguration
readList :: ReadS [GitHubConfiguration]
$creadList :: ReadS [GitHubConfiguration]
readsPrec :: Int -> ReadS GitHubConfiguration
$creadsPrec :: Int -> ReadS GitHubConfiguration
Prelude.Read, Int -> GitHubConfiguration -> ShowS
[GitHubConfiguration] -> ShowS
GitHubConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GitHubConfiguration] -> ShowS
$cshowList :: [GitHubConfiguration] -> ShowS
show :: GitHubConfiguration -> String
$cshow :: GitHubConfiguration -> String
showsPrec :: Int -> GitHubConfiguration -> ShowS
$cshowsPrec :: Int -> GitHubConfiguration -> ShowS
Prelude.Show, forall x. Rep GitHubConfiguration x -> GitHubConfiguration
forall x. GitHubConfiguration -> Rep GitHubConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GitHubConfiguration x -> GitHubConfiguration
$cfrom :: forall x. GitHubConfiguration -> Rep GitHubConfiguration x
Prelude.Generic)

-- |
-- Create a value of 'GitHubConfiguration' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'exclusionFileNamePatterns', 'gitHubConfiguration_exclusionFileNamePatterns' - A list of regular expression patterns to exclude certain file names in
-- your GitHub repository or repositories. File names that match the
-- patterns are excluded from the index. File names that don\'t match the
-- patterns are included in the index. If a file matches both an exclusion
-- and inclusion pattern, the exclusion pattern takes precedence and the
-- file isn\'t included in the index.
--
-- 'exclusionFileTypePatterns', 'gitHubConfiguration_exclusionFileTypePatterns' - A list of regular expression patterns to exclude certain file types in
-- your GitHub repository or repositories. File types that match the
-- patterns are excluded from the index. File types that don\'t match the
-- patterns are included in the index. If a file matches both an exclusion
-- and inclusion pattern, the exclusion pattern takes precedence and the
-- file isn\'t included in the index.
--
-- 'exclusionFolderNamePatterns', 'gitHubConfiguration_exclusionFolderNamePatterns' - A list of regular expression patterns to exclude certain folder names in
-- your GitHub repository or repositories. Folder names that match the
-- patterns are excluded from the index. Folder names that don\'t match the
-- patterns are included in the index. If a folder matches both an
-- exclusion and inclusion pattern, the exclusion pattern takes precedence
-- and the folder isn\'t included in the index.
--
-- 'gitHubCommitConfigurationFieldMappings', 'gitHubConfiguration_gitHubCommitConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub commits to Amazon Kendra index field names. To
-- create custom fields, use the @UpdateIndex@ API before you map to GitHub
-- fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubDocumentCrawlProperties', 'gitHubConfiguration_gitHubDocumentCrawlProperties' - Configuration information to include certain types of GitHub content.
-- You can configure to index repository files only, or also include issues
-- and pull requests, comments, and comment attachments.
--
-- 'gitHubIssueAttachmentConfigurationFieldMappings', 'gitHubConfiguration_gitHubIssueAttachmentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issue attachments to Amazon Kendra index field
-- names. To create custom fields, use the @UpdateIndex@ API before you map
-- to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubIssueCommentConfigurationFieldMappings', 'gitHubConfiguration_gitHubIssueCommentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issue comments to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubIssueDocumentConfigurationFieldMappings', 'gitHubConfiguration_gitHubIssueDocumentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issues to Amazon Kendra index field names. To
-- create custom fields, use the @UpdateIndex@ API before you map to GitHub
-- fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubPullRequestCommentConfigurationFieldMappings', 'gitHubConfiguration_gitHubPullRequestCommentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull request comments to Amazon Kendra index field
-- names. To create custom fields, use the @UpdateIndex@ API before you map
-- to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubPullRequestDocumentAttachmentConfigurationFieldMappings', 'gitHubConfiguration_gitHubPullRequestDocumentAttachmentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull request attachments to Amazon Kendra index
-- field names. To create custom fields, use the @UpdateIndex@ API before
-- you map to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubPullRequestDocumentConfigurationFieldMappings', 'gitHubConfiguration_gitHubPullRequestDocumentConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull requests to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'gitHubRepositoryConfigurationFieldMappings', 'gitHubConfiguration_gitHubRepositoryConfigurationFieldMappings' - A list of @DataSourceToIndexFieldMapping@ objects that map GitHub
-- repository attributes or field names to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
--
-- 'inclusionFileNamePatterns', 'gitHubConfiguration_inclusionFileNamePatterns' - A list of regular expression patterns to include certain file names in
-- your GitHub repository or repositories. File names that match the
-- patterns are included in the index. File names that don\'t match the
-- patterns are excluded from the index. If a file matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the file isn\'t included in the index.
--
-- 'inclusionFileTypePatterns', 'gitHubConfiguration_inclusionFileTypePatterns' - A list of regular expression patterns to include certain file types in
-- your GitHub repository or repositories. File types that match the
-- patterns are included in the index. File types that don\'t match the
-- patterns are excluded from the index. If a file matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the file isn\'t included in the index.
--
-- 'inclusionFolderNamePatterns', 'gitHubConfiguration_inclusionFolderNamePatterns' - A list of regular expression patterns to include certain folder names in
-- your GitHub repository or repositories. Folder names that match the
-- patterns are included in the index. Folder names that don\'t match the
-- patterns are excluded from the index. If a folder matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the folder isn\'t included in the index.
--
-- 'onPremiseConfiguration', 'gitHubConfiguration_onPremiseConfiguration' - Configuration information to connect to GitHub Enterprise Server (on
-- premises).
--
-- 'repositoryFilter', 'gitHubConfiguration_repositoryFilter' - A list of names of the specific repositories you want to index.
--
-- 'saaSConfiguration', 'gitHubConfiguration_saaSConfiguration' - Configuration information to connect to GitHub Enterprise Cloud (SaaS).
--
-- 'type'', 'gitHubConfiguration_type' - The type of GitHub service you want to connect to—GitHub Enterprise
-- Cloud (SaaS) or GitHub Enterprise Server (on premises).
--
-- 'useChangeLog', 'gitHubConfiguration_useChangeLog' - @TRUE@ to use the GitHub change log to determine which documents require
-- updating in the index. Depending on the GitHub change log\'s size, it
-- may take longer for Amazon Kendra to use the change log than to scan all
-- of your documents in GitHub.
--
-- 'vpcConfiguration', 'gitHubConfiguration_vpcConfiguration' - Configuration information of an Amazon Virtual Private Cloud to connect
-- to your GitHub. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/vpc-configuration.html Configuring a VPC>.
--
-- 'secretArn', 'gitHubConfiguration_secretArn' - The Amazon Resource Name (ARN) of an Secrets Manager secret that
-- contains the key-value pairs required to connect to your GitHub. The
-- secret must contain a JSON structure with the following keys:
--
-- -   personalToken—The access token created in GitHub. For more
--     information on creating a token in GitHub, see
--     <https://docs.aws.amazon.com/kendra/latest/dg/data-source-github.html Using a GitHub data source>.
newGitHubConfiguration ::
  -- | 'secretArn'
  Prelude.Text ->
  GitHubConfiguration
newGitHubConfiguration :: Text -> GitHubConfiguration
newGitHubConfiguration Text
pSecretArn_ =
  GitHubConfiguration'
    { $sel:exclusionFileNamePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFileNamePatterns =
        forall a. Maybe a
Prelude.Nothing,
      $sel:exclusionFileTypePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFileTypePatterns = forall a. Maybe a
Prelude.Nothing,
      $sel:exclusionFolderNamePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFolderNamePatterns = forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties = forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings =
        forall a. Maybe a
Prelude.Nothing,
      $sel:inclusionFileNamePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFileNamePatterns = forall a. Maybe a
Prelude.Nothing,
      $sel:inclusionFileTypePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFileTypePatterns = forall a. Maybe a
Prelude.Nothing,
      $sel:inclusionFolderNamePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFolderNamePatterns = forall a. Maybe a
Prelude.Nothing,
      $sel:onPremiseConfiguration:GitHubConfiguration' :: Maybe OnPremiseConfiguration
onPremiseConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:repositoryFilter:GitHubConfiguration' :: Maybe [Text]
repositoryFilter = forall a. Maybe a
Prelude.Nothing,
      $sel:saaSConfiguration:GitHubConfiguration' :: Maybe SaaSConfiguration
saaSConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:type':GitHubConfiguration' :: Maybe Type
type' = forall a. Maybe a
Prelude.Nothing,
      $sel:useChangeLog:GitHubConfiguration' :: Maybe Bool
useChangeLog = forall a. Maybe a
Prelude.Nothing,
      $sel:vpcConfiguration:GitHubConfiguration' :: Maybe DataSourceVpcConfiguration
vpcConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:secretArn:GitHubConfiguration' :: Text
secretArn = Text
pSecretArn_
    }

-- | A list of regular expression patterns to exclude certain file names in
-- your GitHub repository or repositories. File names that match the
-- patterns are excluded from the index. File names that don\'t match the
-- patterns are included in the index. If a file matches both an exclusion
-- and inclusion pattern, the exclusion pattern takes precedence and the
-- file isn\'t included in the index.
gitHubConfiguration_exclusionFileNamePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_exclusionFileNamePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_exclusionFileNamePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
exclusionFileNamePatterns :: Maybe [Text]
$sel:exclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
exclusionFileNamePatterns} -> Maybe [Text]
exclusionFileNamePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:exclusionFileNamePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFileNamePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of regular expression patterns to exclude certain file types in
-- your GitHub repository or repositories. File types that match the
-- patterns are excluded from the index. File types that don\'t match the
-- patterns are included in the index. If a file matches both an exclusion
-- and inclusion pattern, the exclusion pattern takes precedence and the
-- file isn\'t included in the index.
gitHubConfiguration_exclusionFileTypePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_exclusionFileTypePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_exclusionFileTypePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
exclusionFileTypePatterns :: Maybe [Text]
$sel:exclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
exclusionFileTypePatterns} -> Maybe [Text]
exclusionFileTypePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:exclusionFileTypePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFileTypePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of regular expression patterns to exclude certain folder names in
-- your GitHub repository or repositories. Folder names that match the
-- patterns are excluded from the index. Folder names that don\'t match the
-- patterns are included in the index. If a folder matches both an
-- exclusion and inclusion pattern, the exclusion pattern takes precedence
-- and the folder isn\'t included in the index.
gitHubConfiguration_exclusionFolderNamePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_exclusionFolderNamePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_exclusionFolderNamePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
exclusionFolderNamePatterns :: Maybe [Text]
$sel:exclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
exclusionFolderNamePatterns} -> Maybe [Text]
exclusionFolderNamePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:exclusionFolderNamePatterns:GitHubConfiguration' :: Maybe [Text]
exclusionFolderNamePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub commits to Amazon Kendra index field names. To
-- create custom fields, use the @UpdateIndex@ API before you map to GitHub
-- fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubCommitConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubCommitConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubCommitConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Configuration information to include certain types of GitHub content.
-- You can configure to index repository files only, or also include issues
-- and pull requests, comments, and comment attachments.
gitHubConfiguration_gitHubDocumentCrawlProperties :: Lens.Lens' GitHubConfiguration (Prelude.Maybe GitHubDocumentCrawlProperties)
gitHubConfiguration_gitHubDocumentCrawlProperties :: Lens' GitHubConfiguration (Maybe GitHubDocumentCrawlProperties)
gitHubConfiguration_gitHubDocumentCrawlProperties = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties :: Maybe GitHubDocumentCrawlProperties
$sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: GitHubConfiguration -> Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties} -> Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe GitHubDocumentCrawlProperties
a -> GitHubConfiguration
s {$sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties = Maybe GitHubDocumentCrawlProperties
a} :: GitHubConfiguration)

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issue attachments to Amazon Kendra index field
-- names. To create custom fields, use the @UpdateIndex@ API before you map
-- to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubIssueAttachmentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueAttachmentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueAttachmentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issue comments to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubIssueCommentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueCommentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueCommentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub issues to Amazon Kendra index field names. To
-- create custom fields, use the @UpdateIndex@ API before you map to GitHub
-- fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubIssueDocumentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueDocumentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubIssueDocumentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull request comments to Amazon Kendra index field
-- names. To create custom fields, use the @UpdateIndex@ API before you map
-- to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubPullRequestCommentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestCommentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestCommentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull request attachments to Amazon Kendra index
-- field names. To create custom fields, use the @UpdateIndex@ API before
-- you map to GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestDocumentAttachmentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map attributes or
-- field names of GitHub pull requests to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubPullRequestDocumentConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestDocumentConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubPullRequestDocumentConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of @DataSourceToIndexFieldMapping@ objects that map GitHub
-- repository attributes or field names to Amazon Kendra index field names.
-- To create custom fields, use the @UpdateIndex@ API before you map to
-- GitHub fields. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/field-mapping.html Mapping data source fields>.
-- The GitHub data source field names must exist in your GitHub custom
-- metadata.
gitHubConfiguration_gitHubRepositoryConfigurationFieldMappings :: Lens.Lens' GitHubConfiguration (Prelude.Maybe (Prelude.NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubRepositoryConfigurationFieldMappings :: Lens'
  GitHubConfiguration
  (Maybe (NonEmpty DataSourceToIndexFieldMapping))
gitHubConfiguration_gitHubRepositoryConfigurationFieldMappings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings} -> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe (NonEmpty DataSourceToIndexFieldMapping)
a -> GitHubConfiguration
s {$sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings = Maybe (NonEmpty DataSourceToIndexFieldMapping)
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of regular expression patterns to include certain file names in
-- your GitHub repository or repositories. File names that match the
-- patterns are included in the index. File names that don\'t match the
-- patterns are excluded from the index. If a file matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the file isn\'t included in the index.
gitHubConfiguration_inclusionFileNamePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_inclusionFileNamePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_inclusionFileNamePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
inclusionFileNamePatterns :: Maybe [Text]
$sel:inclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
inclusionFileNamePatterns} -> Maybe [Text]
inclusionFileNamePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:inclusionFileNamePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFileNamePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of regular expression patterns to include certain file types in
-- your GitHub repository or repositories. File types that match the
-- patterns are included in the index. File types that don\'t match the
-- patterns are excluded from the index. If a file matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the file isn\'t included in the index.
gitHubConfiguration_inclusionFileTypePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_inclusionFileTypePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_inclusionFileTypePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
inclusionFileTypePatterns :: Maybe [Text]
$sel:inclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
inclusionFileTypePatterns} -> Maybe [Text]
inclusionFileTypePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:inclusionFileTypePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFileTypePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of regular expression patterns to include certain folder names in
-- your GitHub repository or repositories. Folder names that match the
-- patterns are included in the index. Folder names that don\'t match the
-- patterns are excluded from the index. If a folder matches both an
-- inclusion and exclusion pattern, the exclusion pattern takes precedence
-- and the folder isn\'t included in the index.
gitHubConfiguration_inclusionFolderNamePatterns :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_inclusionFolderNamePatterns :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_inclusionFolderNamePatterns = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
inclusionFolderNamePatterns :: Maybe [Text]
$sel:inclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
inclusionFolderNamePatterns} -> Maybe [Text]
inclusionFolderNamePatterns) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:inclusionFolderNamePatterns:GitHubConfiguration' :: Maybe [Text]
inclusionFolderNamePatterns = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Configuration information to connect to GitHub Enterprise Server (on
-- premises).
gitHubConfiguration_onPremiseConfiguration :: Lens.Lens' GitHubConfiguration (Prelude.Maybe OnPremiseConfiguration)
gitHubConfiguration_onPremiseConfiguration :: Lens' GitHubConfiguration (Maybe OnPremiseConfiguration)
gitHubConfiguration_onPremiseConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe OnPremiseConfiguration
onPremiseConfiguration :: Maybe OnPremiseConfiguration
$sel:onPremiseConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe OnPremiseConfiguration
onPremiseConfiguration} -> Maybe OnPremiseConfiguration
onPremiseConfiguration) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe OnPremiseConfiguration
a -> GitHubConfiguration
s {$sel:onPremiseConfiguration:GitHubConfiguration' :: Maybe OnPremiseConfiguration
onPremiseConfiguration = Maybe OnPremiseConfiguration
a} :: GitHubConfiguration)

-- | A list of names of the specific repositories you want to index.
gitHubConfiguration_repositoryFilter :: Lens.Lens' GitHubConfiguration (Prelude.Maybe [Prelude.Text])
gitHubConfiguration_repositoryFilter :: Lens' GitHubConfiguration (Maybe [Text])
gitHubConfiguration_repositoryFilter = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe [Text]
repositoryFilter :: Maybe [Text]
$sel:repositoryFilter:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
repositoryFilter} -> Maybe [Text]
repositoryFilter) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe [Text]
a -> GitHubConfiguration
s {$sel:repositoryFilter:GitHubConfiguration' :: Maybe [Text]
repositoryFilter = Maybe [Text]
a} :: GitHubConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Configuration information to connect to GitHub Enterprise Cloud (SaaS).
gitHubConfiguration_saaSConfiguration :: Lens.Lens' GitHubConfiguration (Prelude.Maybe SaaSConfiguration)
gitHubConfiguration_saaSConfiguration :: Lens' GitHubConfiguration (Maybe SaaSConfiguration)
gitHubConfiguration_saaSConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe SaaSConfiguration
saaSConfiguration :: Maybe SaaSConfiguration
$sel:saaSConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe SaaSConfiguration
saaSConfiguration} -> Maybe SaaSConfiguration
saaSConfiguration) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe SaaSConfiguration
a -> GitHubConfiguration
s {$sel:saaSConfiguration:GitHubConfiguration' :: Maybe SaaSConfiguration
saaSConfiguration = Maybe SaaSConfiguration
a} :: GitHubConfiguration)

-- | The type of GitHub service you want to connect to—GitHub Enterprise
-- Cloud (SaaS) or GitHub Enterprise Server (on premises).
gitHubConfiguration_type :: Lens.Lens' GitHubConfiguration (Prelude.Maybe Type)
gitHubConfiguration_type :: Lens' GitHubConfiguration (Maybe Type)
gitHubConfiguration_type = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe Type
type' :: Maybe Type
$sel:type':GitHubConfiguration' :: GitHubConfiguration -> Maybe Type
type'} -> Maybe Type
type') (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe Type
a -> GitHubConfiguration
s {$sel:type':GitHubConfiguration' :: Maybe Type
type' = Maybe Type
a} :: GitHubConfiguration)

-- | @TRUE@ to use the GitHub change log to determine which documents require
-- updating in the index. Depending on the GitHub change log\'s size, it
-- may take longer for Amazon Kendra to use the change log than to scan all
-- of your documents in GitHub.
gitHubConfiguration_useChangeLog :: Lens.Lens' GitHubConfiguration (Prelude.Maybe Prelude.Bool)
gitHubConfiguration_useChangeLog :: Lens' GitHubConfiguration (Maybe Bool)
gitHubConfiguration_useChangeLog = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe Bool
useChangeLog :: Maybe Bool
$sel:useChangeLog:GitHubConfiguration' :: GitHubConfiguration -> Maybe Bool
useChangeLog} -> Maybe Bool
useChangeLog) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe Bool
a -> GitHubConfiguration
s {$sel:useChangeLog:GitHubConfiguration' :: Maybe Bool
useChangeLog = Maybe Bool
a} :: GitHubConfiguration)

-- | Configuration information of an Amazon Virtual Private Cloud to connect
-- to your GitHub. For more information, see
-- <https://docs.aws.amazon.com/kendra/latest/dg/vpc-configuration.html Configuring a VPC>.
gitHubConfiguration_vpcConfiguration :: Lens.Lens' GitHubConfiguration (Prelude.Maybe DataSourceVpcConfiguration)
gitHubConfiguration_vpcConfiguration :: Lens' GitHubConfiguration (Maybe DataSourceVpcConfiguration)
gitHubConfiguration_vpcConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Maybe DataSourceVpcConfiguration
vpcConfiguration :: Maybe DataSourceVpcConfiguration
$sel:vpcConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe DataSourceVpcConfiguration
vpcConfiguration} -> Maybe DataSourceVpcConfiguration
vpcConfiguration) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Maybe DataSourceVpcConfiguration
a -> GitHubConfiguration
s {$sel:vpcConfiguration:GitHubConfiguration' :: Maybe DataSourceVpcConfiguration
vpcConfiguration = Maybe DataSourceVpcConfiguration
a} :: GitHubConfiguration)

-- | The Amazon Resource Name (ARN) of an Secrets Manager secret that
-- contains the key-value pairs required to connect to your GitHub. The
-- secret must contain a JSON structure with the following keys:
--
-- -   personalToken—The access token created in GitHub. For more
--     information on creating a token in GitHub, see
--     <https://docs.aws.amazon.com/kendra/latest/dg/data-source-github.html Using a GitHub data source>.
gitHubConfiguration_secretArn :: Lens.Lens' GitHubConfiguration Prelude.Text
gitHubConfiguration_secretArn :: Lens' GitHubConfiguration Text
gitHubConfiguration_secretArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GitHubConfiguration' {Text
secretArn :: Text
$sel:secretArn:GitHubConfiguration' :: GitHubConfiguration -> Text
secretArn} -> Text
secretArn) (\s :: GitHubConfiguration
s@GitHubConfiguration' {} Text
a -> GitHubConfiguration
s {$sel:secretArn:GitHubConfiguration' :: Text
secretArn = Text
a} :: GitHubConfiguration)

instance Data.FromJSON GitHubConfiguration where
  parseJSON :: Value -> Parser GitHubConfiguration
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"GitHubConfiguration"
      ( \Object
x ->
          Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe GitHubDocumentCrawlProperties
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe OnPremiseConfiguration
-> Maybe [Text]
-> Maybe SaaSConfiguration
-> Maybe Type
-> Maybe Bool
-> Maybe DataSourceVpcConfiguration
-> Text
-> GitHubConfiguration
GitHubConfiguration'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ExclusionFileNamePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ExclusionFileTypePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ExclusionFolderNamePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubCommitConfigurationFieldMappings")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubDocumentCrawlProperties")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubIssueAttachmentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubIssueCommentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubIssueDocumentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubPullRequestCommentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubPullRequestDocumentAttachmentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubPullRequestDocumentConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GitHubRepositoryConfigurationFieldMappings"
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"InclusionFileNamePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"InclusionFileTypePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"InclusionFolderNamePatterns"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"OnPremiseConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"RepositoryFilter"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"SaaSConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Type")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"UseChangeLog")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"VpcConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"SecretArn")
      )

instance Prelude.Hashable GitHubConfiguration where
  hashWithSalt :: Int -> GitHubConfiguration -> Int
hashWithSalt Int
_salt GitHubConfiguration' {Maybe Bool
Maybe [Text]
Maybe (NonEmpty DataSourceToIndexFieldMapping)
Maybe DataSourceVpcConfiguration
Maybe GitHubDocumentCrawlProperties
Maybe OnPremiseConfiguration
Maybe SaaSConfiguration
Maybe Type
Text
secretArn :: Text
vpcConfiguration :: Maybe DataSourceVpcConfiguration
useChangeLog :: Maybe Bool
type' :: Maybe Type
saaSConfiguration :: Maybe SaaSConfiguration
repositoryFilter :: Maybe [Text]
onPremiseConfiguration :: Maybe OnPremiseConfiguration
inclusionFolderNamePatterns :: Maybe [Text]
inclusionFileTypePatterns :: Maybe [Text]
inclusionFileNamePatterns :: Maybe [Text]
gitHubRepositoryConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubDocumentCrawlProperties :: Maybe GitHubDocumentCrawlProperties
gitHubCommitConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
exclusionFolderNamePatterns :: Maybe [Text]
exclusionFileTypePatterns :: Maybe [Text]
exclusionFileNamePatterns :: Maybe [Text]
$sel:secretArn:GitHubConfiguration' :: GitHubConfiguration -> Text
$sel:vpcConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe DataSourceVpcConfiguration
$sel:useChangeLog:GitHubConfiguration' :: GitHubConfiguration -> Maybe Bool
$sel:type':GitHubConfiguration' :: GitHubConfiguration -> Maybe Type
$sel:saaSConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe SaaSConfiguration
$sel:repositoryFilter:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:onPremiseConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe OnPremiseConfiguration
$sel:inclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: GitHubConfiguration -> Maybe GitHubDocumentCrawlProperties
$sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:exclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
exclusionFileNamePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
exclusionFileTypePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
exclusionFolderNamePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
inclusionFileNamePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
inclusionFileTypePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
inclusionFolderNamePatterns
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe OnPremiseConfiguration
onPremiseConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
repositoryFilter
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SaaSConfiguration
saaSConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Type
type'
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
useChangeLog
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe DataSourceVpcConfiguration
vpcConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
secretArn

instance Prelude.NFData GitHubConfiguration where
  rnf :: GitHubConfiguration -> ()
rnf GitHubConfiguration' {Maybe Bool
Maybe [Text]
Maybe (NonEmpty DataSourceToIndexFieldMapping)
Maybe DataSourceVpcConfiguration
Maybe GitHubDocumentCrawlProperties
Maybe OnPremiseConfiguration
Maybe SaaSConfiguration
Maybe Type
Text
secretArn :: Text
vpcConfiguration :: Maybe DataSourceVpcConfiguration
useChangeLog :: Maybe Bool
type' :: Maybe Type
saaSConfiguration :: Maybe SaaSConfiguration
repositoryFilter :: Maybe [Text]
onPremiseConfiguration :: Maybe OnPremiseConfiguration
inclusionFolderNamePatterns :: Maybe [Text]
inclusionFileTypePatterns :: Maybe [Text]
inclusionFileNamePatterns :: Maybe [Text]
gitHubRepositoryConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubDocumentCrawlProperties :: Maybe GitHubDocumentCrawlProperties
gitHubCommitConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
exclusionFolderNamePatterns :: Maybe [Text]
exclusionFileTypePatterns :: Maybe [Text]
exclusionFileNamePatterns :: Maybe [Text]
$sel:secretArn:GitHubConfiguration' :: GitHubConfiguration -> Text
$sel:vpcConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe DataSourceVpcConfiguration
$sel:useChangeLog:GitHubConfiguration' :: GitHubConfiguration -> Maybe Bool
$sel:type':GitHubConfiguration' :: GitHubConfiguration -> Maybe Type
$sel:saaSConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe SaaSConfiguration
$sel:repositoryFilter:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:onPremiseConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe OnPremiseConfiguration
$sel:inclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: GitHubConfiguration -> Maybe GitHubDocumentCrawlProperties
$sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:exclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
exclusionFileNamePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
exclusionFileTypePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
exclusionFolderNamePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf
        Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
inclusionFileNamePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
inclusionFileTypePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
inclusionFolderNamePatterns
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe OnPremiseConfiguration
onPremiseConfiguration
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
repositoryFilter
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SaaSConfiguration
saaSConfiguration
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Type
type'
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
useChangeLog
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe DataSourceVpcConfiguration
vpcConfiguration
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
secretArn

instance Data.ToJSON GitHubConfiguration where
  toJSON :: GitHubConfiguration -> Value
toJSON GitHubConfiguration' {Maybe Bool
Maybe [Text]
Maybe (NonEmpty DataSourceToIndexFieldMapping)
Maybe DataSourceVpcConfiguration
Maybe GitHubDocumentCrawlProperties
Maybe OnPremiseConfiguration
Maybe SaaSConfiguration
Maybe Type
Text
secretArn :: Text
vpcConfiguration :: Maybe DataSourceVpcConfiguration
useChangeLog :: Maybe Bool
type' :: Maybe Type
saaSConfiguration :: Maybe SaaSConfiguration
repositoryFilter :: Maybe [Text]
onPremiseConfiguration :: Maybe OnPremiseConfiguration
inclusionFolderNamePatterns :: Maybe [Text]
inclusionFileTypePatterns :: Maybe [Text]
inclusionFileNamePatterns :: Maybe [Text]
gitHubRepositoryConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubDocumentCrawlProperties :: Maybe GitHubDocumentCrawlProperties
gitHubCommitConfigurationFieldMappings :: Maybe (NonEmpty DataSourceToIndexFieldMapping)
exclusionFolderNamePatterns :: Maybe [Text]
exclusionFileTypePatterns :: Maybe [Text]
exclusionFileNamePatterns :: Maybe [Text]
$sel:secretArn:GitHubConfiguration' :: GitHubConfiguration -> Text
$sel:vpcConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe DataSourceVpcConfiguration
$sel:useChangeLog:GitHubConfiguration' :: GitHubConfiguration -> Maybe Bool
$sel:type':GitHubConfiguration' :: GitHubConfiguration -> Maybe Type
$sel:saaSConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe SaaSConfiguration
$sel:repositoryFilter:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:onPremiseConfiguration:GitHubConfiguration' :: GitHubConfiguration -> Maybe OnPremiseConfiguration
$sel:inclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:inclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:gitHubRepositoryConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestDocumentAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubPullRequestCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueDocumentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueCommentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubIssueAttachmentConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:gitHubDocumentCrawlProperties:GitHubConfiguration' :: GitHubConfiguration -> Maybe GitHubDocumentCrawlProperties
$sel:gitHubCommitConfigurationFieldMappings:GitHubConfiguration' :: GitHubConfiguration
-> Maybe (NonEmpty DataSourceToIndexFieldMapping)
$sel:exclusionFolderNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileTypePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
$sel:exclusionFileNamePatterns:GitHubConfiguration' :: GitHubConfiguration -> Maybe [Text]
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"ExclusionFileNamePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
exclusionFileNamePatterns,
            (Key
"ExclusionFileTypePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
exclusionFileTypePatterns,
            (Key
"ExclusionFolderNamePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
exclusionFolderNamePatterns,
            (Key
"GitHubCommitConfigurationFieldMappings" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubCommitConfigurationFieldMappings,
            (Key
"GitHubDocumentCrawlProperties" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe GitHubDocumentCrawlProperties
gitHubDocumentCrawlProperties,
            ( Key
"GitHubIssueAttachmentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueAttachmentConfigurationFieldMappings,
            ( Key
"GitHubIssueCommentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueCommentConfigurationFieldMappings,
            ( Key
"GitHubIssueDocumentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubIssueDocumentConfigurationFieldMappings,
            ( Key
"GitHubPullRequestCommentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestCommentConfigurationFieldMappings,
            ( Key
"GitHubPullRequestDocumentAttachmentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentAttachmentConfigurationFieldMappings,
            ( Key
"GitHubPullRequestDocumentConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubPullRequestDocumentConfigurationFieldMappings,
            ( Key
"GitHubRepositoryConfigurationFieldMappings"
                forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=
            )
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataSourceToIndexFieldMapping)
gitHubRepositoryConfigurationFieldMappings,
            (Key
"InclusionFileNamePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
inclusionFileNamePatterns,
            (Key
"InclusionFileTypePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
inclusionFileTypePatterns,
            (Key
"InclusionFolderNamePatterns" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
inclusionFolderNamePatterns,
            (Key
"OnPremiseConfiguration" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe OnPremiseConfiguration
onPremiseConfiguration,
            (Key
"RepositoryFilter" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
repositoryFilter,
            (Key
"SaaSConfiguration" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SaaSConfiguration
saaSConfiguration,
            (Key
"Type" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Type
type',
            (Key
"UseChangeLog" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
useChangeLog,
            (Key
"VpcConfiguration" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DataSourceVpcConfiguration
vpcConfiguration,
            forall a. a -> Maybe a
Prelude.Just (Key
"SecretArn" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
secretArn)
          ]
      )