{-# LANGUAGE MultiWayIf #-}
-- CHANGE WITH CAUTION: This is a generated code file generated by https://github.com/Haskell-OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator.
{-# LANGUAGE OverloadedStrings #-}

-- | Contains the types generated from the schema Reporting_ReportRun
module StripeAPI.Types.Reporting_ReportRun where

import qualified Control.Monad.Fail
import qualified Data.Aeson
import qualified Data.Aeson as Data.Aeson.Encoding.Internal
import qualified Data.Aeson as Data.Aeson.Types
import qualified Data.Aeson as Data.Aeson.Types.FromJSON
import qualified Data.Aeson as Data.Aeson.Types.Internal
import qualified Data.Aeson as Data.Aeson.Types.ToJSON
import qualified Data.ByteString.Char8
import qualified Data.ByteString.Char8 as Data.ByteString.Internal
import qualified Data.Functor
import qualified Data.Scientific
import qualified Data.Text
import qualified Data.Text.Internal
import qualified Data.Time.Calendar as Data.Time.Calendar.Days
import qualified Data.Time.LocalTime as Data.Time.LocalTime.Internal.ZonedTime
import qualified GHC.Base
import qualified GHC.Classes
import qualified GHC.Int
import qualified GHC.Show
import qualified GHC.Types
import qualified StripeAPI.Common
import StripeAPI.TypeAlias
import {-# SOURCE #-} StripeAPI.Types.File
import {-# SOURCE #-} StripeAPI.Types.FileLink
import {-# SOURCE #-} StripeAPI.Types.FinancialReportingFinanceReportRunRunParameters
import qualified Prelude as GHC.Integer.Type
import qualified Prelude as GHC.Maybe

-- | Defines the object schema located at @components.schemas.reporting.report_run@ in the specification.
--
-- The Report Run object represents an instance of a report type generated with
-- specific run parameters. Once the object is created, Stripe begins processing the report.
-- When the report has finished running, it will give you a reference to a file
-- where you can retrieve your results. For an overview, see
-- [API Access to Reports](https:\/\/stripe.com\/docs\/reporting\/statements\/api).
--
-- Note that certain report types can only be run based on your live-mode data (not test-mode
-- data), and will error when queried without a [live-mode API key](https:\/\/stripe.com\/docs\/keys\#test-live-modes).
data Reporting'reportRun = Reporting'reportRun
  { -- | created: Time at which the object was created. Measured in seconds since the Unix epoch.
    Reporting'reportRun -> Int
reporting'reportRunCreated :: GHC.Types.Int,
    -- | error: If something should go wrong during the run, a message about the failure (populated when
    --  \`status=failed\`).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRun -> Maybe Text
reporting'reportRunError :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | id: Unique identifier for the object.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRun -> Text
reporting'reportRunId :: Data.Text.Internal.Text,
    -- | livemode: \`true\` if the report is run on live mode data and \`false\` if it is run on test mode data.
    Reporting'reportRun -> Bool
reporting'reportRunLivemode :: GHC.Types.Bool,
    -- | parameters:
    Reporting'reportRun
-> FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters :: FinancialReportingFinanceReportRunRunParameters,
    -- | report_type: The ID of the [report type](https:\/\/stripe.com\/docs\/reports\/report-types) to run, such as \`\"balance.summary.1\"\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRun -> Text
reporting'reportRunReportType :: Data.Text.Internal.Text,
    -- | result: The file object representing the result of the report run (populated when
    --  \`status=succeeded\`).
    Reporting'reportRun -> Maybe Reporting'reportRunResult'
reporting'reportRunResult :: (GHC.Maybe.Maybe Reporting'reportRunResult'),
    -- | status: Status of this report run. This will be \`pending\` when the run is initially created.
    --  When the run finishes, this will be set to \`succeeded\` and the \`result\` field will be populated.
    --  Rarely, we may encounter an error, at which point this will be set to \`failed\` and the \`error\` field will be populated.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRun -> Text
reporting'reportRunStatus :: Data.Text.Internal.Text,
    -- | succeeded_at: Timestamp at which this run successfully finished (populated when
    --  \`status=succeeded\`). Measured in seconds since the Unix epoch.
    Reporting'reportRun -> Maybe Int
reporting'reportRunSucceededAt :: (GHC.Maybe.Maybe GHC.Types.Int)
  }
  deriving
    ( Int -> Reporting'reportRun -> ShowS
[Reporting'reportRun] -> ShowS
Reporting'reportRun -> String
(Int -> Reporting'reportRun -> ShowS)
-> (Reporting'reportRun -> String)
-> ([Reporting'reportRun] -> ShowS)
-> Show Reporting'reportRun
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Reporting'reportRun] -> ShowS
$cshowList :: [Reporting'reportRun] -> ShowS
show :: Reporting'reportRun -> String
$cshow :: Reporting'reportRun -> String
showsPrec :: Int -> Reporting'reportRun -> ShowS
$cshowsPrec :: Int -> Reporting'reportRun -> ShowS
GHC.Show.Show,
      Reporting'reportRun -> Reporting'reportRun -> Bool
(Reporting'reportRun -> Reporting'reportRun -> Bool)
-> (Reporting'reportRun -> Reporting'reportRun -> Bool)
-> Eq Reporting'reportRun
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Reporting'reportRun -> Reporting'reportRun -> Bool
$c/= :: Reporting'reportRun -> Reporting'reportRun -> Bool
== :: Reporting'reportRun -> Reporting'reportRun -> Bool
$c== :: Reporting'reportRun -> Reporting'reportRun -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON Reporting'reportRun where
  toJSON :: Reporting'reportRun -> Value
toJSON Reporting'reportRun
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"created" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Int
reporting'reportRunCreated Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"error" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Text
reporting'reportRunError Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"id" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunId Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"livemode" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Bool
reporting'reportRunLivemode Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"parameters" Text -> FinancialReportingFinanceReportRunRunParameters -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun
-> FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"report_type" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunReportType Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"result" Text -> Maybe Reporting'reportRunResult' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Reporting'reportRunResult'
reporting'reportRunResult Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"status" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunStatus Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"succeeded_at" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Int
reporting'reportRunSucceededAt Reporting'reportRun
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"reporting.report_run" Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: Reporting'reportRun -> Encoding
toEncoding Reporting'reportRun
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"created" Text -> Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Int
reporting'reportRunCreated Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"error" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Text
reporting'reportRunError Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"id" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunId Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"livemode" Text -> Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Bool
reporting'reportRunLivemode Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"parameters" Text -> FinancialReportingFinanceReportRunRunParameters -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun
-> FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"report_type" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunReportType Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"result" Text -> Maybe Reporting'reportRunResult' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Reporting'reportRunResult'
reporting'reportRunResult Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"status" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Text
reporting'reportRunStatus Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"succeeded_at" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRun -> Maybe Int
reporting'reportRunSucceededAt Reporting'reportRun
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"object" Text -> Value -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"reporting.report_run"))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON Reporting'reportRun where
  parseJSON :: Value -> Parser Reporting'reportRun
parseJSON = String
-> (Object -> Parser Reporting'reportRun)
-> Value
-> Parser Reporting'reportRun
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"Reporting'reportRun" (\Object
obj -> (((((((((Int
 -> Maybe Text
 -> Text
 -> Bool
 -> FinancialReportingFinanceReportRunRunParameters
 -> Text
 -> Maybe Reporting'reportRunResult'
 -> Text
 -> Maybe Int
 -> Reporting'reportRun)
-> Parser
     (Int
      -> Maybe Text
      -> Text
      -> Bool
      -> FinancialReportingFinanceReportRunRunParameters
      -> Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Int
-> Maybe Text
-> Text
-> Bool
-> FinancialReportingFinanceReportRunRunParameters
-> Text
-> Maybe Reporting'reportRunResult'
-> Text
-> Maybe Int
-> Reporting'reportRun
Reporting'reportRun Parser
  (Int
   -> Maybe Text
   -> Text
   -> Bool
   -> FinancialReportingFinanceReportRunRunParameters
   -> Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser Int
-> Parser
     (Maybe Text
      -> Text
      -> Bool
      -> FinancialReportingFinanceReportRunRunParameters
      -> Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Int
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"created")) Parser
  (Maybe Text
   -> Text
   -> Bool
   -> FinancialReportingFinanceReportRunRunParameters
   -> Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser (Maybe Text)
-> Parser
     (Text
      -> Bool
      -> FinancialReportingFinanceReportRunRunParameters
      -> Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"error")) Parser
  (Text
   -> Bool
   -> FinancialReportingFinanceReportRunRunParameters
   -> Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser Text
-> Parser
     (Bool
      -> FinancialReportingFinanceReportRunRunParameters
      -> Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"id")) Parser
  (Bool
   -> FinancialReportingFinanceReportRunRunParameters
   -> Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser Bool
-> Parser
     (FinancialReportingFinanceReportRunRunParameters
      -> Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"livemode")) Parser
  (FinancialReportingFinanceReportRunRunParameters
   -> Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser FinancialReportingFinanceReportRunRunParameters
-> Parser
     (Text
      -> Maybe Reporting'reportRunResult'
      -> Text
      -> Maybe Int
      -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser FinancialReportingFinanceReportRunRunParameters
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"parameters")) Parser
  (Text
   -> Maybe Reporting'reportRunResult'
   -> Text
   -> Maybe Int
   -> Reporting'reportRun)
-> Parser Text
-> Parser
     (Maybe Reporting'reportRunResult'
      -> Text -> Maybe Int -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"report_type")) Parser
  (Maybe Reporting'reportRunResult'
   -> Text -> Maybe Int -> Reporting'reportRun)
-> Parser (Maybe Reporting'reportRunResult')
-> Parser (Text -> Maybe Int -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Reporting'reportRunResult')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"result")) Parser (Text -> Maybe Int -> Reporting'reportRun)
-> Parser Text -> Parser (Maybe Int -> Reporting'reportRun)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"status")) Parser (Maybe Int -> Reporting'reportRun)
-> Parser (Maybe Int) -> Parser Reporting'reportRun
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"succeeded_at"))

-- | Create a new 'Reporting'reportRun' with all required fields.
mkReporting'reportRun ::
  -- | 'reporting'reportRunCreated'
  GHC.Types.Int ->
  -- | 'reporting'reportRunId'
  Data.Text.Internal.Text ->
  -- | 'reporting'reportRunLivemode'
  GHC.Types.Bool ->
  -- | 'reporting'reportRunParameters'
  FinancialReportingFinanceReportRunRunParameters ->
  -- | 'reporting'reportRunReportType'
  Data.Text.Internal.Text ->
  -- | 'reporting'reportRunStatus'
  Data.Text.Internal.Text ->
  Reporting'reportRun
mkReporting'reportRun :: Int
-> Text
-> Bool
-> FinancialReportingFinanceReportRunRunParameters
-> Text
-> Text
-> Reporting'reportRun
mkReporting'reportRun Int
reporting'reportRunCreated Text
reporting'reportRunId Bool
reporting'reportRunLivemode FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters Text
reporting'reportRunReportType Text
reporting'reportRunStatus =
  Reporting'reportRun :: Int
-> Maybe Text
-> Text
-> Bool
-> FinancialReportingFinanceReportRunRunParameters
-> Text
-> Maybe Reporting'reportRunResult'
-> Text
-> Maybe Int
-> Reporting'reportRun
Reporting'reportRun
    { reporting'reportRunCreated :: Int
reporting'reportRunCreated = Int
reporting'reportRunCreated,
      reporting'reportRunError :: Maybe Text
reporting'reportRunError = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunId :: Text
reporting'reportRunId = Text
reporting'reportRunId,
      reporting'reportRunLivemode :: Bool
reporting'reportRunLivemode = Bool
reporting'reportRunLivemode,
      reporting'reportRunParameters :: FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters = FinancialReportingFinanceReportRunRunParameters
reporting'reportRunParameters,
      reporting'reportRunReportType :: Text
reporting'reportRunReportType = Text
reporting'reportRunReportType,
      reporting'reportRunResult :: Maybe Reporting'reportRunResult'
reporting'reportRunResult = Maybe Reporting'reportRunResult'
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunStatus :: Text
reporting'reportRunStatus = Text
reporting'reportRunStatus,
      reporting'reportRunSucceededAt :: Maybe Int
reporting'reportRunSucceededAt = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the object schema located at @components.schemas.reporting.report_run.properties.result.anyOf@ in the specification.
--
-- The file object representing the result of the report run (populated when
--  \\\`status=succeeded\\\`).
data Reporting'reportRunResult' = Reporting'reportRunResult'
  { -- | created: Time at which the object was created. Measured in seconds since the Unix epoch.
    Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Created :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | expires_at: The time at which the file expires and is no longer available in epoch seconds.
    Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'ExpiresAt :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | filename: A filename for the file, suitable for saving to a filesystem.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Filename :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | id: Unique identifier for the object.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Id :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | links: A list of [file links](https:\/\/stripe.com\/docs\/api\#file_links) that point at this file.
    Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Links'
reporting'reportRunResult'Links :: (GHC.Maybe.Maybe Reporting'reportRunResult'Links'),
    -- | object: String representing the object\'s type. Objects of the same type share the same value.
    Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Object'
reporting'reportRunResult'Object :: (GHC.Maybe.Maybe Reporting'reportRunResult'Object'),
    -- | purpose: The [purpose](https:\/\/stripe.com\/docs\/file-upload\#uploading-a-file) of the uploaded file.
    Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Purpose'
reporting'reportRunResult'Purpose :: (GHC.Maybe.Maybe Reporting'reportRunResult'Purpose'),
    -- | size: The size in bytes of the file object.
    Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Size :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | title: A user friendly title for the document.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Title :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | type: The type of the file returned (e.g., \`csv\`, \`pdf\`, \`jpg\`, or \`png\`).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Type :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | url: The URL from which the file can be downloaded using your live secret API key.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Url :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int -> Reporting'reportRunResult' -> ShowS
[Reporting'reportRunResult'] -> ShowS
Reporting'reportRunResult' -> String
(Int -> Reporting'reportRunResult' -> ShowS)
-> (Reporting'reportRunResult' -> String)
-> ([Reporting'reportRunResult'] -> ShowS)
-> Show Reporting'reportRunResult'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Reporting'reportRunResult'] -> ShowS
$cshowList :: [Reporting'reportRunResult'] -> ShowS
show :: Reporting'reportRunResult' -> String
$cshow :: Reporting'reportRunResult' -> String
showsPrec :: Int -> Reporting'reportRunResult' -> ShowS
$cshowsPrec :: Int -> Reporting'reportRunResult' -> ShowS
GHC.Show.Show,
      Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool
(Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool)
-> (Reporting'reportRunResult'
    -> Reporting'reportRunResult' -> Bool)
-> Eq Reporting'reportRunResult'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool
$c/= :: Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool
== :: Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool
$c== :: Reporting'reportRunResult' -> Reporting'reportRunResult' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON Reporting'reportRunResult' where
  toJSON :: Reporting'reportRunResult' -> Value
toJSON Reporting'reportRunResult'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"created" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Created Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"expires_at" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'ExpiresAt Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"filename" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Filename Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"id" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Id Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"links" Text -> Maybe Reporting'reportRunResult'Links' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Links'
reporting'reportRunResult'Links Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Maybe Reporting'reportRunResult'Object' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Object'
reporting'reportRunResult'Object Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"purpose" Text -> Maybe Reporting'reportRunResult'Purpose' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Purpose'
reporting'reportRunResult'Purpose Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"size" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Size Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"title" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Title Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"type" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Type Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"url" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Url Reporting'reportRunResult'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: Reporting'reportRunResult' -> Encoding
toEncoding Reporting'reportRunResult'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"created" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Created Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"expires_at" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'ExpiresAt Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"filename" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Filename Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"id" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Id Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"links" Text -> Maybe Reporting'reportRunResult'Links' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Links'
reporting'reportRunResult'Links Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"object" Text -> Maybe Reporting'reportRunResult'Object' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Object'
reporting'reportRunResult'Object Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"purpose" Text -> Maybe Reporting'reportRunResult'Purpose' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'
-> Maybe Reporting'reportRunResult'Purpose'
reporting'reportRunResult'Purpose Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"size" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Int
reporting'reportRunResult'Size Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"title" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Title Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"type" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Type Reporting'reportRunResult'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"url" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult' -> Maybe Text
reporting'reportRunResult'Url Reporting'reportRunResult'
obj)))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON Reporting'reportRunResult' where
  parseJSON :: Value -> Parser Reporting'reportRunResult'
parseJSON = String
-> (Object -> Parser Reporting'reportRunResult')
-> Value
-> Parser Reporting'reportRunResult'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"Reporting'reportRunResult'" (\Object
obj -> (((((((((((Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Text
 -> Maybe Reporting'reportRunResult'Links'
 -> Maybe Reporting'reportRunResult'Object'
 -> Maybe Reporting'reportRunResult'Purpose'
 -> Maybe Int
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Reporting'reportRunResult')
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Reporting'reportRunResult'Links'
      -> Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Reporting'reportRunResult'Links'
-> Maybe Reporting'reportRunResult'Object'
-> Maybe Reporting'reportRunResult'Purpose'
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Reporting'reportRunResult'
Reporting'reportRunResult' Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Reporting'reportRunResult'Links'
   -> Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Reporting'reportRunResult'Links'
      -> Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"created")) Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Reporting'reportRunResult'Links'
   -> Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Reporting'reportRunResult'Links'
      -> Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"expires_at")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Reporting'reportRunResult'Links'
   -> Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Reporting'reportRunResult'Links'
      -> Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"filename")) Parser
  (Maybe Text
   -> Maybe Reporting'reportRunResult'Links'
   -> Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Text)
-> Parser
     (Maybe Reporting'reportRunResult'Links'
      -> Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"id")) Parser
  (Maybe Reporting'reportRunResult'Links'
   -> Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Reporting'reportRunResult'Links')
-> Parser
     (Maybe Reporting'reportRunResult'Object'
      -> Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Reporting'reportRunResult'Links')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"links")) Parser
  (Maybe Reporting'reportRunResult'Object'
   -> Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Reporting'reportRunResult'Object')
-> Parser
     (Maybe Reporting'reportRunResult'Purpose'
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Reporting'reportRunResult'Object')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"object")) Parser
  (Maybe Reporting'reportRunResult'Purpose'
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Reporting'reportRunResult'Purpose')
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Reporting'reportRunResult'Purpose')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"purpose")) Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Reporting'reportRunResult')
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Text -> Maybe Text -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"size")) Parser
  (Maybe Text
   -> Maybe Text -> Maybe Text -> Reporting'reportRunResult')
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"title")) Parser (Maybe Text -> Maybe Text -> Reporting'reportRunResult')
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Reporting'reportRunResult')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"type")) Parser (Maybe Text -> Reporting'reportRunResult')
-> Parser (Maybe Text) -> Parser Reporting'reportRunResult'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"url"))

-- | Create a new 'Reporting'reportRunResult'' with all required fields.
mkReporting'reportRunResult' :: Reporting'reportRunResult'
mkReporting'reportRunResult' :: Reporting'reportRunResult'
mkReporting'reportRunResult' =
  Reporting'reportRunResult' :: Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Reporting'reportRunResult'Links'
-> Maybe Reporting'reportRunResult'Object'
-> Maybe Reporting'reportRunResult'Purpose'
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Reporting'reportRunResult'
Reporting'reportRunResult'
    { reporting'reportRunResult'Created :: Maybe Int
reporting'reportRunResult'Created = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'ExpiresAt :: Maybe Int
reporting'reportRunResult'ExpiresAt = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Filename :: Maybe Text
reporting'reportRunResult'Filename = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Id :: Maybe Text
reporting'reportRunResult'Id = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Links :: Maybe Reporting'reportRunResult'Links'
reporting'reportRunResult'Links = Maybe Reporting'reportRunResult'Links'
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Object :: Maybe Reporting'reportRunResult'Object'
reporting'reportRunResult'Object = Maybe Reporting'reportRunResult'Object'
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Purpose :: Maybe Reporting'reportRunResult'Purpose'
reporting'reportRunResult'Purpose = Maybe Reporting'reportRunResult'Purpose'
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Size :: Maybe Int
reporting'reportRunResult'Size = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Title :: Maybe Text
reporting'reportRunResult'Title = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Type :: Maybe Text
reporting'reportRunResult'Type = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      reporting'reportRunResult'Url :: Maybe Text
reporting'reportRunResult'Url = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the object schema located at @components.schemas.reporting.report_run.properties.result.anyOf.properties.links@ in the specification.
--
-- A list of [file links](https:\/\/stripe.com\/docs\/api\#file_links) that point at this file.
data Reporting'reportRunResult'Links' = Reporting'reportRunResult'Links'
  { -- | data: Details about each object.
    Reporting'reportRunResult'Links' -> [FileLink]
reporting'reportRunResult'Links'Data :: ([FileLink]),
    -- | has_more: True if this list has another page of items after this one that can be fetched.
    Reporting'reportRunResult'Links' -> Bool
reporting'reportRunResult'Links'HasMore :: GHC.Types.Bool,
    -- | url: The URL where this list can be accessed.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    Reporting'reportRunResult'Links' -> Text
reporting'reportRunResult'Links'Url :: Data.Text.Internal.Text
  }
  deriving
    ( Int -> Reporting'reportRunResult'Links' -> ShowS
[Reporting'reportRunResult'Links'] -> ShowS
Reporting'reportRunResult'Links' -> String
(Int -> Reporting'reportRunResult'Links' -> ShowS)
-> (Reporting'reportRunResult'Links' -> String)
-> ([Reporting'reportRunResult'Links'] -> ShowS)
-> Show Reporting'reportRunResult'Links'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Reporting'reportRunResult'Links'] -> ShowS
$cshowList :: [Reporting'reportRunResult'Links'] -> ShowS
show :: Reporting'reportRunResult'Links' -> String
$cshow :: Reporting'reportRunResult'Links' -> String
showsPrec :: Int -> Reporting'reportRunResult'Links' -> ShowS
$cshowsPrec :: Int -> Reporting'reportRunResult'Links' -> ShowS
GHC.Show.Show,
      Reporting'reportRunResult'Links'
-> Reporting'reportRunResult'Links' -> Bool
(Reporting'reportRunResult'Links'
 -> Reporting'reportRunResult'Links' -> Bool)
-> (Reporting'reportRunResult'Links'
    -> Reporting'reportRunResult'Links' -> Bool)
-> Eq Reporting'reportRunResult'Links'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Reporting'reportRunResult'Links'
-> Reporting'reportRunResult'Links' -> Bool
$c/= :: Reporting'reportRunResult'Links'
-> Reporting'reportRunResult'Links' -> Bool
== :: Reporting'reportRunResult'Links'
-> Reporting'reportRunResult'Links' -> Bool
$c== :: Reporting'reportRunResult'Links'
-> Reporting'reportRunResult'Links' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON Reporting'reportRunResult'Links' where
  toJSON :: Reporting'reportRunResult'Links' -> Value
toJSON Reporting'reportRunResult'Links'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"data" Text -> [FileLink] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> [FileLink]
reporting'reportRunResult'Links'Data Reporting'reportRunResult'Links'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"has_more" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> Bool
reporting'reportRunResult'Links'HasMore Reporting'reportRunResult'Links'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"url" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> Text
reporting'reportRunResult'Links'Url Reporting'reportRunResult'Links'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"list" Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: Reporting'reportRunResult'Links' -> Encoding
toEncoding Reporting'reportRunResult'Links'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"data" Text -> [FileLink] -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> [FileLink]
reporting'reportRunResult'Links'Data Reporting'reportRunResult'Links'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"has_more" Text -> Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> Bool
reporting'reportRunResult'Links'HasMore Reporting'reportRunResult'Links'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"url" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Reporting'reportRunResult'Links' -> Text
reporting'reportRunResult'Links'Url Reporting'reportRunResult'Links'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"object" Text -> Value -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"list"))))

instance Data.Aeson.Types.FromJSON.FromJSON Reporting'reportRunResult'Links' where
  parseJSON :: Value -> Parser Reporting'reportRunResult'Links'
parseJSON = String
-> (Object -> Parser Reporting'reportRunResult'Links')
-> Value
-> Parser Reporting'reportRunResult'Links'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"Reporting'reportRunResult'Links'" (\Object
obj -> ((([FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links')
-> Parser
     ([FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure [FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links'
Reporting'reportRunResult'Links' Parser
  ([FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links')
-> Parser [FileLink]
-> Parser (Bool -> Text -> Reporting'reportRunResult'Links')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser [FileLink]
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"data")) Parser (Bool -> Text -> Reporting'reportRunResult'Links')
-> Parser Bool -> Parser (Text -> Reporting'reportRunResult'Links')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"has_more")) Parser (Text -> Reporting'reportRunResult'Links')
-> Parser Text -> Parser Reporting'reportRunResult'Links'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"url"))

-- | Create a new 'Reporting'reportRunResult'Links'' with all required fields.
mkReporting'reportRunResult'Links' ::
  -- | 'reporting'reportRunResult'Links'Data'
  [FileLink] ->
  -- | 'reporting'reportRunResult'Links'HasMore'
  GHC.Types.Bool ->
  -- | 'reporting'reportRunResult'Links'Url'
  Data.Text.Internal.Text ->
  Reporting'reportRunResult'Links'
mkReporting'reportRunResult'Links' :: [FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links'
mkReporting'reportRunResult'Links' [FileLink]
reporting'reportRunResult'Links'Data Bool
reporting'reportRunResult'Links'HasMore Text
reporting'reportRunResult'Links'Url =
  Reporting'reportRunResult'Links' :: [FileLink] -> Bool -> Text -> Reporting'reportRunResult'Links'
Reporting'reportRunResult'Links'
    { reporting'reportRunResult'Links'Data :: [FileLink]
reporting'reportRunResult'Links'Data = [FileLink]
reporting'reportRunResult'Links'Data,
      reporting'reportRunResult'Links'HasMore :: Bool
reporting'reportRunResult'Links'HasMore = Bool
reporting'reportRunResult'Links'HasMore,
      reporting'reportRunResult'Links'Url :: Text
reporting'reportRunResult'Links'Url = Text
reporting'reportRunResult'Links'Url
    }

-- | Defines the enum schema located at @components.schemas.reporting.report_run.properties.result.anyOf.properties.object@ in the specification.
--
-- String representing the object\'s type. Objects of the same type share the same value.
data Reporting'reportRunResult'Object'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    Reporting'reportRunResult'Object'Other Data.Aeson.Types.Internal.Value
  | -- | This constructor can be used to send values to the server which are not present in the specification yet.
    Reporting'reportRunResult'Object'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"file"@
    Reporting'reportRunResult'Object'EnumFile
  deriving (Int -> Reporting'reportRunResult'Object' -> ShowS
[Reporting'reportRunResult'Object'] -> ShowS
Reporting'reportRunResult'Object' -> String
(Int -> Reporting'reportRunResult'Object' -> ShowS)
-> (Reporting'reportRunResult'Object' -> String)
-> ([Reporting'reportRunResult'Object'] -> ShowS)
-> Show Reporting'reportRunResult'Object'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Reporting'reportRunResult'Object'] -> ShowS
$cshowList :: [Reporting'reportRunResult'Object'] -> ShowS
show :: Reporting'reportRunResult'Object' -> String
$cshow :: Reporting'reportRunResult'Object' -> String
showsPrec :: Int -> Reporting'reportRunResult'Object' -> ShowS
$cshowsPrec :: Int -> Reporting'reportRunResult'Object' -> ShowS
GHC.Show.Show, Reporting'reportRunResult'Object'
-> Reporting'reportRunResult'Object' -> Bool
(Reporting'reportRunResult'Object'
 -> Reporting'reportRunResult'Object' -> Bool)
-> (Reporting'reportRunResult'Object'
    -> Reporting'reportRunResult'Object' -> Bool)
-> Eq Reporting'reportRunResult'Object'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Reporting'reportRunResult'Object'
-> Reporting'reportRunResult'Object' -> Bool
$c/= :: Reporting'reportRunResult'Object'
-> Reporting'reportRunResult'Object' -> Bool
== :: Reporting'reportRunResult'Object'
-> Reporting'reportRunResult'Object' -> Bool
$c== :: Reporting'reportRunResult'Object'
-> Reporting'reportRunResult'Object' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON Reporting'reportRunResult'Object' where
  toJSON :: Reporting'reportRunResult'Object' -> Value
toJSON (Reporting'reportRunResult'Object'Other Value
val) = Value
val
  toJSON (Reporting'reportRunResult'Object'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (Reporting'reportRunResult'Object'
Reporting'reportRunResult'Object'EnumFile) = Value
"file"

instance Data.Aeson.Types.FromJSON.FromJSON Reporting'reportRunResult'Object' where
  parseJSON :: Value -> Parser Reporting'reportRunResult'Object'
parseJSON Value
val =
    Reporting'reportRunResult'Object'
-> Parser Reporting'reportRunResult'Object'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"file" -> Reporting'reportRunResult'Object'
Reporting'reportRunResult'Object'EnumFile
            | Bool
GHC.Base.otherwise -> Value -> Reporting'reportRunResult'Object'
Reporting'reportRunResult'Object'Other Value
val
      )

-- | Defines the enum schema located at @components.schemas.reporting.report_run.properties.result.anyOf.properties.purpose@ in the specification.
--
-- The [purpose](https:\/\/stripe.com\/docs\/file-upload\#uploading-a-file) of the uploaded file.
data Reporting'reportRunResult'Purpose'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    Reporting'reportRunResult'Purpose'Other Data.Aeson.Types.Internal.Value
  | -- | This constructor can be used to send values to the server which are not present in the specification yet.
    Reporting'reportRunResult'Purpose'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"account_requirement"@
    Reporting'reportRunResult'Purpose'EnumAccountRequirement
  | -- | Represents the JSON value @"additional_verification"@
    Reporting'reportRunResult'Purpose'EnumAdditionalVerification
  | -- | Represents the JSON value @"business_icon"@
    Reporting'reportRunResult'Purpose'EnumBusinessIcon
  | -- | Represents the JSON value @"business_logo"@
    
  | -- | Represents the JSON value @"customer_signature"@
    Reporting'reportRunResult'Purpose'EnumCustomerSignature
  | -- | Represents the JSON value @"dispute_evidence"@
    Reporting'reportRunResult'Purpose'EnumDisputeEvidence
  | -- | Represents the JSON value @"document_provider_identity_document"@
    Reporting'reportRunResult'Purpose'EnumDocumentProviderIdentityDocument
  | -- | Represents the JSON value @"finance_report_run"@
    Reporting'reportRunResult'Purpose'EnumFinanceReportRun
  | -- | Represents the JSON value @"identity_document"@
    Reporting'reportRunResult'Purpose'EnumIdentityDocument
  | -- | Represents the JSON value @"identity_document_downloadable"@
    Reporting'reportRunResult'Purpose'EnumIdentityDocumentDownloadable
  | -- | Represents the JSON value @"pci_document"@
    Reporting'reportRunResult'Purpose'EnumPciDocument
  | -- | Represents the JSON value @"selfie"@
    Reporting'reportRunResult'Purpose'EnumSelfie
  | -- | Represents the JSON value @"sigma_scheduled_query"@
    Reporting'reportRunResult'Purpose'EnumSigmaScheduledQuery
  | -- | Represents the JSON value @"tax_document_user_upload"@
    Reporting'reportRunResult'Purpose'EnumTaxDocumentUserUpload
  deriving (Int -> Reporting'reportRunResult'Purpose' -> ShowS
[Reporting'reportRunResult'Purpose'] -> ShowS
Reporting'reportRunResult'Purpose' -> String
(Int -> Reporting'reportRunResult'Purpose' -> ShowS)
-> (Reporting'reportRunResult'Purpose' -> String)
-> ([Reporting'reportRunResult'Purpose'] -> ShowS)
-> Show Reporting'reportRunResult'Purpose'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Reporting'reportRunResult'Purpose'] -> ShowS
$cshowList :: [Reporting'reportRunResult'Purpose'] -> ShowS
show :: Reporting'reportRunResult'Purpose' -> String
$cshow :: Reporting'reportRunResult'Purpose' -> String
showsPrec :: Int -> Reporting'reportRunResult'Purpose' -> ShowS
$cshowsPrec :: Int -> Reporting'reportRunResult'Purpose' -> ShowS
GHC.Show.Show, Reporting'reportRunResult'Purpose'
-> Reporting'reportRunResult'Purpose' -> Bool
(Reporting'reportRunResult'Purpose'
 -> Reporting'reportRunResult'Purpose' -> Bool)
-> (Reporting'reportRunResult'Purpose'
    -> Reporting'reportRunResult'Purpose' -> Bool)
-> Eq Reporting'reportRunResult'Purpose'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Reporting'reportRunResult'Purpose'
-> Reporting'reportRunResult'Purpose' -> Bool
$c/= :: Reporting'reportRunResult'Purpose'
-> Reporting'reportRunResult'Purpose' -> Bool
== :: Reporting'reportRunResult'Purpose'
-> Reporting'reportRunResult'Purpose' -> Bool
$c== :: Reporting'reportRunResult'Purpose'
-> Reporting'reportRunResult'Purpose' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON Reporting'reportRunResult'Purpose' where
  toJSON :: Reporting'reportRunResult'Purpose' -> Value
toJSON (Reporting'reportRunResult'Purpose'Other Value
val) = Value
val
  toJSON (Reporting'reportRunResult'Purpose'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumAccountRequirement) = Value
"account_requirement"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumAdditionalVerification) = Value
"additional_verification"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumBusinessIcon) = Value
"business_icon"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumBusinessLogo) = Value
"business_logo"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumCustomerSignature) = Value
"customer_signature"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumDisputeEvidence) = Value
"dispute_evidence"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumDocumentProviderIdentityDocument) = Value
"document_provider_identity_document"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumFinanceReportRun) = Value
"finance_report_run"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumIdentityDocument) = Value
"identity_document"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumIdentityDocumentDownloadable) = Value
"identity_document_downloadable"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumPciDocument) = Value
"pci_document"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumSelfie) = Value
"selfie"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumSigmaScheduledQuery) = Value
"sigma_scheduled_query"
  toJSON (Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumTaxDocumentUserUpload) = Value
"tax_document_user_upload"

instance Data.Aeson.Types.FromJSON.FromJSON Reporting'reportRunResult'Purpose' where
  parseJSON :: Value -> Parser Reporting'reportRunResult'Purpose'
parseJSON Value
val =
    Reporting'reportRunResult'Purpose'
-> Parser Reporting'reportRunResult'Purpose'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"account_requirement" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumAccountRequirement
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"additional_verification" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumAdditionalVerification
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"business_icon" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumBusinessIcon
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"business_logo" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumBusinessLogo
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"customer_signature" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumCustomerSignature
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"dispute_evidence" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumDisputeEvidence
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"document_provider_identity_document" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumDocumentProviderIdentityDocument
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"finance_report_run" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumFinanceReportRun
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"identity_document" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumIdentityDocument
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"identity_document_downloadable" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumIdentityDocumentDownloadable
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"pci_document" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumPciDocument
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"selfie" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumSelfie
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"sigma_scheduled_query" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumSigmaScheduledQuery
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"tax_document_user_upload" -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'EnumTaxDocumentUserUpload
            | Bool
GHC.Base.otherwise -> Value -> Reporting'reportRunResult'Purpose'
Reporting'reportRunResult'Purpose'Other Value
val
      )