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

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

-- |
-- Module      : Amazonka.ServerlessApplicationRepository.CreateApplication
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Creates an application, optionally including an AWS SAM file to create
-- the first application version in the same call.
module Amazonka.ServerlessApplicationRepository.CreateApplication
  ( -- * Creating a Request
    CreateApplication (..),
    newCreateApplication,

    -- * Request Lenses
    createApplication_homePageUrl,
    createApplication_readmeBody,
    createApplication_licenseUrl,
    createApplication_semanticVersion,
    createApplication_sourceCodeUrl,
    createApplication_readmeUrl,
    createApplication_labels,
    createApplication_templateBody,
    createApplication_templateUrl,
    createApplication_licenseBody,
    createApplication_spdxLicenseId,
    createApplication_sourceCodeArchiveUrl,
    createApplication_description,
    createApplication_name,
    createApplication_author,

    -- * Destructuring the Response
    CreateApplicationResponse (..),
    newCreateApplicationResponse,

    -- * Response Lenses
    createApplicationResponse_creationTime,
    createApplicationResponse_homePageUrl,
    createApplicationResponse_licenseUrl,
    createApplicationResponse_readmeUrl,
    createApplicationResponse_applicationId,
    createApplicationResponse_name,
    createApplicationResponse_version,
    createApplicationResponse_author,
    createApplicationResponse_labels,
    createApplicationResponse_verifiedAuthorUrl,
    createApplicationResponse_description,
    createApplicationResponse_spdxLicenseId,
    createApplicationResponse_isVerifiedAuthor,
    createApplicationResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.ServerlessApplicationRepository.Types

-- | /See:/ 'newCreateApplication' smart constructor.
data CreateApplication = CreateApplication'
  { -- | A URL with more information about the application, for example the
    -- location of your GitHub repository for the application.
    CreateApplication -> Maybe Text
homePageUrl :: Prelude.Maybe Prelude.Text,
    -- | A local text readme file in Markdown language that contains a more
    -- detailed description of the application and how it works. The file has
    -- the format file:\/\/\<path>\/\<filename>.
    --
    -- Maximum size 5 MB
    --
    -- You can specify only one of readmeBody and readmeUrl; otherwise, an
    -- error results.
    CreateApplication -> Maybe Text
readmeBody :: Prelude.Maybe Prelude.Text,
    -- | A link to the S3 object that contains the license of the app that
    -- matches the spdxLicenseID value of your application.
    --
    -- Maximum size 5 MB
    --
    -- You can specify only one of licenseBody and licenseUrl; otherwise, an
    -- error results.
    CreateApplication -> Maybe Text
licenseUrl :: Prelude.Maybe Prelude.Text,
    -- | The semantic version of the application:
    --
    -- <https://semver.org/>
    CreateApplication -> Maybe Text
semanticVersion :: Prelude.Maybe Prelude.Text,
    -- | A link to a public repository for the source code of your application,
    -- for example the URL of a specific GitHub commit.
    CreateApplication -> Maybe Text
sourceCodeUrl :: Prelude.Maybe Prelude.Text,
    -- | A link to the S3 object in Markdown language that contains a more
    -- detailed description of the application and how it works.
    --
    -- Maximum size 5 MB
    --
    -- You can specify only one of readmeBody and readmeUrl; otherwise, an
    -- error results.
    CreateApplication -> Maybe Text
readmeUrl :: Prelude.Maybe Prelude.Text,
    -- | Labels to improve discovery of apps in search results.
    --
    -- Minimum length=1. Maximum length=127. Maximum number of labels: 10
    --
    -- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
    CreateApplication -> Maybe [Text]
labels :: Prelude.Maybe [Prelude.Text],
    -- | The local raw packaged AWS SAM template file of your application. The
    -- file has the format file:\/\/\<path>\/\<filename>.
    --
    -- You can specify only one of templateBody and templateUrl; otherwise an
    -- error results.
    CreateApplication -> Maybe Text
templateBody :: Prelude.Maybe Prelude.Text,
    -- | A link to the S3 object containing the packaged AWS SAM template of your
    -- application.
    --
    -- You can specify only one of templateBody and templateUrl; otherwise an
    -- error results.
    CreateApplication -> Maybe Text
templateUrl :: Prelude.Maybe Prelude.Text,
    -- | A local text file that contains the license of the app that matches the
    -- spdxLicenseID value of your application. The file has the format
    -- file:\/\/\<path>\/\<filename>.
    --
    -- Maximum size 5 MB
    --
    -- You can specify only one of licenseBody and licenseUrl; otherwise, an
    -- error results.
    CreateApplication -> Maybe Text
licenseBody :: Prelude.Maybe Prelude.Text,
    -- | A valid identifier from <https://spdx.org/licenses/>.
    CreateApplication -> Maybe Text
spdxLicenseId :: Prelude.Maybe Prelude.Text,
    -- | A link to the S3 object that contains the ZIP archive of the source code
    -- for this version of your application.
    --
    -- Maximum size 50 MB
    CreateApplication -> Maybe Text
sourceCodeArchiveUrl :: Prelude.Maybe Prelude.Text,
    -- | The description of the application.
    --
    -- Minimum length=1. Maximum length=256
    CreateApplication -> Text
description :: Prelude.Text,
    -- | The name of the application that you want to publish.
    --
    -- Minimum length=1. Maximum length=140
    --
    -- Pattern: \"[a-zA-Z0-9\\\\-]+\";
    CreateApplication -> Text
name :: Prelude.Text,
    -- | The name of the author publishing the app.
    --
    -- Minimum length=1. Maximum length=127.
    --
    -- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
    CreateApplication -> Text
author :: Prelude.Text
  }
  deriving (CreateApplication -> CreateApplication -> Bool
(CreateApplication -> CreateApplication -> Bool)
-> (CreateApplication -> CreateApplication -> Bool)
-> Eq CreateApplication
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateApplication -> CreateApplication -> Bool
$c/= :: CreateApplication -> CreateApplication -> Bool
== :: CreateApplication -> CreateApplication -> Bool
$c== :: CreateApplication -> CreateApplication -> Bool
Prelude.Eq, ReadPrec [CreateApplication]
ReadPrec CreateApplication
Int -> ReadS CreateApplication
ReadS [CreateApplication]
(Int -> ReadS CreateApplication)
-> ReadS [CreateApplication]
-> ReadPrec CreateApplication
-> ReadPrec [CreateApplication]
-> Read CreateApplication
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateApplication]
$creadListPrec :: ReadPrec [CreateApplication]
readPrec :: ReadPrec CreateApplication
$creadPrec :: ReadPrec CreateApplication
readList :: ReadS [CreateApplication]
$creadList :: ReadS [CreateApplication]
readsPrec :: Int -> ReadS CreateApplication
$creadsPrec :: Int -> ReadS CreateApplication
Prelude.Read, Int -> CreateApplication -> ShowS
[CreateApplication] -> ShowS
CreateApplication -> String
(Int -> CreateApplication -> ShowS)
-> (CreateApplication -> String)
-> ([CreateApplication] -> ShowS)
-> Show CreateApplication
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateApplication] -> ShowS
$cshowList :: [CreateApplication] -> ShowS
show :: CreateApplication -> String
$cshow :: CreateApplication -> String
showsPrec :: Int -> CreateApplication -> ShowS
$cshowsPrec :: Int -> CreateApplication -> ShowS
Prelude.Show, (forall x. CreateApplication -> Rep CreateApplication x)
-> (forall x. Rep CreateApplication x -> CreateApplication)
-> Generic CreateApplication
forall x. Rep CreateApplication x -> CreateApplication
forall x. CreateApplication -> Rep CreateApplication x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateApplication x -> CreateApplication
$cfrom :: forall x. CreateApplication -> Rep CreateApplication x
Prelude.Generic)

