{-# 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.Transfer.Types.ListedProfile -- 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.Transfer.Types.ListedProfile where import qualified Amazonka.Core as Core import qualified Amazonka.Core.Lens.Internal as Lens import qualified Amazonka.Data as Data import qualified Amazonka.Prelude as Prelude import Amazonka.Transfer.Types.ProfileType -- | Returns the properties of the profile that was specified. -- -- /See:/ 'newListedProfile' smart constructor. data ListedProfile = ListedProfile' { -- | The Amazon Resource Name (ARN) of the specified profile. arn :: Prelude.Maybe Prelude.Text, -- | The @As2Id@ is the /AS2-name/, as defined in the -- . For inbound -- transfers, this is the @AS2-From@ header for the AS2 messages sent from -- the partner. For outbound connectors, this is the @AS2-To@ header for -- the AS2 messages sent to the partner using the @StartFileTransfer@ API -- operation. This ID cannot include spaces. as2Id :: Prelude.Maybe Prelude.Text, -- | A unique identifier for the local or partner AS2 profile. profileId :: Prelude.Maybe Prelude.Text, -- | Indicates whether to list only @LOCAL@ type profiles or only @PARTNER@ -- type profiles. If not supplied in the request, the command lists all -- types of profiles. profileType :: Prelude.Maybe ProfileType } deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic) -- | -- Create a value of 'ListedProfile' with all optional fields omitted. -- -- Use or to modify other optional fields. -- -- The following record fields are available, with the corresponding lenses provided -- for backwards compatibility: -- -- 'arn', 'listedProfile_arn' - The Amazon Resource Name (ARN) of the specified profile. -- -- 'as2Id', 'listedProfile_as2Id' - The @As2Id@ is the /AS2-name/, as defined in the -- . For inbound -- transfers, this is the @AS2-From@ header for the AS2 messages sent from -- the partner. For outbound connectors, this is the @AS2-To@ header for -- the AS2 messages sent to the partner using the @StartFileTransfer@ API -- operation. This ID cannot include spaces. -- -- 'profileId', 'listedProfile_profileId' - A unique identifier for the local or partner AS2 profile. -- -- 'profileType', 'listedProfile_profileType' - Indicates whether to list only @LOCAL@ type profiles or only @PARTNER@ -- type profiles. If not supplied in the request, the command lists all -- types of profiles. newListedProfile :: ListedProfile newListedProfile = ListedProfile' { arn = Prelude.Nothing, as2Id = Prelude.Nothing, profileId = Prelude.Nothing, profileType = Prelude.Nothing } -- | The Amazon Resource Name (ARN) of the specified profile. listedProfile_arn :: Lens.Lens' ListedProfile (Prelude.Maybe Prelude.Text) listedProfile_arn = Lens.lens (\ListedProfile' {arn} -> arn) (\s@ListedProfile' {} a -> s {arn = a} :: ListedProfile) -- | The @As2Id@ is the /AS2-name/, as defined in the -- . For inbound -- transfers, this is the @AS2-From@ header for the AS2 messages sent from -- the partner. For outbound connectors, this is the @AS2-To@ header for -- the AS2 messages sent to the partner using the @StartFileTransfer@ API -- operation. This ID cannot include spaces. listedProfile_as2Id :: Lens.Lens' ListedProfile (Prelude.Maybe Prelude.Text) listedProfile_as2Id = Lens.lens (\ListedProfile' {as2Id} -> as2Id) (\s@ListedProfile' {} a -> s {as2Id = a} :: ListedProfile) -- | A unique identifier for the local or partner AS2 profile. listedProfile_profileId :: Lens.Lens' ListedProfile (Prelude.Maybe Prelude.Text) listedProfile_profileId = Lens.lens (\ListedProfile' {profileId} -> profileId) (\s@ListedProfile' {} a -> s {profileId = a} :: ListedProfile) -- | Indicates whether to list only @LOCAL@ type profiles or only @PARTNER@ -- type profiles. If not supplied in the request, the command lists all -- types of profiles. listedProfile_profileType :: Lens.Lens' ListedProfile (Prelude.Maybe ProfileType) listedProfile_profileType = Lens.lens (\ListedProfile' {profileType} -> profileType) (\s@ListedProfile' {} a -> s {profileType = a} :: ListedProfile) instance Data.FromJSON ListedProfile where parseJSON = Data.withObject "ListedProfile" ( \x -> ListedProfile' Prelude.<$> (x Data..:? "Arn") Prelude.<*> (x Data..:? "As2Id") Prelude.<*> (x Data..:? "ProfileId") Prelude.<*> (x Data..:? "ProfileType") ) instance Prelude.Hashable ListedProfile where hashWithSalt _salt ListedProfile' {..} = _salt `Prelude.hashWithSalt` arn `Prelude.hashWithSalt` as2Id `Prelude.hashWithSalt` profileId `Prelude.hashWithSalt` profileType instance Prelude.NFData ListedProfile where rnf ListedProfile' {..} = Prelude.rnf arn `Prelude.seq` Prelude.rnf as2Id `Prelude.seq` Prelude.rnf profileId `Prelude.seq` Prelude.rnf profileType