-- |
-- Create a value of 'CreateApplication' 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:
--
-- 'homePageUrl', 'createApplication_homePageUrl' - A URL with more information about the application, for example the
-- location of your GitHub repository for the application.
--
-- 'readmeBody', 'createApplication_readmeBody' - A local text readme file in Markdown language that contains a more
-- detailed description of the application and how it works. The file has
-- the format file:\/\/\<path>\/\<filename>.
--
-- Maximum size 5 MB
--
-- You can specify only one of readmeBody and readmeUrl; otherwise, an
-- error results.
--
-- 'licenseUrl', 'createApplication_licenseUrl' - A link to the S3 object that contains the license of the app that
-- matches the spdxLicenseID value of your application.
--
-- Maximum size 5 MB
--
-- You can specify only one of licenseBody and licenseUrl; otherwise, an
-- error results.
--
-- 'semanticVersion', 'createApplication_semanticVersion' - The semantic version of the application:
--
-- <https://semver.org/>
--
-- 'sourceCodeUrl', 'createApplication_sourceCodeUrl' - A link to a public repository for the source code of your application,
-- for example the URL of a specific GitHub commit.
--
-- 'readmeUrl', 'createApplication_readmeUrl' - A link to the S3 object in Markdown language that contains a more
-- detailed description of the application and how it works.
--
-- Maximum size 5 MB
--
-- You can specify only one of readmeBody and readmeUrl; otherwise, an
-- error results.
--
-- 'labels', 'createApplication_labels' - Labels to improve discovery of apps in search results.
--
-- Minimum length=1. Maximum length=127. Maximum number of labels: 10
--
-- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
--
-- 'templateBody', 'createApplication_templateBody' - The local raw packaged AWS SAM template file of your application. The
-- file has the format file:\/\/\<path>\/\<filename>.
--
-- You can specify only one of templateBody and templateUrl; otherwise an
-- error results.
--
-- 'templateUrl', 'createApplication_templateUrl' - A link to the S3 object containing the packaged AWS SAM template of your
-- application.
--
-- You can specify only one of templateBody and templateUrl; otherwise an
-- error results.
--
-- 'licenseBody', 'createApplication_licenseBody' - A local text file that contains the license of the app that matches the
-- spdxLicenseID value of your application. The file has the format
-- file:\/\/\<path>\/\<filename>.
--
-- Maximum size 5 MB
--
-- You can specify only one of licenseBody and licenseUrl; otherwise, an
-- error results.
--
-- 'spdxLicenseId', 'createApplication_spdxLicenseId' - A valid identifier from <https://spdx.org/licenses/>.
--
-- 'sourceCodeArchiveUrl', 'createApplication_sourceCodeArchiveUrl' - A link to the S3 object that contains the ZIP archive of the source code
-- for this version of your application.
--
-- Maximum size 50 MB
--
-- 'description', 'createApplication_description' - The description of the application.
--
-- Minimum length=1. Maximum length=256
--
-- 'name', 'createApplication_name' - The name of the application that you want to publish.
--
-- Minimum length=1. Maximum length=140
--
-- Pattern: \"[a-zA-Z0-9\\\\-]+\";
--
-- 'author', 'createApplication_author' - The name of the author publishing the app.
--
-- Minimum length=1. Maximum length=127.
--
-- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
newCreateApplication ::
  -- | 'description'
  Prelude.Text ->
  -- | 'name'
  Prelude.Text ->
  -- | 'author'
  Prelude.Text ->
  CreateApplication
newCreateApplication :: Text -> Text -> Text -> CreateApplication
newCreateApplication Text
pDescription_ Text
pName_ Text
pAuthor_ =
  CreateApplication' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> Text
-> Text
-> CreateApplication
CreateApplication'
    { $sel:homePageUrl:CreateApplication' :: Maybe Text
homePageUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:readmeBody:CreateApplication' :: Maybe Text
readmeBody = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:licenseUrl:CreateApplication' :: Maybe Text
licenseUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:semanticVersion:CreateApplication' :: Maybe Text
semanticVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:sourceCodeUrl:CreateApplication' :: Maybe Text
sourceCodeUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:readmeUrl:CreateApplication' :: Maybe Text
readmeUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:labels:CreateApplication' :: Maybe [Text]
labels = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:templateBody:CreateApplication' :: Maybe Text
templateBody = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:templateUrl:CreateApplication' :: Maybe Text
templateUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:licenseBody:CreateApplication' :: Maybe Text
licenseBody = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:spdxLicenseId:CreateApplication' :: Maybe Text
spdxLicenseId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:sourceCodeArchiveUrl:CreateApplication' :: Maybe Text
sourceCodeArchiveUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:description:CreateApplication' :: Text
description = Text
pDescription_,
      $sel:name:CreateApplication' :: Text
name = Text
pName_,
      $sel:author:CreateApplication' :: Text
author = Text
pAuthor_
    }

-- | A URL with more information about the application, for example the
-- location of your GitHub repository for the application.
createApplication_homePageUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_homePageUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_homePageUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
homePageUrl :: Maybe Text
$sel:homePageUrl:CreateApplication' :: CreateApplication -> Maybe Text
homePageUrl} -> Maybe Text
homePageUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:homePageUrl:CreateApplication' :: Maybe Text
homePageUrl = Maybe Text
a} :: CreateApplication)

-- | A local text readme file in Markdown language that contains a more
-- detailed description of the application and how it works. The file has
-- the format file:\/\/\<path>\/\<filename>.
--
-- Maximum size 5 MB
--
-- You can specify only one of readmeBody and readmeUrl; otherwise, an
-- error results.
createApplication_readmeBody :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_readmeBody :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_readmeBody = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
readmeBody :: Maybe Text
$sel:readmeBody:CreateApplication' :: CreateApplication -> Maybe Text
readmeBody} -> Maybe Text
readmeBody) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:readmeBody:CreateApplication' :: Maybe Text
readmeBody = Maybe Text
a} :: CreateApplication)

-- | A link to the S3 object that contains the license of the app that
-- matches the spdxLicenseID value of your application.
--
-- Maximum size 5 MB
--
-- You can specify only one of licenseBody and licenseUrl; otherwise, an
-- error results.
createApplication_licenseUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_licenseUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_licenseUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
licenseUrl :: Maybe Text
$sel:licenseUrl:CreateApplication' :: CreateApplication -> Maybe Text
licenseUrl} -> Maybe Text
licenseUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:licenseUrl:CreateApplication' :: Maybe Text
licenseUrl = Maybe Text
a} :: CreateApplication)

-- | The semantic version of the application:
--
-- <https://semver.org/>
createApplication_semanticVersion :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_semanticVersion :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_semanticVersion = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
semanticVersion :: Maybe Text
$sel:semanticVersion:CreateApplication' :: CreateApplication -> Maybe Text
semanticVersion} -> Maybe Text
semanticVersion) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:semanticVersion:CreateApplication' :: Maybe Text
semanticVersion = Maybe Text
a} :: CreateApplication)

-- | A link to a public repository for the source code of your application,
-- for example the URL of a specific GitHub commit.
createApplication_sourceCodeUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_sourceCodeUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_sourceCodeUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
sourceCodeUrl :: Maybe Text
$sel:sourceCodeUrl:CreateApplication' :: CreateApplication -> Maybe Text
sourceCodeUrl} -> Maybe Text
sourceCodeUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:sourceCodeUrl:CreateApplication' :: Maybe Text
sourceCodeUrl = Maybe Text
a} :: CreateApplication)

-- | A link to the S3 object in Markdown language that contains a more
-- detailed description of the application and how it works.
--
-- Maximum size 5 MB
--
-- You can specify only one of readmeBody and readmeUrl; otherwise, an
-- error results.
createApplication_readmeUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_readmeUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_readmeUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
readmeUrl :: Maybe Text
$sel:readmeUrl:CreateApplication' :: CreateApplication -> Maybe Text
readmeUrl} -> Maybe Text
readmeUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:readmeUrl:CreateApplication' :: Maybe Text
readmeUrl = Maybe Text
a} :: CreateApplication)

-- | Labels to improve discovery of apps in search results.
--
-- Minimum length=1. Maximum length=127. Maximum number of labels: 10
--
-- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
createApplication_labels :: Lens.Lens' CreateApplication (Prelude.Maybe [Prelude.Text])
createApplication_labels :: (Maybe [Text] -> f (Maybe [Text]))
-> CreateApplication -> f CreateApplication
createApplication_labels = (CreateApplication -> Maybe [Text])
-> (CreateApplication -> Maybe [Text] -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe [Text]
labels :: Maybe [Text]
$sel:labels:CreateApplication' :: CreateApplication -> Maybe [Text]
labels} -> Maybe [Text]
labels) (\s :: CreateApplication
s@CreateApplication' {} Maybe [Text]
a -> CreateApplication
s {$sel:labels:CreateApplication' :: Maybe [Text]
labels = Maybe [Text]
a} :: CreateApplication) ((Maybe [Text] -> f (Maybe [Text]))
 -> CreateApplication -> f CreateApplication)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> CreateApplication
-> f CreateApplication
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The local raw packaged AWS SAM template file of your application. The
-- file has the format file:\/\/\<path>\/\<filename>.
--
-- You can specify only one of templateBody and templateUrl; otherwise an
-- error results.
createApplication_templateBody :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_templateBody :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_templateBody = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
templateBody :: Maybe Text
$sel:templateBody:CreateApplication' :: CreateApplication -> Maybe Text
templateBody} -> Maybe Text
templateBody) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:templateBody:CreateApplication' :: Maybe Text
templateBody = Maybe Text
a} :: CreateApplication)

-- | A link to the S3 object containing the packaged AWS SAM template of your
-- application.
--
-- You can specify only one of templateBody and templateUrl; otherwise an
-- error results.
createApplication_templateUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_templateUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_templateUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
templateUrl :: Maybe Text
$sel:templateUrl:CreateApplication' :: CreateApplication -> Maybe Text
templateUrl} -> Maybe Text
templateUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:templateUrl:CreateApplication' :: Maybe Text
templateUrl = Maybe Text
a} :: CreateApplication)

-- | A local text file that contains the license of the app that matches the
-- spdxLicenseID value of your application. The file has the format
-- file:\/\/\<path>\/\<filename>.
--
-- Maximum size 5 MB
--
-- You can specify only one of licenseBody and licenseUrl; otherwise, an
-- error results.
createApplication_licenseBody :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_licenseBody :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_licenseBody = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
licenseBody :: Maybe Text
$sel:licenseBody:CreateApplication' :: CreateApplication -> Maybe Text
licenseBody} -> Maybe Text
licenseBody) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:licenseBody:CreateApplication' :: Maybe Text
licenseBody = Maybe Text
a} :: CreateApplication)

-- | A valid identifier from <https://spdx.org/licenses/>.
createApplication_spdxLicenseId :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_spdxLicenseId :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_spdxLicenseId = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
spdxLicenseId :: Maybe Text
$sel:spdxLicenseId:CreateApplication' :: CreateApplication -> Maybe Text
spdxLicenseId} -> Maybe Text
spdxLicenseId) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:spdxLicenseId:CreateApplication' :: Maybe Text
spdxLicenseId = Maybe Text
a} :: CreateApplication)

-- | A link to the S3 object that contains the ZIP archive of the source code
-- for this version of your application.
--
-- Maximum size 50 MB
createApplication_sourceCodeArchiveUrl :: Lens.Lens' CreateApplication (Prelude.Maybe Prelude.Text)
createApplication_sourceCodeArchiveUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplication -> f CreateApplication
createApplication_sourceCodeArchiveUrl = (CreateApplication -> Maybe Text)
-> (CreateApplication -> Maybe Text -> CreateApplication)
-> Lens
     CreateApplication CreateApplication (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Maybe Text
sourceCodeArchiveUrl :: Maybe Text
$sel:sourceCodeArchiveUrl:CreateApplication' :: CreateApplication -> Maybe Text
sourceCodeArchiveUrl} -> Maybe Text
sourceCodeArchiveUrl) (\s :: CreateApplication
s@CreateApplication' {} Maybe Text
a -> CreateApplication
s {$sel:sourceCodeArchiveUrl:CreateApplication' :: Maybe Text
sourceCodeArchiveUrl = Maybe Text
a} :: CreateApplication)

-- | The description of the application.
--
-- Minimum length=1. Maximum length=256
createApplication_description :: Lens.Lens' CreateApplication Prelude.Text
createApplication_description :: (Text -> f Text) -> CreateApplication -> f CreateApplication
createApplication_description = (CreateApplication -> Text)
-> (CreateApplication -> Text -> CreateApplication)
-> Lens CreateApplication CreateApplication Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Text
description :: Text
$sel:description:CreateApplication' :: CreateApplication -> Text
description} -> Text
description) (\s :: CreateApplication
s@CreateApplication' {} Text
a -> CreateApplication
s {$sel:description:CreateApplication' :: Text
description = Text
a} :: CreateApplication)

-- | The name of the application that you want to publish.
--
-- Minimum length=1. Maximum length=140
--
-- Pattern: \"[a-zA-Z0-9\\\\-]+\";
createApplication_name :: Lens.Lens' CreateApplication Prelude.Text
createApplication_name :: (Text -> f Text) -> CreateApplication -> f CreateApplication
createApplication_name = (CreateApplication -> Text)
-> (CreateApplication -> Text -> CreateApplication)
-> Lens CreateApplication CreateApplication Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Text
name :: Text
$sel:name:CreateApplication' :: CreateApplication -> Text
name} -> Text
name) (\s :: CreateApplication
s@CreateApplication' {} Text
a -> CreateApplication
s {$sel:name:CreateApplication' :: Text
name = Text
a} :: CreateApplication)

-- | The name of the author publishing the app.
--
-- Minimum length=1. Maximum length=127.
--
-- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
createApplication_author :: Lens.Lens' CreateApplication Prelude.Text
createApplication_author :: (Text -> f Text) -> CreateApplication -> f CreateApplication
createApplication_author = (CreateApplication -> Text)
-> (CreateApplication -> Text -> CreateApplication)
-> Lens CreateApplication CreateApplication Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplication' {Text
author :: Text
$sel:author:CreateApplication' :: CreateApplication -> Text
author} -> Text
author) (\s :: CreateApplication
s@CreateApplication' {} Text
a -> CreateApplication
s {$sel:author:CreateApplication' :: Text
author = Text
a} :: CreateApplication)

instance Core.AWSRequest CreateApplication where
  type
    AWSResponse CreateApplication =
      CreateApplicationResponse
  request :: CreateApplication -> Request CreateApplication
request = Service -> CreateApplication -> Request CreateApplication
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateApplication
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateApplication)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateApplication))
-> Logger
-> Service
-> Proxy CreateApplication
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateApplication)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Version
-> Maybe Text
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Int
-> CreateApplicationResponse
CreateApplicationResponse'
            (Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Version
 -> Maybe Text
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Bool
 -> Int
 -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"creationTime")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"homePageUrl")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"licenseUrl")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"readmeUrl")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"applicationId")
            Either
  String
  (Maybe Text
   -> Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Version
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"name")
            Either
  String
  (Maybe Version
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Version)
-> Either
     String
     (Maybe Text
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Version)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"version")
            Either
  String
  (Maybe Text
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"author")
            Either
  String
  (Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Int
      -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"labels" Either String (Maybe (Maybe [Text]))
-> Maybe [Text] -> Either String (Maybe [Text])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Int
   -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text -> Maybe Bool -> Int -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"verifiedAuthorUrl")
            Either
  String
  (Maybe Text
   -> Maybe Text -> Maybe Bool -> Int -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text -> Maybe Bool -> Int -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"description")
            Either
  String
  (Maybe Text -> Maybe Bool -> Int -> CreateApplicationResponse)
-> Either String (Maybe Text)
-> Either String (Maybe Bool -> Int -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"spdxLicenseId")
            Either String (Maybe Bool -> Int -> CreateApplicationResponse)
-> Either String (Maybe Bool)
-> Either String (Int -> CreateApplicationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"isVerifiedAuthor")
            Either String (Int -> CreateApplicationResponse)
-> Either String Int -> Either String CreateApplicationResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable CreateApplication

instance Prelude.NFData CreateApplication

instance Core.ToHeaders CreateApplication where
  toHeaders :: CreateApplication -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateApplication -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON CreateApplication where
  toJSON :: CreateApplication -> Value
toJSON CreateApplication' {Maybe [Text]
Maybe Text
Text
author :: Text
name :: Text
description :: Text
sourceCodeArchiveUrl :: Maybe Text
spdxLicenseId :: Maybe Text
licenseBody :: Maybe Text
templateUrl :: Maybe Text
templateBody :: Maybe Text
labels :: Maybe [Text]
readmeUrl :: Maybe Text
sourceCodeUrl :: Maybe Text
semanticVersion :: Maybe Text
licenseUrl :: Maybe Text
readmeBody :: Maybe Text
homePageUrl :: Maybe Text
$sel:author:CreateApplication' :: CreateApplication -> Text
$sel:name:CreateApplication' :: CreateApplication -> Text
$sel:description:CreateApplication' :: CreateApplication -> Text
$sel:sourceCodeArchiveUrl:CreateApplication' :: CreateApplication -> Maybe Text
$sel:spdxLicenseId:CreateApplication' :: CreateApplication -> Maybe Text
$sel:licenseBody:CreateApplication' :: CreateApplication -> Maybe Text
$sel:templateUrl:CreateApplication' :: CreateApplication -> Maybe Text
$sel:templateBody:CreateApplication' :: CreateApplication -> Maybe Text
$sel:labels:CreateApplication' :: CreateApplication -> Maybe [Text]
$sel:readmeUrl:CreateApplication' :: CreateApplication -> Maybe Text
$sel:sourceCodeUrl:CreateApplication' :: CreateApplication -> Maybe Text
$sel:semanticVersion:CreateApplication' :: CreateApplication -> Maybe Text
$sel:licenseUrl:CreateApplication' :: CreateApplication -> Maybe Text
$sel:readmeBody:CreateApplication' :: CreateApplication -> Maybe Text
$sel:homePageUrl:CreateApplication' :: CreateApplication -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"homePageUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
homePageUrl,
            (Text
"readmeBody" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
readmeBody,
            (Text
"licenseUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
licenseUrl,
            (Text
"semanticVersion" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
semanticVersion,
            (Text
"sourceCodeUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sourceCodeUrl,
            (Text
"readmeUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
readmeUrl,
            (Text
"labels" Text -> [Text] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Text] -> Pair) -> Maybe [Text] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
labels,
            (Text
"templateBody" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
templateBody,
            (Text
"templateUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
templateUrl,
            (Text
"licenseBody" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
licenseBody,
            (Text
"spdxLicenseId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
spdxLicenseId,
            (Text
"sourceCodeArchiveUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sourceCodeArchiveUrl,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"description" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
description),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"author" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
author)
          ]
      )

instance Core.ToPath CreateApplication where
  toPath :: CreateApplication -> ByteString
toPath = ByteString -> CreateApplication -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/applications"

instance Core.ToQuery CreateApplication where
  toQuery :: CreateApplication -> QueryString
toQuery = QueryString -> CreateApplication -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newCreateApplicationResponse' smart constructor.
data CreateApplicationResponse = CreateApplicationResponse'
  { -- | The date and time this resource was created.
    CreateApplicationResponse -> Maybe Text
creationTime :: Prelude.Maybe Prelude.Text,
    -- | A URL with more information about the application, for example the
    -- location of your GitHub repository for the application.
    CreateApplicationResponse -> Maybe Text
homePageUrl :: Prelude.Maybe Prelude.Text,
    -- | A link to a license file of the app that matches the spdxLicenseID value
    -- of your application.
    --
    -- Maximum size 5 MB
    CreateApplicationResponse -> Maybe Text
licenseUrl :: Prelude.Maybe Prelude.Text,
    -- | A link to the readme file in Markdown language that contains a more
    -- detailed description of the application and how it works.
    --
    -- Maximum size 5 MB
    CreateApplicationResponse -> Maybe Text
readmeUrl :: Prelude.Maybe Prelude.Text,
    -- | The application Amazon Resource Name (ARN).
    CreateApplicationResponse -> Maybe Text
applicationId :: Prelude.Maybe Prelude.Text,
    -- | The name of the application.
    --
    -- Minimum length=1. Maximum length=140
    --
    -- Pattern: \"[a-zA-Z0-9\\\\-]+\";
    CreateApplicationResponse -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | Version information about the application.
    CreateApplicationResponse -> Maybe Version
version :: Prelude.Maybe Version,
    -- | The name of the author publishing the app.
    --
    -- Minimum length=1. Maximum length=127.
    --
    -- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
    CreateApplicationResponse -> Maybe Text
author :: Prelude.Maybe Prelude.Text,
    -- | Labels to improve discovery of apps in search results.
    --
    -- Minimum length=1. Maximum length=127. Maximum number of labels: 10
    --
    -- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
    CreateApplicationResponse -> Maybe [Text]
labels :: Prelude.Maybe [Prelude.Text],
    -- | The URL to the public profile of a verified author. This URL is
    -- submitted by the author.
    CreateApplicationResponse -> Maybe Text
verifiedAuthorUrl :: Prelude.Maybe Prelude.Text,
    -- | The description of the application.
    --
    -- Minimum length=1. Maximum length=256
    CreateApplicationResponse -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | A valid identifier from https:\/\/spdx.org\/licenses\/.
    CreateApplicationResponse -> Maybe Text
spdxLicenseId :: Prelude.Maybe Prelude.Text,
    -- | Whether the author of this application has been verified. This means
    -- means that AWS has made a good faith review, as a reasonable and prudent
    -- service provider, of the information provided by the requester and has
    -- confirmed that the requester\'s identity is as claimed.
    CreateApplicationResponse -> Maybe Bool
isVerifiedAuthor :: Prelude.Maybe Prelude.Bool,
    -- | The response's http status code.
    CreateApplicationResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateApplicationResponse -> CreateApplicationResponse -> Bool
(CreateApplicationResponse -> CreateApplicationResponse -> Bool)
-> (CreateApplicationResponse -> CreateApplicationResponse -> Bool)
-> Eq CreateApplicationResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateApplicationResponse -> CreateApplicationResponse -> Bool
$c/= :: CreateApplicationResponse -> CreateApplicationResponse -> Bool
== :: CreateApplicationResponse -> CreateApplicationResponse -> Bool
$c== :: CreateApplicationResponse -> CreateApplicationResponse -> Bool
Prelude.Eq, ReadPrec [CreateApplicationResponse]
ReadPrec CreateApplicationResponse
Int -> ReadS CreateApplicationResponse
ReadS [CreateApplicationResponse]
(Int -> ReadS CreateApplicationResponse)
-> ReadS [CreateApplicationResponse]
-> ReadPrec CreateApplicationResponse
-> ReadPrec [CreateApplicationResponse]
-> Read CreateApplicationResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateApplicationResponse]
$creadListPrec :: ReadPrec [CreateApplicationResponse]
readPrec :: ReadPrec CreateApplicationResponse
$creadPrec :: ReadPrec CreateApplicationResponse
readList :: ReadS [CreateApplicationResponse]
$creadList :: ReadS [CreateApplicationResponse]
readsPrec :: Int -> ReadS CreateApplicationResponse
$creadsPrec :: Int -> ReadS CreateApplicationResponse
Prelude.Read, Int -> CreateApplicationResponse -> ShowS
[CreateApplicationResponse] -> ShowS
CreateApplicationResponse -> String
(Int -> CreateApplicationResponse -> ShowS)
-> (CreateApplicationResponse -> String)
-> ([CreateApplicationResponse] -> ShowS)
-> Show CreateApplicationResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateApplicationResponse] -> ShowS
$cshowList :: [CreateApplicationResponse] -> ShowS
show :: CreateApplicationResponse -> String
$cshow :: CreateApplicationResponse -> String
showsPrec :: Int -> CreateApplicationResponse -> ShowS
$cshowsPrec :: Int -> CreateApplicationResponse -> ShowS
Prelude.Show, (forall x.
 CreateApplicationResponse -> Rep CreateApplicationResponse x)
-> (forall x.
    Rep CreateApplicationResponse x -> CreateApplicationResponse)
-> Generic CreateApplicationResponse
forall x.
Rep CreateApplicationResponse x -> CreateApplicationResponse
forall x.
CreateApplicationResponse -> Rep CreateApplicationResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateApplicationResponse x -> CreateApplicationResponse
$cfrom :: forall x.
CreateApplicationResponse -> Rep CreateApplicationResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateApplicationResponse' 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:
--
-- 'creationTime', 'createApplicationResponse_creationTime' - The date and time this resource was created.
--
-- 'homePageUrl', 'createApplicationResponse_homePageUrl' - A URL with more information about the application, for example the
-- location of your GitHub repository for the application.
--
-- 'licenseUrl', 'createApplicationResponse_licenseUrl' - A link to a license file of the app that matches the spdxLicenseID value
-- of your application.
--
-- Maximum size 5 MB
--
-- 'readmeUrl', 'createApplicationResponse_readmeUrl' - A link to the readme file in Markdown language that contains a more
-- detailed description of the application and how it works.
--
-- Maximum size 5 MB
--
-- 'applicationId', 'createApplicationResponse_applicationId' - The application Amazon Resource Name (ARN).
--
-- 'name', 'createApplicationResponse_name' - The name of the application.
--
-- Minimum length=1. Maximum length=140
--
-- Pattern: \"[a-zA-Z0-9\\\\-]+\";
--
-- 'version', 'createApplicationResponse_version' - Version information about the application.
--
-- 'author', 'createApplicationResponse_author' - The name of the author publishing the app.
--
-- Minimum length=1. Maximum length=127.
--
-- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
--
-- 'labels', 'createApplicationResponse_labels' - Labels to improve discovery of apps in search results.
--
-- Minimum length=1. Maximum length=127. Maximum number of labels: 10
--
-- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
--
-- 'verifiedAuthorUrl', 'createApplicationResponse_verifiedAuthorUrl' - The URL to the public profile of a verified author. This URL is
-- submitted by the author.
--
-- 'description', 'createApplicationResponse_description' - The description of the application.
--
-- Minimum length=1. Maximum length=256
--
-- 'spdxLicenseId', 'createApplicationResponse_spdxLicenseId' - A valid identifier from https:\/\/spdx.org\/licenses\/.
--
-- 'isVerifiedAuthor', 'createApplicationResponse_isVerifiedAuthor' - Whether the author of this application has been verified. This means
-- means that AWS has made a good faith review, as a reasonable and prudent
-- service provider, of the information provided by the requester and has
-- confirmed that the requester\'s identity is as claimed.
--
-- 'httpStatus', 'createApplicationResponse_httpStatus' - The response's http status code.
newCreateApplicationResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateApplicationResponse
newCreateApplicationResponse :: Int -> CreateApplicationResponse
newCreateApplicationResponse Int
pHttpStatus_ =
  CreateApplicationResponse' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Version
-> Maybe Text
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Int
-> CreateApplicationResponse
CreateApplicationResponse'
    { $sel:creationTime:CreateApplicationResponse' :: Maybe Text
creationTime =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:homePageUrl:CreateApplicationResponse' :: Maybe Text
homePageUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:licenseUrl:CreateApplicationResponse' :: Maybe Text
licenseUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:readmeUrl:CreateApplicationResponse' :: Maybe Text
readmeUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:applicationId:CreateApplicationResponse' :: Maybe Text
applicationId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:CreateApplicationResponse' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:version:CreateApplicationResponse' :: Maybe Version
version = Maybe Version
forall a. Maybe a
Prelude.Nothing,
      $sel:author:CreateApplicationResponse' :: Maybe Text
author = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:labels:CreateApplicationResponse' :: Maybe [Text]
labels = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:verifiedAuthorUrl:CreateApplicationResponse' :: Maybe Text
verifiedAuthorUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:description:CreateApplicationResponse' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:spdxLicenseId:CreateApplicationResponse' :: Maybe Text
spdxLicenseId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:isVerifiedAuthor:CreateApplicationResponse' :: Maybe Bool
isVerifiedAuthor = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateApplicationResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The date and time this resource was created.
createApplicationResponse_creationTime :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_creationTime :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_creationTime = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
creationTime :: Maybe Text
$sel:creationTime:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
creationTime} -> Maybe Text
creationTime) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:creationTime:CreateApplicationResponse' :: Maybe Text
creationTime = Maybe Text
a} :: CreateApplicationResponse)

-- | A URL with more information about the application, for example the
-- location of your GitHub repository for the application.
createApplicationResponse_homePageUrl :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_homePageUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_homePageUrl = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
homePageUrl :: Maybe Text
$sel:homePageUrl:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
homePageUrl} -> Maybe Text
homePageUrl) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:homePageUrl:CreateApplicationResponse' :: Maybe Text
homePageUrl = Maybe Text
a} :: CreateApplicationResponse)

-- | A link to a license file of the app that matches the spdxLicenseID value
-- of your application.
--
-- Maximum size 5 MB
createApplicationResponse_licenseUrl :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_licenseUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_licenseUrl = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
licenseUrl :: Maybe Text
$sel:licenseUrl:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
licenseUrl} -> Maybe Text
licenseUrl) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:licenseUrl:CreateApplicationResponse' :: Maybe Text
licenseUrl = Maybe Text
a} :: CreateApplicationResponse)

-- | A link to the readme file in Markdown language that contains a more
-- detailed description of the application and how it works.
--
-- Maximum size 5 MB
createApplicationResponse_readmeUrl :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_readmeUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_readmeUrl = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
readmeUrl :: Maybe Text
$sel:readmeUrl:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
readmeUrl} -> Maybe Text
readmeUrl) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:readmeUrl:CreateApplicationResponse' :: Maybe Text
readmeUrl = Maybe Text
a} :: CreateApplicationResponse)

-- | The application Amazon Resource Name (ARN).
createApplicationResponse_applicationId :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_applicationId :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_applicationId = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
applicationId :: Maybe Text
$sel:applicationId:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
applicationId} -> Maybe Text
applicationId) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:applicationId:CreateApplicationResponse' :: Maybe Text
applicationId = Maybe Text
a} :: CreateApplicationResponse)

-- | The name of the application.
--
-- Minimum length=1. Maximum length=140
--
-- Pattern: \"[a-zA-Z0-9\\\\-]+\";
createApplicationResponse_name :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_name :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_name = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
name :: Maybe Text
$sel:name:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
name} -> Maybe Text
name) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:name:CreateApplicationResponse' :: Maybe Text
name = Maybe Text
a} :: CreateApplicationResponse)

-- | Version information about the application.
createApplicationResponse_version :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Version)
createApplicationResponse_version :: (Maybe Version -> f (Maybe Version))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_version = (CreateApplicationResponse -> Maybe Version)
-> (CreateApplicationResponse
    -> Maybe Version -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Version)
     (Maybe Version)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Version
version :: Maybe Version
$sel:version:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Version
version} -> Maybe Version
version) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Version
a -> CreateApplicationResponse
s {$sel:version:CreateApplicationResponse' :: Maybe Version
version = Maybe Version
a} :: CreateApplicationResponse)

-- | The name of the author publishing the app.
--
-- Minimum length=1. Maximum length=127.
--
-- Pattern \"^[a-z0-9](([a-z0-9]|-(?!-))*[a-z0-9])?$\";
createApplicationResponse_author :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_author :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_author = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
author :: Maybe Text
$sel:author:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
author} -> Maybe Text
author) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:author:CreateApplicationResponse' :: Maybe Text
author = Maybe Text
a} :: CreateApplicationResponse)

-- | Labels to improve discovery of apps in search results.
--
-- Minimum length=1. Maximum length=127. Maximum number of labels: 10
--
-- Pattern: \"^[a-zA-Z0-9+\\\\-_:\\\\\/\@]+$\";
createApplicationResponse_labels :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe [Prelude.Text])
createApplicationResponse_labels :: (Maybe [Text] -> f (Maybe [Text]))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_labels = (CreateApplicationResponse -> Maybe [Text])
-> (CreateApplicationResponse
    -> Maybe [Text] -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe [Text])
     (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe [Text]
labels :: Maybe [Text]
$sel:labels:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe [Text]
labels} -> Maybe [Text]
labels) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe [Text]
a -> CreateApplicationResponse
s {$sel:labels:CreateApplicationResponse' :: Maybe [Text]
labels = Maybe [Text]
a} :: CreateApplicationResponse) ((Maybe [Text] -> f (Maybe [Text]))
 -> CreateApplicationResponse -> f CreateApplicationResponse)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> CreateApplicationResponse
-> f CreateApplicationResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The URL to the public profile of a verified author. This URL is
-- submitted by the author.
createApplicationResponse_verifiedAuthorUrl :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_verifiedAuthorUrl :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_verifiedAuthorUrl = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
verifiedAuthorUrl :: Maybe Text
$sel:verifiedAuthorUrl:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
verifiedAuthorUrl} -> Maybe Text
verifiedAuthorUrl) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:verifiedAuthorUrl:CreateApplicationResponse' :: Maybe Text
verifiedAuthorUrl = Maybe Text
a} :: CreateApplicationResponse)

-- | The description of the application.
--
-- Minimum length=1. Maximum length=256
createApplicationResponse_description :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_description :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_description = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
description :: Maybe Text
$sel:description:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:description:CreateApplicationResponse' :: Maybe Text
description = Maybe Text
a} :: CreateApplicationResponse)

-- | A valid identifier from https:\/\/spdx.org\/licenses\/.
createApplicationResponse_spdxLicenseId :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Text)
createApplicationResponse_spdxLicenseId :: (Maybe Text -> f (Maybe Text))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_spdxLicenseId = (CreateApplicationResponse -> Maybe Text)
-> (CreateApplicationResponse
    -> Maybe Text -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Text
spdxLicenseId :: Maybe Text
$sel:spdxLicenseId:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Text
spdxLicenseId} -> Maybe Text
spdxLicenseId) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Text
a -> CreateApplicationResponse
s {$sel:spdxLicenseId:CreateApplicationResponse' :: Maybe Text
spdxLicenseId = Maybe Text
a} :: CreateApplicationResponse)

-- | Whether the author of this application has been verified. This means
-- means that AWS has made a good faith review, as a reasonable and prudent
-- service provider, of the information provided by the requester and has
-- confirmed that the requester\'s identity is as claimed.
createApplicationResponse_isVerifiedAuthor :: Lens.Lens' CreateApplicationResponse (Prelude.Maybe Prelude.Bool)
createApplicationResponse_isVerifiedAuthor :: (Maybe Bool -> f (Maybe Bool))
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_isVerifiedAuthor = (CreateApplicationResponse -> Maybe Bool)
-> (CreateApplicationResponse
    -> Maybe Bool -> CreateApplicationResponse)
-> Lens
     CreateApplicationResponse
     CreateApplicationResponse
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Maybe Bool
isVerifiedAuthor :: Maybe Bool
$sel:isVerifiedAuthor:CreateApplicationResponse' :: CreateApplicationResponse -> Maybe Bool
isVerifiedAuthor} -> Maybe Bool
isVerifiedAuthor) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Maybe Bool
a -> CreateApplicationResponse
s {$sel:isVerifiedAuthor:CreateApplicationResponse' :: Maybe Bool
isVerifiedAuthor = Maybe Bool
a} :: CreateApplicationResponse)

-- | The response's http status code.
createApplicationResponse_httpStatus :: Lens.Lens' CreateApplicationResponse Prelude.Int
createApplicationResponse_httpStatus :: (Int -> f Int)
-> CreateApplicationResponse -> f CreateApplicationResponse
createApplicationResponse_httpStatus = (CreateApplicationResponse -> Int)
-> (CreateApplicationResponse -> Int -> CreateApplicationResponse)
-> Lens CreateApplicationResponse CreateApplicationResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateApplicationResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateApplicationResponse' :: CreateApplicationResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateApplicationResponse
s@CreateApplicationResponse' {} Int
a -> CreateApplicationResponse
s {$sel:httpStatus:CreateApplicationResponse' :: Int
httpStatus = Int
a} :: CreateApplicationResponse)

instance Prelude.NFData CreateApplicationResponse