module Network.Google.YouTube.Types.Sum where
import Network.Google.Prelude
data ContentRatingCceRating
= CCEM12
| CCEM16
| CCEM18
| CCEM4
| CCEM6
| CceUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCceRating
instance FromText ContentRatingCceRating where
fromText = \case
"cceM12" -> Just CCEM12
"cceM16" -> Just CCEM16
"cceM18" -> Just CCEM18
"cceM4" -> Just CCEM4
"cceM6" -> Just CCEM6
"cceUnrated" -> Just CceUnrated
_ -> Nothing
instance ToText ContentRatingCceRating where
toText = \case
CCEM12 -> "cceM12"
CCEM16 -> "cceM16"
CCEM18 -> "cceM18"
CCEM4 -> "cceM4"
CCEM6 -> "cceM6"
CceUnrated -> "cceUnrated"
instance FromJSON ContentRatingCceRating where
parseJSON = parseJSONText "ContentRatingCceRating"
instance ToJSON ContentRatingCceRating where
toJSON = toJSONText
data ContentRatingChfilmRating
= CHFILM0
| CHFILM12
| CHFILM16
| CHFILM18
| CHFILM6
| ChfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingChfilmRating
instance FromText ContentRatingChfilmRating where
fromText = \case
"chfilm0" -> Just CHFILM0
"chfilm12" -> Just CHFILM12
"chfilm16" -> Just CHFILM16
"chfilm18" -> Just CHFILM18
"chfilm6" -> Just CHFILM6
"chfilmUnrated" -> Just ChfilmUnrated
_ -> Nothing
instance ToText ContentRatingChfilmRating where
toText = \case
CHFILM0 -> "chfilm0"
CHFILM12 -> "chfilm12"
CHFILM16 -> "chfilm16"
CHFILM18 -> "chfilm18"
CHFILM6 -> "chfilm6"
ChfilmUnrated -> "chfilmUnrated"
instance FromJSON ContentRatingChfilmRating where
parseJSON = parseJSONText "ContentRatingChfilmRating"
instance ToJSON ContentRatingChfilmRating where
toJSON = toJSONText
data ContentRatingMccaaRating
= MCCAA12
| Mccaa12a
| MCCAA14
| MCCAA15
| MCCAA16
| MCCAA18
| MccaaPg
| MccaaU
| MccaaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMccaaRating
instance FromText ContentRatingMccaaRating where
fromText = \case
"mccaa12" -> Just MCCAA12
"mccaa12a" -> Just Mccaa12a
"mccaa14" -> Just MCCAA14
"mccaa15" -> Just MCCAA15
"mccaa16" -> Just MCCAA16
"mccaa18" -> Just MCCAA18
"mccaaPg" -> Just MccaaPg
"mccaaU" -> Just MccaaU
"mccaaUnrated" -> Just MccaaUnrated
_ -> Nothing
instance ToText ContentRatingMccaaRating where
toText = \case
MCCAA12 -> "mccaa12"
Mccaa12a -> "mccaa12a"
MCCAA14 -> "mccaa14"
MCCAA15 -> "mccaa15"
MCCAA16 -> "mccaa16"
MCCAA18 -> "mccaa18"
MccaaPg -> "mccaaPg"
MccaaU -> "mccaaU"
MccaaUnrated -> "mccaaUnrated"
instance FromJSON ContentRatingMccaaRating where
parseJSON = parseJSONText "ContentRatingMccaaRating"
instance ToJSON ContentRatingMccaaRating where
toJSON = toJSONText
data VideosListChart
= MostPopular
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideosListChart
instance FromText VideosListChart where
fromText = \case
"mostPopular" -> Just MostPopular
_ -> Nothing
instance ToText VideosListChart where
toText = \case
MostPopular -> "mostPopular"
instance FromJSON VideosListChart where
parseJSON = parseJSONText "VideosListChart"
instance ToJSON VideosListChart where
toJSON = toJSONText
data ContentRatingMpaaRating
= MpaaG
| MPAANC17
| MpaaPg
| MPAAPG13
| MpaaR
| MpaaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMpaaRating
instance FromText ContentRatingMpaaRating where
fromText = \case
"mpaaG" -> Just MpaaG
"mpaaNc17" -> Just MPAANC17
"mpaaPg" -> Just MpaaPg
"mpaaPg13" -> Just MPAAPG13
"mpaaR" -> Just MpaaR
"mpaaUnrated" -> Just MpaaUnrated
_ -> Nothing
instance ToText ContentRatingMpaaRating where
toText = \case
MpaaG -> "mpaaG"
MPAANC17 -> "mpaaNc17"
MpaaPg -> "mpaaPg"
MPAAPG13 -> "mpaaPg13"
MpaaR -> "mpaaR"
MpaaUnrated -> "mpaaUnrated"
instance FromJSON ContentRatingMpaaRating where
parseJSON = parseJSONText "ContentRatingMpaaRating"
instance ToJSON ContentRatingMpaaRating where
toJSON = toJSONText
data CaptionSnippetTrackKind
= Asr
| Forced
| Standard
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CaptionSnippetTrackKind
instance FromText CaptionSnippetTrackKind where
fromText = \case
"ASR" -> Just Asr
"forced" -> Just Forced
"standard" -> Just Standard
_ -> Nothing
instance ToText CaptionSnippetTrackKind where
toText = \case
Asr -> "ASR"
Forced -> "forced"
Standard -> "standard"
instance FromJSON CaptionSnippetTrackKind where
parseJSON = parseJSONText "CaptionSnippetTrackKind"
instance ToJSON CaptionSnippetTrackKind where
toJSON = toJSONText
data VideoSnippetLiveBroadcastContent
= Live
| None
| Upcoming
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoSnippetLiveBroadcastContent
instance FromText VideoSnippetLiveBroadcastContent where
fromText = \case
"live" -> Just Live
"none" -> Just None
"upcoming" -> Just Upcoming
_ -> Nothing
instance ToText VideoSnippetLiveBroadcastContent where
toText = \case
Live -> "live"
None -> "none"
Upcoming -> "upcoming"
instance FromJSON VideoSnippetLiveBroadcastContent where
parseJSON = parseJSONText "VideoSnippetLiveBroadcastContent"
instance ToJSON VideoSnippetLiveBroadcastContent where
toJSON = toJSONText
data ChannelConversionPingContext
= Cview
| Subscribe
| Unsubscribe
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ChannelConversionPingContext
instance FromText ChannelConversionPingContext where
fromText = \case
"cview" -> Just Cview
"subscribe" -> Just Subscribe
"unsubscribe" -> Just Unsubscribe
_ -> Nothing
instance ToText ChannelConversionPingContext where
toText = \case
Cview -> "cview"
Subscribe -> "subscribe"
Unsubscribe -> "unsubscribe"
instance FromJSON ChannelConversionPingContext where
parseJSON = parseJSONText "ChannelConversionPingContext"
instance ToJSON ChannelConversionPingContext where
toJSON = toJSONText
data ContentRatingRcnofRating
= RcnofI
| RcnofIi
| RcnofIii
| RcnofIv
| RcnofUnrated
| RcnofV
| RcnofVi
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingRcnofRating
instance FromText ContentRatingRcnofRating where
fromText = \case
"rcnofI" -> Just RcnofI
"rcnofIi" -> Just RcnofIi
"rcnofIii" -> Just RcnofIii
"rcnofIv" -> Just RcnofIv
"rcnofUnrated" -> Just RcnofUnrated
"rcnofV" -> Just RcnofV
"rcnofVi" -> Just RcnofVi
_ -> Nothing
instance ToText ContentRatingRcnofRating where
toText = \case
RcnofI -> "rcnofI"
RcnofIi -> "rcnofIi"
RcnofIii -> "rcnofIii"
RcnofIv -> "rcnofIv"
RcnofUnrated -> "rcnofUnrated"
RcnofV -> "rcnofV"
RcnofVi -> "rcnofVi"
instance FromJSON ContentRatingRcnofRating where
parseJSON = parseJSONText "ContentRatingRcnofRating"
instance ToJSON ContentRatingRcnofRating where
toJSON = toJSONText
data VideoStatusPrivacyStatus
= Private
| Public
| UnListed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoStatusPrivacyStatus
instance FromText VideoStatusPrivacyStatus where
fromText = \case
"private" -> Just Private
"public" -> Just Public
"unlisted" -> Just UnListed
_ -> Nothing
instance ToText VideoStatusPrivacyStatus where
toText = \case
Private -> "private"
Public -> "public"
UnListed -> "unlisted"
instance FromJSON VideoStatusPrivacyStatus where
parseJSON = parseJSONText "VideoStatusPrivacyStatus"
instance ToJSON VideoStatusPrivacyStatus where
toJSON = toJSONText
data LiveBroadcastStatusLifeCycleStatus
= LBSLCSAbandoned
| LBSLCSComplete
| LBSLCSCompleteStarting
| LBSLCSCreated
| LBSLCSLive
| LBSLCSLiveStarting
| LBSLCSReady
| LBSLCSReclaimed
| LBSLCSRevoked
| LBSLCSTestStarting
| LBSLCSTesting
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastStatusLifeCycleStatus
instance FromText LiveBroadcastStatusLifeCycleStatus where
fromText = \case
"abandoned" -> Just LBSLCSAbandoned
"complete" -> Just LBSLCSComplete
"completeStarting" -> Just LBSLCSCompleteStarting
"created" -> Just LBSLCSCreated
"live" -> Just LBSLCSLive
"liveStarting" -> Just LBSLCSLiveStarting
"ready" -> Just LBSLCSReady
"reclaimed" -> Just LBSLCSReclaimed
"revoked" -> Just LBSLCSRevoked
"testStarting" -> Just LBSLCSTestStarting
"testing" -> Just LBSLCSTesting
_ -> Nothing
instance ToText LiveBroadcastStatusLifeCycleStatus where
toText = \case
LBSLCSAbandoned -> "abandoned"
LBSLCSComplete -> "complete"
LBSLCSCompleteStarting -> "completeStarting"
LBSLCSCreated -> "created"
LBSLCSLive -> "live"
LBSLCSLiveStarting -> "liveStarting"
LBSLCSReady -> "ready"
LBSLCSReclaimed -> "reclaimed"
LBSLCSRevoked -> "revoked"
LBSLCSTestStarting -> "testStarting"
LBSLCSTesting -> "testing"
instance FromJSON LiveBroadcastStatusLifeCycleStatus where
parseJSON = parseJSONText "LiveBroadcastStatusLifeCycleStatus"
instance ToJSON LiveBroadcastStatusLifeCycleStatus where
toJSON = toJSONText
data CaptionSnippetFailureReason
= ProcessingFailed
| UnknownFormat
| UnsupportedFormat
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CaptionSnippetFailureReason
instance FromText CaptionSnippetFailureReason where
fromText = \case
"processingFailed" -> Just ProcessingFailed
"unknownFormat" -> Just UnknownFormat
"unsupportedFormat" -> Just UnsupportedFormat
_ -> Nothing
instance ToText CaptionSnippetFailureReason where
toText = \case
ProcessingFailed -> "processingFailed"
UnknownFormat -> "unknownFormat"
UnsupportedFormat -> "unsupportedFormat"
instance FromJSON CaptionSnippetFailureReason where
parseJSON = parseJSONText "CaptionSnippetFailureReason"
instance ToJSON CaptionSnippetFailureReason where
toJSON = toJSONText
data VideoProcessingDetailsProcessingFailureReason
= Other
| StreamingFailed
| TranscodeFailed
| UploadFailed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoProcessingDetailsProcessingFailureReason
instance FromText VideoProcessingDetailsProcessingFailureReason where
fromText = \case
"other" -> Just Other
"streamingFailed" -> Just StreamingFailed
"transcodeFailed" -> Just TranscodeFailed
"uploadFailed" -> Just UploadFailed
_ -> Nothing
instance ToText VideoProcessingDetailsProcessingFailureReason where
toText = \case
Other -> "other"
StreamingFailed -> "streamingFailed"
TranscodeFailed -> "transcodeFailed"
UploadFailed -> "uploadFailed"
instance FromJSON VideoProcessingDetailsProcessingFailureReason where
parseJSON = parseJSONText "VideoProcessingDetailsProcessingFailureReason"
instance ToJSON VideoProcessingDetailsProcessingFailureReason where
toJSON = toJSONText
data InvideoPositionType
= Corner
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable InvideoPositionType
instance FromText InvideoPositionType where
fromText = \case
"corner" -> Just Corner
_ -> Nothing
instance ToText InvideoPositionType where
toText = \case
Corner -> "corner"
instance FromJSON InvideoPositionType where
parseJSON = parseJSONText "InvideoPositionType"
instance ToJSON InvideoPositionType where
toJSON = toJSONText
data ContentRatingFskRating
= FSK0
| FSK12
| FSK16
| FSK18
| FSK6
| FskUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingFskRating
instance FromText ContentRatingFskRating where
fromText = \case
"fsk0" -> Just FSK0
"fsk12" -> Just FSK12
"fsk16" -> Just FSK16
"fsk18" -> Just FSK18
"fsk6" -> Just FSK6
"fskUnrated" -> Just FskUnrated
_ -> Nothing
instance ToText ContentRatingFskRating where
toText = \case
FSK0 -> "fsk0"
FSK12 -> "fsk12"
FSK16 -> "fsk16"
FSK18 -> "fsk18"
FSK6 -> "fsk6"
FskUnrated -> "fskUnrated"
instance FromJSON ContentRatingFskRating where
parseJSON = parseJSONText "ContentRatingFskRating"
instance ToJSON ContentRatingFskRating where
toJSON = toJSONText
data ContentRatingMekuRating
= MEKU12
| MEKU16
| MEKU18
| MEKU7
| MekuS
| MekuUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMekuRating
instance FromText ContentRatingMekuRating where
fromText = \case
"meku12" -> Just MEKU12
"meku16" -> Just MEKU16
"meku18" -> Just MEKU18
"meku7" -> Just MEKU7
"mekuS" -> Just MekuS
"mekuUnrated" -> Just MekuUnrated
_ -> Nothing
instance ToText ContentRatingMekuRating where
toText = \case
MEKU12 -> "meku12"
MEKU16 -> "meku16"
MEKU18 -> "meku18"
MEKU7 -> "meku7"
MekuS -> "mekuS"
MekuUnrated -> "mekuUnrated"
instance FromJSON ContentRatingMekuRating where
parseJSON = parseJSONText "ContentRatingMekuRating"
instance ToJSON ContentRatingMekuRating where
toJSON = toJSONText
data VideoContentDetailsDefinition
= HD
| SD
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoContentDetailsDefinition
instance FromText VideoContentDetailsDefinition where
fromText = \case
"hd" -> Just HD
"sd" -> Just SD
_ -> Nothing
instance ToText VideoContentDetailsDefinition where
toText = \case
HD -> "hd"
SD -> "sd"
instance FromJSON VideoContentDetailsDefinition where
parseJSON = parseJSONText "VideoContentDetailsDefinition"
instance ToJSON VideoContentDetailsDefinition where
toJSON = toJSONText
data ContentRatingEefilmRating
= EEFILMK12
| EEFILMK14
| EEFILMK16
| EEFILMK6
| EefilmL
| EEFILMMS12
| EEFILMMS6
| EefilmPere
| EefilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingEefilmRating
instance FromText ContentRatingEefilmRating where
fromText = \case
"eefilmK12" -> Just EEFILMK12
"eefilmK14" -> Just EEFILMK14
"eefilmK16" -> Just EEFILMK16
"eefilmK6" -> Just EEFILMK6
"eefilmL" -> Just EefilmL
"eefilmMs12" -> Just EEFILMMS12
"eefilmMs6" -> Just EEFILMMS6
"eefilmPere" -> Just EefilmPere
"eefilmUnrated" -> Just EefilmUnrated
_ -> Nothing
instance ToText ContentRatingEefilmRating where
toText = \case
EEFILMK12 -> "eefilmK12"
EEFILMK14 -> "eefilmK14"
EEFILMK16 -> "eefilmK16"
EEFILMK6 -> "eefilmK6"
EefilmL -> "eefilmL"
EEFILMMS12 -> "eefilmMs12"
EEFILMMS6 -> "eefilmMs6"
EefilmPere -> "eefilmPere"
EefilmUnrated -> "eefilmUnrated"
instance FromJSON ContentRatingEefilmRating where
parseJSON = parseJSONText "ContentRatingEefilmRating"
instance ToJSON ContentRatingEefilmRating where
toJSON = toJSONText
data LiveBroadcastStatusPrivacyStatus
= LBSPSPrivate
| LBSPSPublic
| LBSPSUnListed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastStatusPrivacyStatus
instance FromText LiveBroadcastStatusPrivacyStatus where
fromText = \case
"private" -> Just LBSPSPrivate
"public" -> Just LBSPSPublic
"unlisted" -> Just LBSPSUnListed
_ -> Nothing
instance ToText LiveBroadcastStatusPrivacyStatus where
toText = \case
LBSPSPrivate -> "private"
LBSPSPublic -> "public"
LBSPSUnListed -> "unlisted"
instance FromJSON LiveBroadcastStatusPrivacyStatus where
parseJSON = parseJSONText "LiveBroadcastStatusPrivacyStatus"
instance ToJSON LiveBroadcastStatusPrivacyStatus where
toJSON = toJSONText
data CaptionsDownloadTfmt
= Sbv
| Scc
| Srt
| Ttml
| Vtt
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CaptionsDownloadTfmt
instance FromText CaptionsDownloadTfmt where
fromText = \case
"sbv" -> Just Sbv
"scc" -> Just Scc
"srt" -> Just Srt
"ttml" -> Just Ttml
"vtt" -> Just Vtt
_ -> Nothing
instance ToText CaptionsDownloadTfmt where
toText = \case
Sbv -> "sbv"
Scc -> "scc"
Srt -> "srt"
Ttml -> "ttml"
Vtt -> "vtt"
instance FromJSON CaptionsDownloadTfmt where
parseJSON = parseJSONText "CaptionsDownloadTfmt"
instance ToJSON CaptionsDownloadTfmt where
toJSON = toJSONText
data PromotedItemIdType
= PIITRecentUpload
| PIITVideo
| PIITWebsite
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable PromotedItemIdType
instance FromText PromotedItemIdType where
fromText = \case
"recentUpload" -> Just PIITRecentUpload
"video" -> Just PIITVideo
"website" -> Just PIITWebsite
_ -> Nothing
instance ToText PromotedItemIdType where
toText = \case
PIITRecentUpload -> "recentUpload"
PIITVideo -> "video"
PIITWebsite -> "website"
instance FromJSON PromotedItemIdType where
parseJSON = parseJSONText "PromotedItemIdType"
instance ToJSON PromotedItemIdType where
toJSON = toJSONText
data ContentRatingPefilmRating
= PEFILM14
| PEFILM18
| PefilmPg
| PefilmPt
| PefilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingPefilmRating
instance FromText ContentRatingPefilmRating where
fromText = \case
"pefilm14" -> Just PEFILM14
"pefilm18" -> Just PEFILM18
"pefilmPg" -> Just PefilmPg
"pefilmPt" -> Just PefilmPt
"pefilmUnrated" -> Just PefilmUnrated
_ -> Nothing
instance ToText ContentRatingPefilmRating where
toText = \case
PEFILM14 -> "pefilm14"
PEFILM18 -> "pefilm18"
PefilmPg -> "pefilmPg"
PefilmPt -> "pefilmPt"
PefilmUnrated -> "pefilmUnrated"
instance FromJSON ContentRatingPefilmRating where
parseJSON = parseJSONText "ContentRatingPefilmRating"
instance ToJSON ContentRatingPefilmRating where
toJSON = toJSONText
data SearchResultSnippetLiveBroadcastContent
= SRSLBCLive
| SRSLBCNone
| SRSLBCUpcoming
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchResultSnippetLiveBroadcastContent
instance FromText SearchResultSnippetLiveBroadcastContent where
fromText = \case
"live" -> Just SRSLBCLive
"none" -> Just SRSLBCNone
"upcoming" -> Just SRSLBCUpcoming
_ -> Nothing
instance ToText SearchResultSnippetLiveBroadcastContent where
toText = \case
SRSLBCLive -> "live"
SRSLBCNone -> "none"
SRSLBCUpcoming -> "upcoming"
instance FromJSON SearchResultSnippetLiveBroadcastContent where
parseJSON = parseJSONText "SearchResultSnippetLiveBroadcastContent"
instance ToJSON SearchResultSnippetLiveBroadcastContent where
toJSON = toJSONText
data ContentRatingAnatelRating
= AnatelA
| AnatelF
| AnatelI
| ANATELI10
| ANATELI12
| ANATELI7
| AnatelR
| AnatelUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingAnatelRating
instance FromText ContentRatingAnatelRating where
fromText = \case
"anatelA" -> Just AnatelA
"anatelF" -> Just AnatelF
"anatelI" -> Just AnatelI
"anatelI10" -> Just ANATELI10
"anatelI12" -> Just ANATELI12
"anatelI7" -> Just ANATELI7
"anatelR" -> Just AnatelR
"anatelUnrated" -> Just AnatelUnrated
_ -> Nothing
instance ToText ContentRatingAnatelRating where
toText = \case
AnatelA -> "anatelA"
AnatelF -> "anatelF"
AnatelI -> "anatelI"
ANATELI10 -> "anatelI10"
ANATELI12 -> "anatelI12"
ANATELI7 -> "anatelI7"
AnatelR -> "anatelR"
AnatelUnrated -> "anatelUnrated"
instance FromJSON ContentRatingAnatelRating where
parseJSON = parseJSONText "ContentRatingAnatelRating"
instance ToJSON ContentRatingAnatelRating where
toJSON = toJSONText
data SearchListOrder
= Date
| Rating
| Relevance
| Title
| VideoCount
| ViewCount
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListOrder
instance FromText SearchListOrder where
fromText = \case
"date" -> Just Date
"rating" -> Just Rating
"relevance" -> Just Relevance
"title" -> Just Title
"videoCount" -> Just VideoCount
"viewCount" -> Just ViewCount
_ -> Nothing
instance ToText SearchListOrder where
toText = \case
Date -> "date"
Rating -> "rating"
Relevance -> "relevance"
Title -> "title"
VideoCount -> "videoCount"
ViewCount -> "viewCount"
instance FromJSON SearchListOrder where
parseJSON = parseJSONText "SearchListOrder"
instance ToJSON SearchListOrder where
toJSON = toJSONText
data ContentRatingCccRating
= CCC14
| CCC18
| Ccc18s
| Ccc18v
| CCC6
| CccTe
| CccUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCccRating
instance FromText ContentRatingCccRating where
fromText = \case
"ccc14" -> Just CCC14
"ccc18" -> Just CCC18
"ccc18s" -> Just Ccc18s
"ccc18v" -> Just Ccc18v
"ccc6" -> Just CCC6
"cccTe" -> Just CccTe
"cccUnrated" -> Just CccUnrated
_ -> Nothing
instance ToText ContentRatingCccRating where
toText = \case
CCC14 -> "ccc14"
CCC18 -> "ccc18"
Ccc18s -> "ccc18s"
Ccc18v -> "ccc18v"
CCC6 -> "ccc6"
CccTe -> "cccTe"
CccUnrated -> "cccUnrated"
instance FromJSON ContentRatingCccRating where
parseJSON = parseJSONText "ContentRatingCccRating"
instance ToJSON ContentRatingCccRating where
toJSON = toJSONText
data CaptionSnippetAudioTrackType
= Commentary
| Descriptive
| Primary
| Unknown
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CaptionSnippetAudioTrackType
instance FromText CaptionSnippetAudioTrackType where
fromText = \case
"commentary" -> Just Commentary
"descriptive" -> Just Descriptive
"primary" -> Just Primary
"unknown" -> Just Unknown
_ -> Nothing
instance ToText CaptionSnippetAudioTrackType where
toText = \case
Commentary -> "commentary"
Descriptive -> "descriptive"
Primary -> "primary"
Unknown -> "unknown"
instance FromJSON CaptionSnippetAudioTrackType where
parseJSON = parseJSONText "CaptionSnippetAudioTrackType"
instance ToJSON CaptionSnippetAudioTrackType where
toJSON = toJSONText
data ChannelStatusPrivacyStatus
= CSPSPrivate
| CSPSPublic
| CSPSUnListed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ChannelStatusPrivacyStatus
instance FromText ChannelStatusPrivacyStatus where
fromText = \case
"private" -> Just CSPSPrivate
"public" -> Just CSPSPublic
"unlisted" -> Just CSPSUnListed
_ -> Nothing
instance ToText ChannelStatusPrivacyStatus where
toText = \case
CSPSPrivate -> "private"
CSPSPublic -> "public"
CSPSUnListed -> "unlisted"
instance FromJSON ChannelStatusPrivacyStatus where
parseJSON = parseJSONText "ChannelStatusPrivacyStatus"
instance ToJSON ChannelStatusPrivacyStatus where
toJSON = toJSONText
data VideoSuggestionsEditorSuggestionsItem
= AudioQuietAudioSwap
| VideoAutoLevels
| VideoCrop
| VideoStabilize
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoSuggestionsEditorSuggestionsItem
instance FromText VideoSuggestionsEditorSuggestionsItem where
fromText = \case
"audioQuietAudioSwap" -> Just AudioQuietAudioSwap
"videoAutoLevels" -> Just VideoAutoLevels
"videoCrop" -> Just VideoCrop
"videoStabilize" -> Just VideoStabilize
_ -> Nothing
instance ToText VideoSuggestionsEditorSuggestionsItem where
toText = \case
AudioQuietAudioSwap -> "audioQuietAudioSwap"
VideoAutoLevels -> "videoAutoLevels"
VideoCrop -> "videoCrop"
VideoStabilize -> "videoStabilize"
instance FromJSON VideoSuggestionsEditorSuggestionsItem where
parseJSON = parseJSONText "VideoSuggestionsEditorSuggestionsItem"
instance ToJSON VideoSuggestionsEditorSuggestionsItem where
toJSON = toJSONText
data ContentRatingCatvfrRating
= Catvfr13plus
| Catvfr16plus
| Catvfr18plus
| Catvfr8plus
| CatvfrG
| CatvfrUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCatvfrRating
instance FromText ContentRatingCatvfrRating where
fromText = \case
"catvfr13plus" -> Just Catvfr13plus
"catvfr16plus" -> Just Catvfr16plus
"catvfr18plus" -> Just Catvfr18plus
"catvfr8plus" -> Just Catvfr8plus
"catvfrG" -> Just CatvfrG
"catvfrUnrated" -> Just CatvfrUnrated
_ -> Nothing
instance ToText ContentRatingCatvfrRating where
toText = \case
Catvfr13plus -> "catvfr13plus"
Catvfr16plus -> "catvfr16plus"
Catvfr18plus -> "catvfr18plus"
Catvfr8plus -> "catvfr8plus"
CatvfrG -> "catvfrG"
CatvfrUnrated -> "catvfrUnrated"
instance FromJSON ContentRatingCatvfrRating where
parseJSON = parseJSONText "ContentRatingCatvfrRating"
instance ToJSON ContentRatingCatvfrRating where
toJSON = toJSONText
data ContentRatingCnaRating
= CNA12
| CNA15
| CNA18
| Cna18plus
| CnaAp
| CnaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCnaRating
instance FromText ContentRatingCnaRating where
fromText = \case
"cna12" -> Just CNA12
"cna15" -> Just CNA15
"cna18" -> Just CNA18
"cna18plus" -> Just Cna18plus
"cnaAp" -> Just CnaAp
"cnaUnrated" -> Just CnaUnrated
_ -> Nothing
instance ToText ContentRatingCnaRating where
toText = \case
CNA12 -> "cna12"
CNA15 -> "cna15"
CNA18 -> "cna18"
Cna18plus -> "cna18plus"
CnaAp -> "cnaAp"
CnaUnrated -> "cnaUnrated"
instance FromJSON ContentRatingCnaRating where
parseJSON = parseJSONText "ContentRatingCnaRating"
instance ToJSON ContentRatingCnaRating where
toJSON = toJSONText
data ContentRatingChvrsRating
= Chvrs14a
| Chvrs18a
| ChvrsE
| ChvrsG
| ChvrsPg
| ChvrsR
| ChvrsUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingChvrsRating
instance FromText ContentRatingChvrsRating where
fromText = \case
"chvrs14a" -> Just Chvrs14a
"chvrs18a" -> Just Chvrs18a
"chvrsE" -> Just ChvrsE
"chvrsG" -> Just ChvrsG
"chvrsPg" -> Just ChvrsPg
"chvrsR" -> Just ChvrsR
"chvrsUnrated" -> Just ChvrsUnrated
_ -> Nothing
instance ToText ContentRatingChvrsRating where
toText = \case
Chvrs14a -> "chvrs14a"
Chvrs18a -> "chvrs18a"
ChvrsE -> "chvrsE"
ChvrsG -> "chvrsG"
ChvrsPg -> "chvrsPg"
ChvrsR -> "chvrsR"
ChvrsUnrated -> "chvrsUnrated"
instance FromJSON ContentRatingChvrsRating where
parseJSON = parseJSONText "ContentRatingChvrsRating"
instance ToJSON ContentRatingChvrsRating where
toJSON = toJSONText
data ContentRatingIncaaRating
= IncaaAtp
| IncaaC
| INCAASAM13
| INCAASAM16
| INCAASAM18
| IncaaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingIncaaRating
instance FromText ContentRatingIncaaRating where
fromText = \case
"incaaAtp" -> Just IncaaAtp
"incaaC" -> Just IncaaC
"incaaSam13" -> Just INCAASAM13
"incaaSam16" -> Just INCAASAM16
"incaaSam18" -> Just INCAASAM18
"incaaUnrated" -> Just IncaaUnrated
_ -> Nothing
instance ToText ContentRatingIncaaRating where
toText = \case
IncaaAtp -> "incaaAtp"
IncaaC -> "incaaC"
INCAASAM13 -> "incaaSam13"
INCAASAM16 -> "incaaSam16"
INCAASAM18 -> "incaaSam18"
IncaaUnrated -> "incaaUnrated"
instance FromJSON ContentRatingIncaaRating where
parseJSON = parseJSONText "ContentRatingIncaaRating"
instance ToJSON ContentRatingIncaaRating where
toJSON = toJSONText
data ContentRatingSmsaRating
= SMSA11
| SMSA15
| SMSA7
| SmsaA
| SmsaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingSmsaRating
instance FromText ContentRatingSmsaRating where
fromText = \case
"smsa11" -> Just SMSA11
"smsa15" -> Just SMSA15
"smsa7" -> Just SMSA7
"smsaA" -> Just SmsaA
"smsaUnrated" -> Just SmsaUnrated
_ -> Nothing
instance ToText ContentRatingSmsaRating where
toText = \case
SMSA11 -> "smsa11"
SMSA15 -> "smsa15"
SMSA7 -> "smsa7"
SmsaA -> "smsaA"
SmsaUnrated -> "smsaUnrated"
instance FromJSON ContentRatingSmsaRating where
parseJSON = parseJSONText "ContentRatingSmsaRating"
instance ToJSON ContentRatingSmsaRating where
toJSON = toJSONText
data ContentRatingCbfcRating
= CbfcA
| CbfcS
| CbfcU
| CbfcUA
| CbfcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCbfcRating
instance FromText ContentRatingCbfcRating where
fromText = \case
"cbfcA" -> Just CbfcA
"cbfcS" -> Just CbfcS
"cbfcU" -> Just CbfcU
"cbfcUA" -> Just CbfcUA
"cbfcUnrated" -> Just CbfcUnrated
_ -> Nothing
instance ToText ContentRatingCbfcRating where
toText = \case
CbfcA -> "cbfcA"
CbfcS -> "cbfcS"
CbfcU -> "cbfcU"
CbfcUA -> "cbfcUA"
CbfcUnrated -> "cbfcUnrated"
instance FromJSON ContentRatingCbfcRating where
parseJSON = parseJSONText "ContentRatingCbfcRating"
instance ToJSON ContentRatingCbfcRating where
toJSON = toJSONText
data ContentRatingKfcbRating
= Kfcb16plus
| KfcbG
| KfcbPg
| KfcbR
| KfcbUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingKfcbRating
instance FromText ContentRatingKfcbRating where
fromText = \case
"kfcb16plus" -> Just Kfcb16plus
"kfcbG" -> Just KfcbG
"kfcbPg" -> Just KfcbPg
"kfcbR" -> Just KfcbR
"kfcbUnrated" -> Just KfcbUnrated
_ -> Nothing
instance ToText ContentRatingKfcbRating where
toText = \case
Kfcb16plus -> "kfcb16plus"
KfcbG -> "kfcbG"
KfcbPg -> "kfcbPg"
KfcbR -> "kfcbR"
KfcbUnrated -> "kfcbUnrated"
instance FromJSON ContentRatingKfcbRating where
parseJSON = parseJSONText "ContentRatingKfcbRating"
instance ToJSON ContentRatingKfcbRating where
toJSON = toJSONText
data LiveStreamConfigurationIssueSeverity
= Error'
| Info
| Warning
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveStreamConfigurationIssueSeverity
instance FromText LiveStreamConfigurationIssueSeverity where
fromText = \case
"error" -> Just Error'
"info" -> Just Info
"warning" -> Just Warning
_ -> Nothing
instance ToText LiveStreamConfigurationIssueSeverity where
toText = \case
Error' -> "error"
Info -> "info"
Warning -> "warning"
instance FromJSON LiveStreamConfigurationIssueSeverity where
parseJSON = parseJSONText "LiveStreamConfigurationIssueSeverity"
instance ToJSON LiveStreamConfigurationIssueSeverity where
toJSON = toJSONText
data SearchListVideoDefinition
= SLVDAny
| SLVDHigh
| SLVDStandard
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoDefinition
instance FromText SearchListVideoDefinition where
fromText = \case
"any" -> Just SLVDAny
"high" -> Just SLVDHigh
"standard" -> Just SLVDStandard
_ -> Nothing
instance ToText SearchListVideoDefinition where
toText = \case
SLVDAny -> "any"
SLVDHigh -> "high"
SLVDStandard -> "standard"
instance FromJSON SearchListVideoDefinition where
parseJSON = parseJSONText "SearchListVideoDefinition"
instance ToJSON SearchListVideoDefinition where
toJSON = toJSONText
data VideoAgeGatingVideoGameRating
= Anyone
| M15Plus
| M16Plus
| M17Plus
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoAgeGatingVideoGameRating
instance FromText VideoAgeGatingVideoGameRating where
fromText = \case
"anyone" -> Just Anyone
"m15Plus" -> Just M15Plus
"m16Plus" -> Just M16Plus
"m17Plus" -> Just M17Plus
_ -> Nothing
instance ToText VideoAgeGatingVideoGameRating where
toText = \case
Anyone -> "anyone"
M15Plus -> "m15Plus"
M16Plus -> "m16Plus"
M17Plus -> "m17Plus"
instance FromJSON VideoAgeGatingVideoGameRating where
parseJSON = parseJSONText "VideoAgeGatingVideoGameRating"
instance ToJSON VideoAgeGatingVideoGameRating where
toJSON = toJSONText
data ContentRatingLsfRating
= LSF13
| LSF17
| LSF21
| LsfA
| LsfBo
| LsfD
| LsfR
| LsfSu
| LsfUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingLsfRating
instance FromText ContentRatingLsfRating where
fromText = \case
"lsf13" -> Just LSF13
"lsf17" -> Just LSF17
"lsf21" -> Just LSF21
"lsfA" -> Just LsfA
"lsfBo" -> Just LsfBo
"lsfD" -> Just LsfD
"lsfR" -> Just LsfR
"lsfSu" -> Just LsfSu
"lsfUnrated" -> Just LsfUnrated
_ -> Nothing
instance ToText ContentRatingLsfRating where
toText = \case
LSF13 -> "lsf13"
LSF17 -> "lsf17"
LSF21 -> "lsf21"
LsfA -> "lsfA"
LsfBo -> "lsfBo"
LsfD -> "lsfD"
LsfR -> "lsfR"
LsfSu -> "lsfSu"
LsfUnrated -> "lsfUnrated"
instance FromJSON ContentRatingLsfRating where
parseJSON = parseJSONText "ContentRatingLsfRating"
instance ToJSON ContentRatingLsfRating where
toJSON = toJSONText
data ContentRatingBfvcRating
= BFVC13
| BFVC15
| BFVC18
| BFVC20
| BfvcB
| BfvcE
| BfvcG
| BfvcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingBfvcRating
instance FromText ContentRatingBfvcRating where
fromText = \case
"bfvc13" -> Just BFVC13
"bfvc15" -> Just BFVC15
"bfvc18" -> Just BFVC18
"bfvc20" -> Just BFVC20
"bfvcB" -> Just BfvcB
"bfvcE" -> Just BfvcE
"bfvcG" -> Just BfvcG
"bfvcUnrated" -> Just BfvcUnrated
_ -> Nothing
instance ToText ContentRatingBfvcRating where
toText = \case
BFVC13 -> "bfvc13"
BFVC15 -> "bfvc15"
BFVC18 -> "bfvc18"
BFVC20 -> "bfvc20"
BfvcB -> "bfvcB"
BfvcE -> "bfvcE"
BfvcG -> "bfvcG"
BfvcUnrated -> "bfvcUnrated"
instance FromJSON ContentRatingBfvcRating where
parseJSON = parseJSONText "ContentRatingBfvcRating"
instance ToJSON ContentRatingBfvcRating where
toJSON = toJSONText
data LiveBroadcastTopicType
= VideoGame
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastTopicType
instance FromText LiveBroadcastTopicType where
fromText = \case
"videoGame" -> Just VideoGame
_ -> Nothing
instance ToText LiveBroadcastTopicType where
toText = \case
VideoGame -> "videoGame"
instance FromJSON LiveBroadcastTopicType where
parseJSON = parseJSONText "LiveBroadcastTopicType"
instance ToJSON LiveBroadcastTopicType where
toJSON = toJSONText
data SearchListVideoDuration
= Any
| Long
| Medium
| Short
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoDuration
instance FromText SearchListVideoDuration where
fromText = \case
"any" -> Just Any
"long" -> Just Long
"medium" -> Just Medium
"short" -> Just Short
_ -> Nothing
instance ToText SearchListVideoDuration where
toText = \case
Any -> "any"
Long -> "long"
Medium -> "medium"
Short -> "short"
instance FromJSON SearchListVideoDuration where
parseJSON = parseJSONText "SearchListVideoDuration"
instance ToJSON SearchListVideoDuration where
toJSON = toJSONText
data SearchListVideoCaption
= SLVCAny
| SLVCClosedCaption
| SLVCNone
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoCaption
instance FromText SearchListVideoCaption where
fromText = \case
"any" -> Just SLVCAny
"closedCaption" -> Just SLVCClosedCaption
"none" -> Just SLVCNone
_ -> Nothing
instance ToText SearchListVideoCaption where
toText = \case
SLVCAny -> "any"
SLVCClosedCaption -> "closedCaption"
SLVCNone -> "none"
instance FromJSON SearchListVideoCaption where
parseJSON = parseJSONText "SearchListVideoCaption"
instance ToJSON SearchListVideoCaption where
toJSON = toJSONText
data VideosListMyRating
= Dislike
| Like
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideosListMyRating
instance FromText VideosListMyRating where
fromText = \case
"dislike" -> Just Dislike
"like" -> Just Like
_ -> Nothing
instance ToText VideosListMyRating where
toText = \case
Dislike -> "dislike"
Like -> "like"
instance FromJSON VideosListMyRating where
parseJSON = parseJSONText "VideosListMyRating"
instance ToJSON VideosListMyRating where
toJSON = toJSONText
data CommentSnippetViewerRating
= CSVRDislike
| CSVRLike
| CSVRNone
| CSVRUnspecified
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentSnippetViewerRating
instance FromText CommentSnippetViewerRating where
fromText = \case
"dislike" -> Just CSVRDislike
"like" -> Just CSVRLike
"none" -> Just CSVRNone
"unspecified" -> Just CSVRUnspecified
_ -> Nothing
instance ToText CommentSnippetViewerRating where
toText = \case
CSVRDislike -> "dislike"
CSVRLike -> "like"
CSVRNone -> "none"
CSVRUnspecified -> "unspecified"
instance FromJSON CommentSnippetViewerRating where
parseJSON = parseJSONText "CommentSnippetViewerRating"
instance ToJSON CommentSnippetViewerRating where
toJSON = toJSONText
data ContentRatingFcbmRating
= FCBM18
| Fcbm18pa
| Fcbm18pl
| Fcbm18sg
| Fcbm18sx
| FCBMP13
| FCBMPG13
| FcbmU
| FcbmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingFcbmRating
instance FromText ContentRatingFcbmRating where
fromText = \case
"fcbm18" -> Just FCBM18
"fcbm18pa" -> Just Fcbm18pa
"fcbm18pl" -> Just Fcbm18pl
"fcbm18sg" -> Just Fcbm18sg
"fcbm18sx" -> Just Fcbm18sx
"fcbmP13" -> Just FCBMP13
"fcbmPg13" -> Just FCBMPG13
"fcbmU" -> Just FcbmU
"fcbmUnrated" -> Just FcbmUnrated
_ -> Nothing
instance ToText ContentRatingFcbmRating where
toText = \case
FCBM18 -> "fcbm18"
Fcbm18pa -> "fcbm18pa"
Fcbm18pl -> "fcbm18pl"
Fcbm18sg -> "fcbm18sg"
Fcbm18sx -> "fcbm18sx"
FCBMP13 -> "fcbmP13"
FCBMPG13 -> "fcbmPg13"
FcbmU -> "fcbmU"
FcbmUnrated -> "fcbmUnrated"
instance FromJSON ContentRatingFcbmRating where
parseJSON = parseJSONText "ContentRatingFcbmRating"
instance ToJSON ContentRatingFcbmRating where
toJSON = toJSONText
data LiveBroadcastsListBroadcastStatus
= LBLBSActive
| LBLBSAll
| LBLBSCompleted
| LBLBSUpcoming
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastsListBroadcastStatus
instance FromText LiveBroadcastsListBroadcastStatus where
fromText = \case
"active" -> Just LBLBSActive
"all" -> Just LBLBSAll
"completed" -> Just LBLBSCompleted
"upcoming" -> Just LBLBSUpcoming
_ -> Nothing
instance ToText LiveBroadcastsListBroadcastStatus where
toText = \case
LBLBSActive -> "active"
LBLBSAll -> "all"
LBLBSCompleted -> "completed"
LBLBSUpcoming -> "upcoming"
instance FromJSON LiveBroadcastsListBroadcastStatus where
parseJSON = parseJSONText "LiveBroadcastsListBroadcastStatus"
instance ToJSON LiveBroadcastsListBroadcastStatus where
toJSON = toJSONText
data ContentRatingMoctwRating
= MoctwG
| MoctwP
| MoctwPg
| MoctwR
| MoctwUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMoctwRating
instance FromText ContentRatingMoctwRating where
fromText = \case
"moctwG" -> Just MoctwG
"moctwP" -> Just MoctwP
"moctwPg" -> Just MoctwPg
"moctwR" -> Just MoctwR
"moctwUnrated" -> Just MoctwUnrated
_ -> Nothing
instance ToText ContentRatingMoctwRating where
toText = \case
MoctwG -> "moctwG"
MoctwP -> "moctwP"
MoctwPg -> "moctwPg"
MoctwR -> "moctwR"
MoctwUnrated -> "moctwUnrated"
instance FromJSON ContentRatingMoctwRating where
parseJSON = parseJSONText "ContentRatingMoctwRating"
instance ToJSON ContentRatingMoctwRating where
toJSON = toJSONText
data ContentRatingBmukkRating
= BMUKK10
| BMUKK12
| BMUKK14
| BMUKK16
| BMUKK6
| BMUKK8
| BmukkAa
| BmukkUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingBmukkRating
instance FromText ContentRatingBmukkRating where
fromText = \case
"bmukk10" -> Just BMUKK10
"bmukk12" -> Just BMUKK12
"bmukk14" -> Just BMUKK14
"bmukk16" -> Just BMUKK16
"bmukk6" -> Just BMUKK6
"bmukk8" -> Just BMUKK8
"bmukkAa" -> Just BmukkAa
"bmukkUnrated" -> Just BmukkUnrated
_ -> Nothing
instance ToText ContentRatingBmukkRating where
toText = \case
BMUKK10 -> "bmukk10"
BMUKK12 -> "bmukk12"
BMUKK14 -> "bmukk14"
BMUKK16 -> "bmukk16"
BMUKK6 -> "bmukk6"
BMUKK8 -> "bmukk8"
BmukkAa -> "bmukkAa"
BmukkUnrated -> "bmukkUnrated"
instance FromJSON ContentRatingBmukkRating where
parseJSON = parseJSONText "ContentRatingBmukkRating"
instance ToJSON ContentRatingBmukkRating where
toJSON = toJSONText
data ContentRatingIcaaRating
= ICAA12
| ICAA13
| ICAA16
| ICAA18
| ICAA7
| IcaaApta
| IcaaUnrated
| IcaaX
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingIcaaRating
instance FromText ContentRatingIcaaRating where
fromText = \case
"icaa12" -> Just ICAA12
"icaa13" -> Just ICAA13
"icaa16" -> Just ICAA16
"icaa18" -> Just ICAA18
"icaa7" -> Just ICAA7
"icaaApta" -> Just IcaaApta
"icaaUnrated" -> Just IcaaUnrated
"icaaX" -> Just IcaaX
_ -> Nothing
instance ToText ContentRatingIcaaRating where
toText = \case
ICAA12 -> "icaa12"
ICAA13 -> "icaa13"
ICAA16 -> "icaa16"
ICAA18 -> "icaa18"
ICAA7 -> "icaa7"
IcaaApta -> "icaaApta"
IcaaUnrated -> "icaaUnrated"
IcaaX -> "icaaX"
instance FromJSON ContentRatingIcaaRating where
parseJSON = parseJSONText "ContentRatingIcaaRating"
instance ToJSON ContentRatingIcaaRating where
toJSON = toJSONText
data VideoStatusRejectionReason
= Claim
| Copyright
| Duplicate
| InAppropriate
| Length
| TermsOfUse
| Trademark
| UploaderAccountClosed
| UploaderAccountSuspended
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoStatusRejectionReason
instance FromText VideoStatusRejectionReason where
fromText = \case
"claim" -> Just Claim
"copyright" -> Just Copyright
"duplicate" -> Just Duplicate
"inappropriate" -> Just InAppropriate
"length" -> Just Length
"termsOfUse" -> Just TermsOfUse
"trademark" -> Just Trademark
"uploaderAccountClosed" -> Just UploaderAccountClosed
"uploaderAccountSuspended" -> Just UploaderAccountSuspended
_ -> Nothing
instance ToText VideoStatusRejectionReason where
toText = \case
Claim -> "claim"
Copyright -> "copyright"
Duplicate -> "duplicate"
InAppropriate -> "inappropriate"
Length -> "length"
TermsOfUse -> "termsOfUse"
Trademark -> "trademark"
UploaderAccountClosed -> "uploaderAccountClosed"
UploaderAccountSuspended -> "uploaderAccountSuspended"
instance FromJSON VideoStatusRejectionReason where
parseJSON = parseJSONText "VideoStatusRejectionReason"
instance ToJSON VideoStatusRejectionReason where
toJSON = toJSONText
data ContentRatingCzfilmRating
= CZFILM12
| CZFILM14
| CZFILM18
| CzfilmU
| CzfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCzfilmRating
instance FromText ContentRatingCzfilmRating where
fromText = \case
"czfilm12" -> Just CZFILM12
"czfilm14" -> Just CZFILM14
"czfilm18" -> Just CZFILM18
"czfilmU" -> Just CzfilmU
"czfilmUnrated" -> Just CzfilmUnrated
_ -> Nothing
instance ToText ContentRatingCzfilmRating where
toText = \case
CZFILM12 -> "czfilm12"
CZFILM14 -> "czfilm14"
CZFILM18 -> "czfilm18"
CzfilmU -> "czfilmU"
CzfilmUnrated -> "czfilmUnrated"
instance FromJSON ContentRatingCzfilmRating where
parseJSON = parseJSONText "ContentRatingCzfilmRating"
instance ToJSON ContentRatingCzfilmRating where
toJSON = toJSONText
data ContentRatingRussiaRating
= RUSSIA0
| RUSSIA12
| RUSSIA16
| RUSSIA18
| RUSSIA6
| RussiaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingRussiaRating
instance FromText ContentRatingRussiaRating where
fromText = \case
"russia0" -> Just RUSSIA0
"russia12" -> Just RUSSIA12
"russia16" -> Just RUSSIA16
"russia18" -> Just RUSSIA18
"russia6" -> Just RUSSIA6
"russiaUnrated" -> Just RussiaUnrated
_ -> Nothing
instance ToText ContentRatingRussiaRating where
toText = \case
RUSSIA0 -> "russia0"
RUSSIA12 -> "russia12"
RUSSIA16 -> "russia16"
RUSSIA18 -> "russia18"
RUSSIA6 -> "russia6"
RussiaUnrated -> "russiaUnrated"
instance FromJSON ContentRatingRussiaRating where
parseJSON = parseJSONText "ContentRatingRussiaRating"
instance ToJSON ContentRatingRussiaRating where
toJSON = toJSONText
data ContentRatingCicfRating
= CicfE
| CicfKntEna
| CicfKtEa
| CicfUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCicfRating
instance FromText ContentRatingCicfRating where
fromText = \case
"cicfE" -> Just CicfE
"cicfKntEna" -> Just CicfKntEna
"cicfKtEa" -> Just CicfKtEa
"cicfUnrated" -> Just CicfUnrated
_ -> Nothing
instance ToText ContentRatingCicfRating where
toText = \case
CicfE -> "cicfE"
CicfKntEna -> "cicfKntEna"
CicfKtEa -> "cicfKtEa"
CicfUnrated -> "cicfUnrated"
instance FromJSON ContentRatingCicfRating where
parseJSON = parseJSONText "ContentRatingCicfRating"
instance ToJSON ContentRatingCicfRating where
toJSON = toJSONText
data ContentRatingFmocRating
= FMOC10
| FMOC12
| FMOC16
| FMOC18
| FmocE
| FmocU
| FmocUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingFmocRating
instance FromText ContentRatingFmocRating where
fromText = \case
"fmoc10" -> Just FMOC10
"fmoc12" -> Just FMOC12
"fmoc16" -> Just FMOC16
"fmoc18" -> Just FMOC18
"fmocE" -> Just FmocE
"fmocU" -> Just FmocU
"fmocUnrated" -> Just FmocUnrated
_ -> Nothing
instance ToText ContentRatingFmocRating where
toText = \case
FMOC10 -> "fmoc10"
FMOC12 -> "fmoc12"
FMOC16 -> "fmoc16"
FMOC18 -> "fmoc18"
FmocE -> "fmocE"
FmocU -> "fmocU"
FmocUnrated -> "fmocUnrated"
instance FromJSON ContentRatingFmocRating where
parseJSON = parseJSONText "ContentRatingFmocRating"
instance ToJSON ContentRatingFmocRating where
toJSON = toJSONText
data LiveBroadcastsTransitionBroadcastStatus
= LBTBSComplete
| LBTBSLive
| LBTBSTesting
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastsTransitionBroadcastStatus
instance FromText LiveBroadcastsTransitionBroadcastStatus where
fromText = \case
"complete" -> Just LBTBSComplete
"live" -> Just LBTBSLive
"testing" -> Just LBTBSTesting
_ -> Nothing
instance ToText LiveBroadcastsTransitionBroadcastStatus where
toText = \case
LBTBSComplete -> "complete"
LBTBSLive -> "live"
LBTBSTesting -> "testing"
instance FromJSON LiveBroadcastsTransitionBroadcastStatus where
parseJSON = parseJSONText "LiveBroadcastsTransitionBroadcastStatus"
instance ToJSON LiveBroadcastsTransitionBroadcastStatus where
toJSON = toJSONText
data ContentRatingNbcRating
= Nbc12plus
| Nbc15plus
| Nbc18plus
| Nbc18plusr
| NbcG
| NbcPg
| NbcPu
| NbcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingNbcRating
instance FromText ContentRatingNbcRating where
fromText = \case
"nbc12plus" -> Just Nbc12plus
"nbc15plus" -> Just Nbc15plus
"nbc18plus" -> Just Nbc18plus
"nbc18plusr" -> Just Nbc18plusr
"nbcG" -> Just NbcG
"nbcPg" -> Just NbcPg
"nbcPu" -> Just NbcPu
"nbcUnrated" -> Just NbcUnrated
_ -> Nothing
instance ToText ContentRatingNbcRating where
toText = \case
Nbc12plus -> "nbc12plus"
Nbc15plus -> "nbc15plus"
Nbc18plus -> "nbc18plus"
Nbc18plusr -> "nbc18plusr"
NbcG -> "nbcG"
NbcPg -> "nbcPg"
NbcPu -> "nbcPu"
NbcUnrated -> "nbcUnrated"
instance FromJSON ContentRatingNbcRating where
parseJSON = parseJSONText "ContentRatingNbcRating"
instance ToJSON ContentRatingNbcRating where
toJSON = toJSONText
data LiveBroadcastStatusLiveBroadcastPriority
= High
| Low
| Normal
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastStatusLiveBroadcastPriority
instance FromText LiveBroadcastStatusLiveBroadcastPriority where
fromText = \case
"high" -> Just High
"low" -> Just Low
"normal" -> Just Normal
_ -> Nothing
instance ToText LiveBroadcastStatusLiveBroadcastPriority where
toText = \case
High -> "high"
Low -> "low"
Normal -> "normal"
instance FromJSON LiveBroadcastStatusLiveBroadcastPriority where
parseJSON = parseJSONText "LiveBroadcastStatusLiveBroadcastPriority"
instance ToJSON LiveBroadcastStatusLiveBroadcastPriority where
toJSON = toJSONText
data LiveStreamHealthStatusStatus
= Bad
| Good
| NoData
| OK
| Revoked
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveStreamHealthStatusStatus
instance FromText LiveStreamHealthStatusStatus where
fromText = \case
"bad" -> Just Bad
"good" -> Just Good
"noData" -> Just NoData
"ok" -> Just OK
"revoked" -> Just Revoked
_ -> Nothing
instance ToText LiveStreamHealthStatusStatus where
toText = \case
Bad -> "bad"
Good -> "good"
NoData -> "noData"
OK -> "ok"
Revoked -> "revoked"
instance FromJSON LiveStreamHealthStatusStatus where
parseJSON = parseJSONText "LiveStreamHealthStatusStatus"
instance ToJSON LiveStreamHealthStatusStatus where
toJSON = toJSONText
data VideoRatingRating
= VRRDislike
| VRRLike
| VRRNone
| VRRUnspecified
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoRatingRating
instance FromText VideoRatingRating where
fromText = \case
"dislike" -> Just VRRDislike
"like" -> Just VRRLike
"none" -> Just VRRNone
"unspecified" -> Just VRRUnspecified
_ -> Nothing
instance ToText VideoRatingRating where
toText = \case
VRRDislike -> "dislike"
VRRLike -> "like"
VRRNone -> "none"
VRRUnspecified -> "unspecified"
instance FromJSON VideoRatingRating where
parseJSON = parseJSONText "VideoRatingRating"
instance ToJSON VideoRatingRating where
toJSON = toJSONText
data VideoSuggestionsProcessingWarningsItem
= HasEditList
| InconsistentResolution
| ProblematicAudioCodec
| ProblematicVideoCodec
| UnknownAudioCodec
| UnknownContainer
| UnknownVideoCodec
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoSuggestionsProcessingWarningsItem
instance FromText VideoSuggestionsProcessingWarningsItem where
fromText = \case
"hasEditlist" -> Just HasEditList
"inconsistentResolution" -> Just InconsistentResolution
"problematicAudioCodec" -> Just ProblematicAudioCodec
"problematicVideoCodec" -> Just ProblematicVideoCodec
"unknownAudioCodec" -> Just UnknownAudioCodec
"unknownContainer" -> Just UnknownContainer
"unknownVideoCodec" -> Just UnknownVideoCodec
_ -> Nothing
instance ToText VideoSuggestionsProcessingWarningsItem where
toText = \case
HasEditList -> "hasEditlist"
InconsistentResolution -> "inconsistentResolution"
ProblematicAudioCodec -> "problematicAudioCodec"
ProblematicVideoCodec -> "problematicVideoCodec"
UnknownAudioCodec -> "unknownAudioCodec"
UnknownContainer -> "unknownContainer"
UnknownVideoCodec -> "unknownVideoCodec"
instance FromJSON VideoSuggestionsProcessingWarningsItem where
parseJSON = parseJSONText "VideoSuggestionsProcessingWarningsItem"
instance ToJSON VideoSuggestionsProcessingWarningsItem where
toJSON = toJSONText
data InvideoPositionCornerPosition
= BottomLeft
| BottomRight
| TopLeft
| TopRight
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable InvideoPositionCornerPosition
instance FromText InvideoPositionCornerPosition where
fromText = \case
"bottomLeft" -> Just BottomLeft
"bottomRight" -> Just BottomRight
"topLeft" -> Just TopLeft
"topRight" -> Just TopRight
_ -> Nothing
instance ToText InvideoPositionCornerPosition where
toText = \case
BottomLeft -> "bottomLeft"
BottomRight -> "bottomRight"
TopLeft -> "topLeft"
TopRight -> "topRight"
instance FromJSON InvideoPositionCornerPosition where
parseJSON = parseJSONText "InvideoPositionCornerPosition"
instance ToJSON InvideoPositionCornerPosition where
toJSON = toJSONText
data ChannelStatusLongUploadsStatus
= Allowed
| Disallowed
| Eligible
| LongUploadsUnspecified
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ChannelStatusLongUploadsStatus
instance FromText ChannelStatusLongUploadsStatus where
fromText = \case
"allowed" -> Just Allowed
"disallowed" -> Just Disallowed
"eligible" -> Just Eligible
"longUploadsUnspecified" -> Just LongUploadsUnspecified
_ -> Nothing
instance ToText ChannelStatusLongUploadsStatus where
toText = \case
Allowed -> "allowed"
Disallowed -> "disallowed"
Eligible -> "eligible"
LongUploadsUnspecified -> "longUploadsUnspecified"
instance FromJSON ChannelStatusLongUploadsStatus where
parseJSON = parseJSONText "ChannelStatusLongUploadsStatus"
instance ToJSON ChannelStatusLongUploadsStatus where
toJSON = toJSONText
data ContentRatingCscfRating
= CSCF12
| CSCF16
| CSCF18
| CSCF6
| CSCF9
| CscfA
| CscfAl
| CscfUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCscfRating
instance FromText ContentRatingCscfRating where
fromText = \case
"cscf12" -> Just CSCF12
"cscf16" -> Just CSCF16
"cscf18" -> Just CSCF18
"cscf6" -> Just CSCF6
"cscf9" -> Just CSCF9
"cscfA" -> Just CscfA
"cscfAl" -> Just CscfAl
"cscfUnrated" -> Just CscfUnrated
_ -> Nothing
instance ToText ContentRatingCscfRating where
toText = \case
CSCF12 -> "cscf12"
CSCF16 -> "cscf16"
CSCF18 -> "cscf18"
CSCF6 -> "cscf6"
CSCF9 -> "cscf9"
CscfA -> "cscfA"
CscfAl -> "cscfAl"
CscfUnrated -> "cscfUnrated"
instance FromJSON ContentRatingCscfRating where
parseJSON = parseJSONText "ContentRatingCscfRating"
instance ToJSON ContentRatingCscfRating where
toJSON = toJSONText
data LiveBroadcastStatusRecordingStatus
= NotRecording
| Recorded
| Recording
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveBroadcastStatusRecordingStatus
instance FromText LiveBroadcastStatusRecordingStatus where
fromText = \case
"notRecording" -> Just NotRecording
"recorded" -> Just Recorded
"recording" -> Just Recording
_ -> Nothing
instance ToText LiveBroadcastStatusRecordingStatus where
toText = \case
NotRecording -> "notRecording"
Recorded -> "recorded"
Recording -> "recording"
instance FromJSON LiveBroadcastStatusRecordingStatus where
parseJSON = parseJSONText "LiveBroadcastStatusRecordingStatus"
instance ToJSON LiveBroadcastStatusRecordingStatus where
toJSON = toJSONText
data VideoFileDetailsVideoStreamRotation
= VFDVSRClockwise
| VFDVSRCounterClockwise
| VFDVSRNone
| VFDVSROther
| VFDVSRUpsideDown
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoFileDetailsVideoStreamRotation
instance FromText VideoFileDetailsVideoStreamRotation where
fromText = \case
"clockwise" -> Just VFDVSRClockwise
"counterClockwise" -> Just VFDVSRCounterClockwise
"none" -> Just VFDVSRNone
"other" -> Just VFDVSROther
"upsideDown" -> Just VFDVSRUpsideDown
_ -> Nothing
instance ToText VideoFileDetailsVideoStreamRotation where
toText = \case
VFDVSRClockwise -> "clockwise"
VFDVSRCounterClockwise -> "counterClockwise"
VFDVSRNone -> "none"
VFDVSROther -> "other"
VFDVSRUpsideDown -> "upsideDown"
instance FromJSON VideoFileDetailsVideoStreamRotation where
parseJSON = parseJSONText "VideoFileDetailsVideoStreamRotation"
instance ToJSON VideoFileDetailsVideoStreamRotation where
toJSON = toJSONText
data ContentRatingRtcRating
= RtcA
| RtcAa
| RtcB
| RTCB15
| RtcC
| RtcD
| RtcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingRtcRating
instance FromText ContentRatingRtcRating where
fromText = \case
"rtcA" -> Just RtcA
"rtcAa" -> Just RtcAa
"rtcB" -> Just RtcB
"rtcB15" -> Just RTCB15
"rtcC" -> Just RtcC
"rtcD" -> Just RtcD
"rtcUnrated" -> Just RtcUnrated
_ -> Nothing
instance ToText ContentRatingRtcRating where
toText = \case
RtcA -> "rtcA"
RtcAa -> "rtcAa"
RtcB -> "rtcB"
RTCB15 -> "rtcB15"
RtcC -> "rtcC"
RtcD -> "rtcD"
RtcUnrated -> "rtcUnrated"
instance FromJSON ContentRatingRtcRating where
parseJSON = parseJSONText "ContentRatingRtcRating"
instance ToJSON ContentRatingRtcRating where
toJSON = toJSONText
data CommentThreadsListModerationStatus
= HeldForReview
| LikelySpam
| Published
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentThreadsListModerationStatus
instance FromText CommentThreadsListModerationStatus where
fromText = \case
"heldForReview" -> Just HeldForReview
"likelySpam" -> Just LikelySpam
"published" -> Just Published
_ -> Nothing
instance ToText CommentThreadsListModerationStatus where
toText = \case
HeldForReview -> "heldForReview"
LikelySpam -> "likelySpam"
Published -> "published"
instance FromJSON CommentThreadsListModerationStatus where
parseJSON = parseJSONText "CommentThreadsListModerationStatus"
instance ToJSON CommentThreadsListModerationStatus where
toJSON = toJSONText
data ContentRatingSmaisRating
= SMAIS12
| SMAIS14
| SMAIS16
| SMAIS18
| SMAIS7
| SmaisL
| SmaisUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingSmaisRating
instance FromText ContentRatingSmaisRating where
fromText = \case
"smais12" -> Just SMAIS12
"smais14" -> Just SMAIS14
"smais16" -> Just SMAIS16
"smais18" -> Just SMAIS18
"smais7" -> Just SMAIS7
"smaisL" -> Just SmaisL
"smaisUnrated" -> Just SmaisUnrated
_ -> Nothing
instance ToText ContentRatingSmaisRating where
toText = \case
SMAIS12 -> "smais12"
SMAIS14 -> "smais14"
SMAIS16 -> "smais16"
SMAIS18 -> "smais18"
SMAIS7 -> "smais7"
SmaisL -> "smaisL"
SmaisUnrated -> "smaisUnrated"
instance FromJSON ContentRatingSmaisRating where
parseJSON = parseJSONText "ContentRatingSmaisRating"
instance ToJSON ContentRatingSmaisRating where
toJSON = toJSONText
data ContentRatingYtRating
= YtAgeRestricted
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingYtRating
instance FromText ContentRatingYtRating where
fromText = \case
"ytAgeRestricted" -> Just YtAgeRestricted
_ -> Nothing
instance ToText ContentRatingYtRating where
toText = \case
YtAgeRestricted -> "ytAgeRestricted"
instance FromJSON ContentRatingYtRating where
parseJSON = parseJSONText "ContentRatingYtRating"
instance ToJSON ContentRatingYtRating where
toJSON = toJSONText
data VideoContentDetailsCaption
= False'
| True'
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoContentDetailsCaption
instance FromText VideoContentDetailsCaption where
fromText = \case
"false" -> Just False'
"true" -> Just True'
_ -> Nothing
instance ToText VideoContentDetailsCaption where
toText = \case
False' -> "false"
True' -> "true"
instance FromJSON VideoContentDetailsCaption where
parseJSON = parseJSONText "VideoContentDetailsCaption"
instance ToJSON VideoContentDetailsCaption where
toJSON = toJSONText
data SubscriptionsListOrder
= SLOAlphabetical
| SLORelevance
| SLOUnread
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SubscriptionsListOrder
instance FromText SubscriptionsListOrder where
fromText = \case
"alphabetical" -> Just SLOAlphabetical
"relevance" -> Just SLORelevance
"unread" -> Just SLOUnread
_ -> Nothing
instance ToText SubscriptionsListOrder where
toText = \case
SLOAlphabetical -> "alphabetical"
SLORelevance -> "relevance"
SLOUnread -> "unread"
instance FromJSON SubscriptionsListOrder where
parseJSON = parseJSONText "SubscriptionsListOrder"
instance ToJSON SubscriptionsListOrder where
toJSON = toJSONText
data ContentRatingBbfcRating
= BBFC12
| Bbfc12a
| BBFC15
| BBFC18
| BbfcPg
| BBFCR18
| BbfcU
| BbfcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingBbfcRating
instance FromText ContentRatingBbfcRating where
fromText = \case
"bbfc12" -> Just BBFC12
"bbfc12a" -> Just Bbfc12a
"bbfc15" -> Just BBFC15
"bbfc18" -> Just BBFC18
"bbfcPg" -> Just BbfcPg
"bbfcR18" -> Just BBFCR18
"bbfcU" -> Just BbfcU
"bbfcUnrated" -> Just BbfcUnrated
_ -> Nothing
instance ToText ContentRatingBbfcRating where
toText = \case
BBFC12 -> "bbfc12"
Bbfc12a -> "bbfc12a"
BBFC15 -> "bbfc15"
BBFC18 -> "bbfc18"
BbfcPg -> "bbfcPg"
BBFCR18 -> "bbfcR18"
BbfcU -> "bbfcU"
BbfcUnrated -> "bbfcUnrated"
instance FromJSON ContentRatingBbfcRating where
parseJSON = parseJSONText "ContentRatingBbfcRating"
instance ToJSON ContentRatingBbfcRating where
toJSON = toJSONText
data ContentRatingTvpgRating
= PG14
| TvpgG
| TvpgMa
| TvpgPg
| TvpgUnrated
| TvpgY
| TVPGY7
| TvpgY7Fv
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingTvpgRating
instance FromText ContentRatingTvpgRating where
fromText = \case
"pg14" -> Just PG14
"tvpgG" -> Just TvpgG
"tvpgMa" -> Just TvpgMa
"tvpgPg" -> Just TvpgPg
"tvpgUnrated" -> Just TvpgUnrated
"tvpgY" -> Just TvpgY
"tvpgY7" -> Just TVPGY7
"tvpgY7Fv" -> Just TvpgY7Fv
_ -> Nothing
instance ToText ContentRatingTvpgRating where
toText = \case
PG14 -> "pg14"
TvpgG -> "tvpgG"
TvpgMa -> "tvpgMa"
TvpgPg -> "tvpgPg"
TvpgUnrated -> "tvpgUnrated"
TvpgY -> "tvpgY"
TVPGY7 -> "tvpgY7"
TvpgY7Fv -> "tvpgY7Fv"
instance FromJSON ContentRatingTvpgRating where
parseJSON = parseJSONText "ContentRatingTvpgRating"
instance ToJSON ContentRatingTvpgRating where
toJSON = toJSONText
data CommentsListTextFormat
= HTML
| PlainText
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentsListTextFormat
instance FromText CommentsListTextFormat where
fromText = \case
"html" -> Just HTML
"plainText" -> Just PlainText
_ -> Nothing
instance ToText CommentsListTextFormat where
toText = \case
HTML -> "html"
PlainText -> "plainText"
instance FromJSON CommentsListTextFormat where
parseJSON = parseJSONText "CommentsListTextFormat"
instance ToJSON CommentsListTextFormat where
toJSON = toJSONText
data VideosRateRating
= VDislike
| VLike
| VNone
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideosRateRating
instance FromText VideosRateRating where
fromText = \case
"dislike" -> Just VDislike
"like" -> Just VLike
"none" -> Just VNone
_ -> Nothing
instance ToText VideosRateRating where
toText = \case
VDislike -> "dislike"
VLike -> "like"
VNone -> "none"
instance FromJSON VideosRateRating where
parseJSON = parseJSONText "VideosRateRating"
instance ToJSON VideosRateRating where
toJSON = toJSONText
data CaptionSnippetStatus
= Failed
| Serving
| Syncing
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CaptionSnippetStatus
instance FromText CaptionSnippetStatus where
fromText = \case
"failed" -> Just Failed
"serving" -> Just Serving
"syncing" -> Just Syncing
_ -> Nothing
instance ToText CaptionSnippetStatus where
toText = \case
Failed -> "failed"
Serving -> "serving"
Syncing -> "syncing"
instance FromJSON CaptionSnippetStatus where
parseJSON = parseJSONText "CaptionSnippetStatus"
instance ToJSON CaptionSnippetStatus where
toJSON = toJSONText
data ContentRatingSkfilmRating
= SkfilmG
| SKFILMP2
| SKFILMP5
| SKFILMP8
| SkfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingSkfilmRating
instance FromText ContentRatingSkfilmRating where
fromText = \case
"skfilmG" -> Just SkfilmG
"skfilmP2" -> Just SKFILMP2
"skfilmP5" -> Just SKFILMP5
"skfilmP8" -> Just SKFILMP8
"skfilmUnrated" -> Just SkfilmUnrated
_ -> Nothing
instance ToText ContentRatingSkfilmRating where
toText = \case
SkfilmG -> "skfilmG"
SKFILMP2 -> "skfilmP2"
SKFILMP5 -> "skfilmP5"
SKFILMP8 -> "skfilmP8"
SkfilmUnrated -> "skfilmUnrated"
instance FromJSON ContentRatingSkfilmRating where
parseJSON = parseJSONText "ContentRatingSkfilmRating"
instance ToJSON ContentRatingSkfilmRating where
toJSON = toJSONText
data ChannelSectionSnippetType
= AllPlayLists
| ChannelsectionTypeUndefined
| CompletedEvents
| LikedPlayLists
| Likes
| LiveEvents
| MultipleChannels
| MultiplePlayLists
| PopularUploads
| PostedPlayLists
| PostedVideos
| RecentActivity
| RecentPosts
| RecentUploads
| SinglePlayList
| Subscriptions
| UpcomingEvents
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ChannelSectionSnippetType
instance FromText ChannelSectionSnippetType where
fromText = \case
"allPlaylists" -> Just AllPlayLists
"channelsectionTypeUndefined" -> Just ChannelsectionTypeUndefined
"completedEvents" -> Just CompletedEvents
"likedPlaylists" -> Just LikedPlayLists
"likes" -> Just Likes
"liveEvents" -> Just LiveEvents
"multipleChannels" -> Just MultipleChannels
"multiplePlaylists" -> Just MultiplePlayLists
"popularUploads" -> Just PopularUploads
"postedPlaylists" -> Just PostedPlayLists
"postedVideos" -> Just PostedVideos
"recentActivity" -> Just RecentActivity
"recentPosts" -> Just RecentPosts
"recentUploads" -> Just RecentUploads
"singlePlaylist" -> Just SinglePlayList
"subscriptions" -> Just Subscriptions
"upcomingEvents" -> Just UpcomingEvents
_ -> Nothing
instance ToText ChannelSectionSnippetType where
toText = \case
AllPlayLists -> "allPlaylists"
ChannelsectionTypeUndefined -> "channelsectionTypeUndefined"
CompletedEvents -> "completedEvents"
LikedPlayLists -> "likedPlaylists"
Likes -> "likes"
LiveEvents -> "liveEvents"
MultipleChannels -> "multipleChannels"
MultiplePlayLists -> "multiplePlaylists"
PopularUploads -> "popularUploads"
PostedPlayLists -> "postedPlaylists"
PostedVideos -> "postedVideos"
RecentActivity -> "recentActivity"
RecentPosts -> "recentPosts"
RecentUploads -> "recentUploads"
SinglePlayList -> "singlePlaylist"
Subscriptions -> "subscriptions"
UpcomingEvents -> "upcomingEvents"
instance FromJSON ChannelSectionSnippetType where
parseJSON = parseJSONText "ChannelSectionSnippetType"
instance ToJSON ChannelSectionSnippetType where
toJSON = toJSONText
data VideoProcessingDetailsProcessingStatus
= VPDPSFailed
| VPDPSProcessing
| VPDPSSucceeded
| VPDPSTerminated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoProcessingDetailsProcessingStatus
instance FromText VideoProcessingDetailsProcessingStatus where
fromText = \case
"failed" -> Just VPDPSFailed
"processing" -> Just VPDPSProcessing
"succeeded" -> Just VPDPSSucceeded
"terminated" -> Just VPDPSTerminated
_ -> Nothing
instance ToText VideoProcessingDetailsProcessingStatus where
toText = \case
VPDPSFailed -> "failed"
VPDPSProcessing -> "processing"
VPDPSSucceeded -> "succeeded"
VPDPSTerminated -> "terminated"
instance FromJSON VideoProcessingDetailsProcessingStatus where
parseJSON = parseJSONText "VideoProcessingDetailsProcessingStatus"
instance ToJSON VideoProcessingDetailsProcessingStatus where
toJSON = toJSONText
data ActivityContentDetailsPromotedItemCtaType
= Unspecified
| VisitAdvertiserSite
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ActivityContentDetailsPromotedItemCtaType
instance FromText ActivityContentDetailsPromotedItemCtaType where
fromText = \case
"unspecified" -> Just Unspecified
"visitAdvertiserSite" -> Just VisitAdvertiserSite
_ -> Nothing
instance ToText ActivityContentDetailsPromotedItemCtaType where
toText = \case
Unspecified -> "unspecified"
VisitAdvertiserSite -> "visitAdvertiserSite"
instance FromJSON ActivityContentDetailsPromotedItemCtaType where
parseJSON = parseJSONText "ActivityContentDetailsPromotedItemCtaType"
instance ToJSON ActivityContentDetailsPromotedItemCtaType where
toJSON = toJSONText
data SearchListChannelType
= SLCTAny
| SLCTShow
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListChannelType
instance FromText SearchListChannelType where
fromText = \case
"any" -> Just SLCTAny
"show" -> Just SLCTShow
_ -> Nothing
instance ToText SearchListChannelType where
toText = \case
SLCTAny -> "any"
SLCTShow -> "show"
instance FromJSON SearchListChannelType where
parseJSON = parseJSONText "SearchListChannelType"
instance ToJSON SearchListChannelType where
toJSON = toJSONText
data ContentRatingKmrbRating
= Kmrb12plus
| Kmrb15plus
| KmrbAll
| KmrbR
| KmrbTeenr
| KmrbUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingKmrbRating
instance FromText ContentRatingKmrbRating where
fromText = \case
"kmrb12plus" -> Just Kmrb12plus
"kmrb15plus" -> Just Kmrb15plus
"kmrbAll" -> Just KmrbAll
"kmrbR" -> Just KmrbR
"kmrbTeenr" -> Just KmrbTeenr
"kmrbUnrated" -> Just KmrbUnrated
_ -> Nothing
instance ToText ContentRatingKmrbRating where
toText = \case
Kmrb12plus -> "kmrb12plus"
Kmrb15plus -> "kmrb15plus"
KmrbAll -> "kmrbAll"
KmrbR -> "kmrbR"
KmrbTeenr -> "kmrbTeenr"
KmrbUnrated -> "kmrbUnrated"
instance FromJSON ContentRatingKmrbRating where
parseJSON = parseJSONText "ContentRatingKmrbRating"
instance ToJSON ContentRatingKmrbRating where
toJSON = toJSONText
data ContentRatingOflcRating
= OflcG
| OflcM
| OflcPg
| OFLCR13
| OFLCR15
| OFLCR16
| OFLCR18
| OFLCRP13
| OFLCRP16
| OflcUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingOflcRating
instance FromText ContentRatingOflcRating where
fromText = \case
"oflcG" -> Just OflcG
"oflcM" -> Just OflcM
"oflcPg" -> Just OflcPg
"oflcR13" -> Just OFLCR13
"oflcR15" -> Just OFLCR15
"oflcR16" -> Just OFLCR16
"oflcR18" -> Just OFLCR18
"oflcRp13" -> Just OFLCRP13
"oflcRp16" -> Just OFLCRP16
"oflcUnrated" -> Just OflcUnrated
_ -> Nothing
instance ToText ContentRatingOflcRating where
toText = \case
OflcG -> "oflcG"
OflcM -> "oflcM"
OflcPg -> "oflcPg"
OFLCR13 -> "oflcR13"
OFLCR15 -> "oflcR15"
OFLCR16 -> "oflcR16"
OFLCR18 -> "oflcR18"
OFLCRP13 -> "oflcRp13"
OFLCRP16 -> "oflcRp16"
OflcUnrated -> "oflcUnrated"
instance FromJSON ContentRatingOflcRating where
parseJSON = parseJSONText "ContentRatingOflcRating"
instance ToJSON ContentRatingOflcRating where
toJSON = toJSONText
data ContentRatingCNCRating
= CNC10
| CNC12
| CNC16
| CNC18
| CNCE
| CNCT
| CNCUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCNCRating
instance FromText ContentRatingCNCRating where
fromText = \case
"cnc10" -> Just CNC10
"cnc12" -> Just CNC12
"cnc16" -> Just CNC16
"cnc18" -> Just CNC18
"cncE" -> Just CNCE
"cncT" -> Just CNCT
"cncUnrated" -> Just CNCUnrated
_ -> Nothing
instance ToText ContentRatingCNCRating where
toText = \case
CNC10 -> "cnc10"
CNC12 -> "cnc12"
CNC16 -> "cnc16"
CNC18 -> "cnc18"
CNCE -> "cncE"
CNCT -> "cncT"
CNCUnrated -> "cncUnrated"
instance FromJSON ContentRatingCNCRating where
parseJSON = parseJSONText "ContentRatingCNCRating"
instance ToJSON ContentRatingCNCRating where
toJSON = toJSONText
data ContentRatingGrfilmRating
= GrfilmE
| GrfilmK
| GRFILMK13
| GRFILMK17
| GrfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingGrfilmRating
instance FromText ContentRatingGrfilmRating where
fromText = \case
"grfilmE" -> Just GrfilmE
"grfilmK" -> Just GrfilmK
"grfilmK13" -> Just GRFILMK13
"grfilmK17" -> Just GRFILMK17
"grfilmUnrated" -> Just GrfilmUnrated
_ -> Nothing
instance ToText ContentRatingGrfilmRating where
toText = \case
GrfilmE -> "grfilmE"
GrfilmK -> "grfilmK"
GRFILMK13 -> "grfilmK13"
GRFILMK17 -> "grfilmK17"
GrfilmUnrated -> "grfilmUnrated"
instance FromJSON ContentRatingGrfilmRating where
parseJSON = parseJSONText "ContentRatingGrfilmRating"
instance ToJSON ContentRatingGrfilmRating where
toJSON = toJSONText
data CommentThreadsListOrder
= CTLORelevance
| CTLOTime
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentThreadsListOrder
instance FromText CommentThreadsListOrder where
fromText = \case
"relevance" -> Just CTLORelevance
"time" -> Just CTLOTime
_ -> Nothing
instance ToText CommentThreadsListOrder where
toText = \case
CTLORelevance -> "relevance"
CTLOTime -> "time"
instance FromJSON CommentThreadsListOrder where
parseJSON = parseJSONText "CommentThreadsListOrder"
instance ToJSON CommentThreadsListOrder where
toJSON = toJSONText
data ContentRatingIlfilmRating
= ILFILM12
| ILFILM16
| ILFILM18
| IlfilmAa
| IlfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingIlfilmRating
instance FromText ContentRatingIlfilmRating where
fromText = \case
"ilfilm12" -> Just ILFILM12
"ilfilm16" -> Just ILFILM16
"ilfilm18" -> Just ILFILM18
"ilfilmAa" -> Just IlfilmAa
"ilfilmUnrated" -> Just IlfilmUnrated
_ -> Nothing
instance ToText ContentRatingIlfilmRating where
toText = \case
ILFILM12 -> "ilfilm12"
ILFILM16 -> "ilfilm16"
ILFILM18 -> "ilfilm18"
IlfilmAa -> "ilfilmAa"
IlfilmUnrated -> "ilfilmUnrated"
instance FromJSON ContentRatingIlfilmRating where
parseJSON = parseJSONText "ContentRatingIlfilmRating"
instance ToJSON ContentRatingIlfilmRating where
toJSON = toJSONText
data ContentRatingNbcplRating
= Nbcpl18plus
| NbcplI
| NbcplIi
| NbcplIii
| NbcplIv
| NbcplUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingNbcplRating
instance FromText ContentRatingNbcplRating where
fromText = \case
"nbcpl18plus" -> Just Nbcpl18plus
"nbcplI" -> Just NbcplI
"nbcplIi" -> Just NbcplIi
"nbcplIii" -> Just NbcplIii
"nbcplIv" -> Just NbcplIv
"nbcplUnrated" -> Just NbcplUnrated
_ -> Nothing
instance ToText ContentRatingNbcplRating where
toText = \case
Nbcpl18plus -> "nbcpl18plus"
NbcplI -> "nbcplI"
NbcplIi -> "nbcplIi"
NbcplIii -> "nbcplIii"
NbcplIv -> "nbcplIv"
NbcplUnrated -> "nbcplUnrated"
instance FromJSON ContentRatingNbcplRating where
parseJSON = parseJSONText "ContentRatingNbcplRating"
instance ToJSON ContentRatingNbcplRating where
toJSON = toJSONText
data VideoStatusUploadStatus
= VSUSDeleted
| VSUSFailed
| VSUSProcessed
| VSUSRejected
| VSUSUploaded
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoStatusUploadStatus
instance FromText VideoStatusUploadStatus where
fromText = \case
"deleted" -> Just VSUSDeleted
"failed" -> Just VSUSFailed
"processed" -> Just VSUSProcessed
"rejected" -> Just VSUSRejected
"uploaded" -> Just VSUSUploaded
_ -> Nothing
instance ToText VideoStatusUploadStatus where
toText = \case
VSUSDeleted -> "deleted"
VSUSFailed -> "failed"
VSUSProcessed -> "processed"
VSUSRejected -> "rejected"
VSUSUploaded -> "uploaded"
instance FromJSON VideoStatusUploadStatus where
parseJSON = parseJSONText "VideoStatusUploadStatus"
instance ToJSON VideoStatusUploadStatus where
toJSON = toJSONText
data ContentRatingRteRating
= RteCh
| RteGa
| RteMa
| RtePs
| RteUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingRteRating
instance FromText ContentRatingRteRating where
fromText = \case
"rteCh" -> Just RteCh
"rteGa" -> Just RteGa
"rteMa" -> Just RteMa
"rtePs" -> Just RtePs
"rteUnrated" -> Just RteUnrated
_ -> Nothing
instance ToText ContentRatingRteRating where
toText = \case
RteCh -> "rteCh"
RteGa -> "rteGa"
RteMa -> "rteMa"
RtePs -> "rtePs"
RteUnrated -> "rteUnrated"
instance FromJSON ContentRatingRteRating where
parseJSON = parseJSONText "ContentRatingRteRating"
instance ToJSON ContentRatingRteRating where
toJSON = toJSONText
data CommentThreadsListTextFormat
= CTLTFHTML
| CTLTFPlainText
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentThreadsListTextFormat
instance FromText CommentThreadsListTextFormat where
fromText = \case
"html" -> Just CTLTFHTML
"plainText" -> Just CTLTFPlainText
_ -> Nothing
instance ToText CommentThreadsListTextFormat where
toText = \case
CTLTFHTML -> "html"
CTLTFPlainText -> "plainText"
instance FromJSON CommentThreadsListTextFormat where
parseJSON = parseJSONText "CommentThreadsListTextFormat"
instance ToJSON CommentThreadsListTextFormat where
toJSON = toJSONText
data ContentRatingIfcoRating
= IFCO12
| Ifco12a
| IFCO15
| Ifco15a
| IFCO16
| IFCO18
| IfcoG
| IfcoPg
| IfcoUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingIfcoRating
instance FromText ContentRatingIfcoRating where
fromText = \case
"ifco12" -> Just IFCO12
"ifco12a" -> Just Ifco12a
"ifco15" -> Just IFCO15
"ifco15a" -> Just Ifco15a
"ifco16" -> Just IFCO16
"ifco18" -> Just IFCO18
"ifcoG" -> Just IfcoG
"ifcoPg" -> Just IfcoPg
"ifcoUnrated" -> Just IfcoUnrated
_ -> Nothing
instance ToText ContentRatingIfcoRating where
toText = \case
IFCO12 -> "ifco12"
Ifco12a -> "ifco12a"
IFCO15 -> "ifco15"
Ifco15a -> "ifco15a"
IFCO16 -> "ifco16"
IFCO18 -> "ifco18"
IfcoG -> "ifcoG"
IfcoPg -> "ifcoPg"
IfcoUnrated -> "ifcoUnrated"
instance FromJSON ContentRatingIfcoRating where
parseJSON = parseJSONText "ContentRatingIfcoRating"
instance ToJSON ContentRatingIfcoRating where
toJSON = toJSONText
data CommentsSetModerationStatusModerationStatus
= CSMSMSHeldForReview
| CSMSMSPublished
| CSMSMSRejected
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentsSetModerationStatusModerationStatus
instance FromText CommentsSetModerationStatusModerationStatus where
fromText = \case
"heldForReview" -> Just CSMSMSHeldForReview
"published" -> Just CSMSMSPublished
"rejected" -> Just CSMSMSRejected
_ -> Nothing
instance ToText CommentsSetModerationStatusModerationStatus where
toText = \case
CSMSMSHeldForReview -> "heldForReview"
CSMSMSPublished -> "published"
CSMSMSRejected -> "rejected"
instance FromJSON CommentsSetModerationStatusModerationStatus where
parseJSON = parseJSONText "CommentsSetModerationStatusModerationStatus"
instance ToJSON CommentsSetModerationStatusModerationStatus where
toJSON = toJSONText
data ActivityContentDetailsSocialType
= ACDSTFacebook
| ACDSTGooglePlus
| ACDSTTwitter
| ACDSTUnspecified
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ActivityContentDetailsSocialType
instance FromText ActivityContentDetailsSocialType where
fromText = \case
"facebook" -> Just ACDSTFacebook
"googlePlus" -> Just ACDSTGooglePlus
"twitter" -> Just ACDSTTwitter
"unspecified" -> Just ACDSTUnspecified
_ -> Nothing
instance ToText ActivityContentDetailsSocialType where
toText = \case
ACDSTFacebook -> "facebook"
ACDSTGooglePlus -> "googlePlus"
ACDSTTwitter -> "twitter"
ACDSTUnspecified -> "unspecified"
instance FromJSON ActivityContentDetailsSocialType where
parseJSON = parseJSONText "ActivityContentDetailsSocialType"
instance ToJSON ActivityContentDetailsSocialType where
toJSON = toJSONText
data ContentRatingMedietilsynetRating
= MEDIETILSYNET11
| MEDIETILSYNET12
| MEDIETILSYNET15
| MEDIETILSYNET18
| MEDIETILSYNET6
| MEDIETILSYNET7
| MEDIETILSYNET9
| MedietilsynetA
| MedietilsynetUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMedietilsynetRating
instance FromText ContentRatingMedietilsynetRating where
fromText = \case
"medietilsynet11" -> Just MEDIETILSYNET11
"medietilsynet12" -> Just MEDIETILSYNET12
"medietilsynet15" -> Just MEDIETILSYNET15
"medietilsynet18" -> Just MEDIETILSYNET18
"medietilsynet6" -> Just MEDIETILSYNET6
"medietilsynet7" -> Just MEDIETILSYNET7
"medietilsynet9" -> Just MEDIETILSYNET9
"medietilsynetA" -> Just MedietilsynetA
"medietilsynetUnrated" -> Just MedietilsynetUnrated
_ -> Nothing
instance ToText ContentRatingMedietilsynetRating where
toText = \case
MEDIETILSYNET11 -> "medietilsynet11"
MEDIETILSYNET12 -> "medietilsynet12"
MEDIETILSYNET15 -> "medietilsynet15"
MEDIETILSYNET18 -> "medietilsynet18"
MEDIETILSYNET6 -> "medietilsynet6"
MEDIETILSYNET7 -> "medietilsynet7"
MEDIETILSYNET9 -> "medietilsynet9"
MedietilsynetA -> "medietilsynetA"
MedietilsynetUnrated -> "medietilsynetUnrated"
instance FromJSON ContentRatingMedietilsynetRating where
parseJSON = parseJSONText "ContentRatingMedietilsynetRating"
instance ToJSON ContentRatingMedietilsynetRating where
toJSON = toJSONText
data PlayListItemStatusPrivacyStatus
= PLISPSPrivate
| PLISPSPublic
| PLISPSUnListed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable PlayListItemStatusPrivacyStatus
instance FromText PlayListItemStatusPrivacyStatus where
fromText = \case
"private" -> Just PLISPSPrivate
"public" -> Just PLISPSPublic
"unlisted" -> Just PLISPSUnListed
_ -> Nothing
instance ToText PlayListItemStatusPrivacyStatus where
toText = \case
PLISPSPrivate -> "private"
PLISPSPublic -> "public"
PLISPSUnListed -> "unlisted"
instance FromJSON PlayListItemStatusPrivacyStatus where
parseJSON = parseJSONText "PlayListItemStatusPrivacyStatus"
instance ToJSON PlayListItemStatusPrivacyStatus where
toJSON = toJSONText
data SubscriptionContentDetailsActivityType
= All
| Uploads
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SubscriptionContentDetailsActivityType
instance FromText SubscriptionContentDetailsActivityType where
fromText = \case
"all" -> Just All
"uploads" -> Just Uploads
_ -> Nothing
instance ToText SubscriptionContentDetailsActivityType where
toText = \case
All -> "all"
Uploads -> "uploads"
instance FromJSON SubscriptionContentDetailsActivityType where
parseJSON = parseJSONText "SubscriptionContentDetailsActivityType"
instance ToJSON SubscriptionContentDetailsActivityType where
toJSON = toJSONText
data ContentRatingFpbRating
= Fpb1012Pg
| FPB13
| FPB16
| FPB18
| Fpb79Pg
| FpbA
| FpbPg
| FpbUnrated
| FPBX18
| FpbXx
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingFpbRating
instance FromText ContentRatingFpbRating where
fromText = \case
"fpb1012Pg" -> Just Fpb1012Pg
"fpb13" -> Just FPB13
"fpb16" -> Just FPB16
"fpb18" -> Just FPB18
"fpb79Pg" -> Just Fpb79Pg
"fpbA" -> Just FpbA
"fpbPg" -> Just FpbPg
"fpbUnrated" -> Just FpbUnrated
"fpbX18" -> Just FPBX18
"fpbXx" -> Just FpbXx
_ -> Nothing
instance ToText ContentRatingFpbRating where
toText = \case
Fpb1012Pg -> "fpb1012Pg"
FPB13 -> "fpb13"
FPB16 -> "fpb16"
FPB18 -> "fpb18"
Fpb79Pg -> "fpb79Pg"
FpbA -> "fpbA"
FpbPg -> "fpbPg"
FpbUnrated -> "fpbUnrated"
FPBX18 -> "fpbX18"
FpbXx -> "fpbXx"
instance FromJSON ContentRatingFpbRating where
parseJSON = parseJSONText "ContentRatingFpbRating"
instance ToJSON ContentRatingFpbRating where
toJSON = toJSONText
data SearchListVideoDimension
= S2D
| S3D
| SAny
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoDimension
instance FromText SearchListVideoDimension where
fromText = \case
"2d" -> Just S2D
"3d" -> Just S3D
"any" -> Just SAny
_ -> Nothing
instance ToText SearchListVideoDimension where
toText = \case
S2D -> "2d"
S3D -> "3d"
SAny -> "any"
instance FromJSON SearchListVideoDimension where
parseJSON = parseJSONText "SearchListVideoDimension"
instance ToJSON SearchListVideoDimension where
toJSON = toJSONText
data ContentRatingNkclvRating
= Nkclv12plus
| Nkclv18plus
| Nkclv7plus
| NkclvU
| NkclvUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingNkclvRating
instance FromText ContentRatingNkclvRating where
fromText = \case
"nkclv12plus" -> Just Nkclv12plus
"nkclv18plus" -> Just Nkclv18plus
"nkclv7plus" -> Just Nkclv7plus
"nkclvU" -> Just NkclvU
"nkclvUnrated" -> Just NkclvUnrated
_ -> Nothing
instance ToText ContentRatingNkclvRating where
toText = \case
Nkclv12plus -> "nkclv12plus"
Nkclv18plus -> "nkclv18plus"
Nkclv7plus -> "nkclv7plus"
NkclvU -> "nkclvU"
NkclvUnrated -> "nkclvUnrated"
instance FromJSON ContentRatingNkclvRating where
parseJSON = parseJSONText "ContentRatingNkclvRating"
instance ToJSON ContentRatingNkclvRating where
toJSON = toJSONText
data SearchListVideoType
= SLVTAny
| SLVTEpisode
| SLVTMovie
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoType
instance FromText SearchListVideoType where
fromText = \case
"any" -> Just SLVTAny
"episode" -> Just SLVTEpisode
"movie" -> Just SLVTMovie
_ -> Nothing
instance ToText SearchListVideoType where
toText = \case
SLVTAny -> "any"
SLVTEpisode -> "episode"
SLVTMovie -> "movie"
instance FromJSON SearchListVideoType where
parseJSON = parseJSONText "SearchListVideoType"
instance ToJSON SearchListVideoType where
toJSON = toJSONText
data ContentRatingMibacRating
= MibacT
| MibacUnrated
| MibacVap
| MIBACVM12
| MIBACVM14
| MIBACVM18
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMibacRating
instance FromText ContentRatingMibacRating where
fromText = \case
"mibacT" -> Just MibacT
"mibacUnrated" -> Just MibacUnrated
"mibacVap" -> Just MibacVap
"mibacVm12" -> Just MIBACVM12
"mibacVm14" -> Just MIBACVM14
"mibacVm18" -> Just MIBACVM18
_ -> Nothing
instance ToText ContentRatingMibacRating where
toText = \case
MibacT -> "mibacT"
MibacUnrated -> "mibacUnrated"
MibacVap -> "mibacVap"
MIBACVM12 -> "mibacVm12"
MIBACVM14 -> "mibacVm14"
MIBACVM18 -> "mibacVm18"
instance FromJSON ContentRatingMibacRating where
parseJSON = parseJSONText "ContentRatingMibacRating"
instance ToJSON ContentRatingMibacRating where
toJSON = toJSONText
data ContentRatingResorteviolenciaRating
= ResorteviolenciaA
| ResorteviolenciaB
| ResorteviolenciaC
| ResorteviolenciaD
| ResorteviolenciaE
| ResorteviolenciaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingResorteviolenciaRating
instance FromText ContentRatingResorteviolenciaRating where
fromText = \case
"resorteviolenciaA" -> Just ResorteviolenciaA
"resorteviolenciaB" -> Just ResorteviolenciaB
"resorteviolenciaC" -> Just ResorteviolenciaC
"resorteviolenciaD" -> Just ResorteviolenciaD
"resorteviolenciaE" -> Just ResorteviolenciaE
"resorteviolenciaUnrated" -> Just ResorteviolenciaUnrated
_ -> Nothing
instance ToText ContentRatingResorteviolenciaRating where
toText = \case
ResorteviolenciaA -> "resorteviolenciaA"
ResorteviolenciaB -> "resorteviolenciaB"
ResorteviolenciaC -> "resorteviolenciaC"
ResorteviolenciaD -> "resorteviolenciaD"
ResorteviolenciaE -> "resorteviolenciaE"
ResorteviolenciaUnrated -> "resorteviolenciaUnrated"
instance FromJSON ContentRatingResorteviolenciaRating where
parseJSON = parseJSONText "ContentRatingResorteviolenciaRating"
instance ToJSON ContentRatingResorteviolenciaRating where
toJSON = toJSONText
data ContentRatingEgfilmRating
= EGFILM18
| EgfilmBn
| EgfilmGn
| EgfilmUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingEgfilmRating
instance FromText ContentRatingEgfilmRating where
fromText = \case
"egfilm18" -> Just EGFILM18
"egfilmBn" -> Just EgfilmBn
"egfilmGn" -> Just EgfilmGn
"egfilmUnrated" -> Just EgfilmUnrated
_ -> Nothing
instance ToText ContentRatingEgfilmRating where
toText = \case
EGFILM18 -> "egfilm18"
EgfilmBn -> "egfilmBn"
EgfilmGn -> "egfilmGn"
EgfilmUnrated -> "egfilmUnrated"
instance FromJSON ContentRatingEgfilmRating where
parseJSON = parseJSONText "ContentRatingEgfilmRating"
instance ToJSON ContentRatingEgfilmRating where
toJSON = toJSONText
data ContentRatingMccypRating
= MCCYP11
| MCCYP15
| MCCYP7
| MccypA
| MccypUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMccypRating
instance FromText ContentRatingMccypRating where
fromText = \case
"mccyp11" -> Just MCCYP11
"mccyp15" -> Just MCCYP15
"mccyp7" -> Just MCCYP7
"mccypA" -> Just MccypA
"mccypUnrated" -> Just MccypUnrated
_ -> Nothing
instance ToText ContentRatingMccypRating where
toText = \case
MCCYP11 -> "mccyp11"
MCCYP15 -> "mccyp15"
MCCYP7 -> "mccyp7"
MccypA -> "mccypA"
MccypUnrated -> "mccypUnrated"
instance FromJSON ContentRatingMccypRating where
parseJSON = parseJSONText "ContentRatingMccypRating"
instance ToJSON ContentRatingMccypRating where
toJSON = toJSONText
data PlayListStatusPrivacyStatus
= PLSPSPrivate
| PLSPSPublic
| PLSPSUnListed
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable PlayListStatusPrivacyStatus
instance FromText PlayListStatusPrivacyStatus where
fromText = \case
"private" -> Just PLSPSPrivate
"public" -> Just PLSPSPublic
"unlisted" -> Just PLSPSUnListed
_ -> Nothing
instance ToText PlayListStatusPrivacyStatus where
toText = \case
PLSPSPrivate -> "private"
PLSPSPublic -> "public"
PLSPSUnListed -> "unlisted"
instance FromJSON PlayListStatusPrivacyStatus where
parseJSON = parseJSONText "PlayListStatusPrivacyStatus"
instance ToJSON PlayListStatusPrivacyStatus where
toJSON = toJSONText
data ContentRatingCsaRating
= CSA10
| CSA12
| CSA16
| CSA18
| CsaInterdiction
| CsaT
| CsaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCsaRating
instance FromText ContentRatingCsaRating where
fromText = \case
"csa10" -> Just CSA10
"csa12" -> Just CSA12
"csa16" -> Just CSA16
"csa18" -> Just CSA18
"csaInterdiction" -> Just CsaInterdiction
"csaT" -> Just CsaT
"csaUnrated" -> Just CsaUnrated
_ -> Nothing
instance ToText ContentRatingCsaRating where
toText = \case
CSA10 -> "csa10"
CSA12 -> "csa12"
CSA16 -> "csa16"
CSA18 -> "csa18"
CsaInterdiction -> "csaInterdiction"
CsaT -> "csaT"
CsaUnrated -> "csaUnrated"
instance FromJSON ContentRatingCsaRating where
parseJSON = parseJSONText "ContentRatingCsaRating"
instance ToJSON ContentRatingCsaRating where
toJSON = toJSONText
data ChannelSectionSnippetStyle
= ChannelsectionStyleUndefined
| HorizontalRow
| VerticalList
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ChannelSectionSnippetStyle
instance FromText ChannelSectionSnippetStyle where
fromText = \case
"channelsectionStyleUndefined" -> Just ChannelsectionStyleUndefined
"horizontalRow" -> Just HorizontalRow
"verticalList" -> Just VerticalList
_ -> Nothing
instance ToText ChannelSectionSnippetStyle where
toText = \case
ChannelsectionStyleUndefined -> "channelsectionStyleUndefined"
HorizontalRow -> "horizontalRow"
VerticalList -> "verticalList"
instance FromJSON ChannelSectionSnippetStyle where
parseJSON = parseJSONText "ChannelSectionSnippetStyle"
instance ToJSON ChannelSectionSnippetStyle where
toJSON = toJSONText
data ContentRatingEirinRating
= EirinG
| EIRINPG12
| EirinR15plus
| EirinR18plus
| EirinUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingEirinRating
instance FromText ContentRatingEirinRating where
fromText = \case
"eirinG" -> Just EirinG
"eirinPg12" -> Just EIRINPG12
"eirinR15plus" -> Just EirinR15plus
"eirinR18plus" -> Just EirinR18plus
"eirinUnrated" -> Just EirinUnrated
_ -> Nothing
instance ToText ContentRatingEirinRating where
toText = \case
EirinG -> "eirinG"
EIRINPG12 -> "eirinPg12"
EirinR15plus -> "eirinR15plus"
EirinR18plus -> "eirinR18plus"
EirinUnrated -> "eirinUnrated"
instance FromJSON ContentRatingEirinRating where
parseJSON = parseJSONText "ContentRatingEirinRating"
instance ToJSON ContentRatingEirinRating where
toJSON = toJSONText
data VideoSuggestionsProcessingHintsItem
= NonStreamableMov
| SendBestQualityVideo
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoSuggestionsProcessingHintsItem
instance FromText VideoSuggestionsProcessingHintsItem where
fromText = \case
"nonStreamableMov" -> Just NonStreamableMov
"sendBestQualityVideo" -> Just SendBestQualityVideo
_ -> Nothing
instance ToText VideoSuggestionsProcessingHintsItem where
toText = \case
NonStreamableMov -> "nonStreamableMov"
SendBestQualityVideo -> "sendBestQualityVideo"
instance FromJSON VideoSuggestionsProcessingHintsItem where
parseJSON = parseJSONText "VideoSuggestionsProcessingHintsItem"
instance ToJSON VideoSuggestionsProcessingHintsItem where
toJSON = toJSONText
data ContentRatingNfrcRating
= NfrcA
| NfrcB
| NfrcC
| NfrcD
| NfrcUnrated
| NfrcX
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingNfrcRating
instance FromText ContentRatingNfrcRating where
fromText = \case
"nfrcA" -> Just NfrcA
"nfrcB" -> Just NfrcB
"nfrcC" -> Just NfrcC
"nfrcD" -> Just NfrcD
"nfrcUnrated" -> Just NfrcUnrated
"nfrcX" -> Just NfrcX
_ -> Nothing
instance ToText ContentRatingNfrcRating where
toText = \case
NfrcA -> "nfrcA"
NfrcB -> "nfrcB"
NfrcC -> "nfrcC"
NfrcD -> "nfrcD"
NfrcUnrated -> "nfrcUnrated"
NfrcX -> "nfrcX"
instance FromJSON ContentRatingNfrcRating where
parseJSON = parseJSONText "ContentRatingNfrcRating"
instance ToJSON ContentRatingNfrcRating where
toJSON = toJSONText
data ActivitySnippetType
= ASTBulletin
| ASTChannelItem
| ASTComment
| ASTFavorite
| ASTLike
| ASTPlayListItem
| ASTPromotedItem
| ASTRecommendation
| ASTSocial
| ASTSubscription
| ASTUpload
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ActivitySnippetType
instance FromText ActivitySnippetType where
fromText = \case
"bulletin" -> Just ASTBulletin
"channelItem" -> Just ASTChannelItem
"comment" -> Just ASTComment
"favorite" -> Just ASTFavorite
"like" -> Just ASTLike
"playlistItem" -> Just ASTPlayListItem
"promotedItem" -> Just ASTPromotedItem
"recommendation" -> Just ASTRecommendation
"social" -> Just ASTSocial
"subscription" -> Just ASTSubscription
"upload" -> Just ASTUpload
_ -> Nothing
instance ToText ActivitySnippetType where
toText = \case
ASTBulletin -> "bulletin"
ASTChannelItem -> "channelItem"
ASTComment -> "comment"
ASTFavorite -> "favorite"
ASTLike -> "like"
ASTPlayListItem -> "playlistItem"
ASTPromotedItem -> "promotedItem"
ASTRecommendation -> "recommendation"
ASTSocial -> "social"
ASTSubscription -> "subscription"
ASTUpload -> "upload"
instance FromJSON ActivitySnippetType where
parseJSON = parseJSONText "ActivitySnippetType"
instance ToJSON ActivitySnippetType where
toJSON = toJSONText
data ContentRatingMocRating
= MOC12
| MOC15
| MOC18
| MOC7
| MocBanned
| MocE
| MocT
| MocUnrated
| MocX
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMocRating
instance FromText ContentRatingMocRating where
fromText = \case
"moc12" -> Just MOC12
"moc15" -> Just MOC15
"moc18" -> Just MOC18
"moc7" -> Just MOC7
"mocBanned" -> Just MocBanned
"mocE" -> Just MocE
"mocT" -> Just MocT
"mocUnrated" -> Just MocUnrated
"mocX" -> Just MocX
_ -> Nothing
instance ToText ContentRatingMocRating where
toText = \case
MOC12 -> "moc12"
MOC15 -> "moc15"
MOC18 -> "moc18"
MOC7 -> "moc7"
MocBanned -> "mocBanned"
MocE -> "mocE"
MocT -> "mocT"
MocUnrated -> "mocUnrated"
MocX -> "mocX"
instance FromJSON ContentRatingMocRating where
parseJSON = parseJSONText "ContentRatingMocRating"
instance ToJSON ContentRatingMocRating where
toJSON = toJSONText
data SearchListVideoEmbeddable
= SLVEAny
| SLVETrue'
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoEmbeddable
instance FromText SearchListVideoEmbeddable where
fromText = \case
"any" -> Just SLVEAny
"true" -> Just SLVETrue'
_ -> Nothing
instance ToText SearchListVideoEmbeddable where
toText = \case
SLVEAny -> "any"
SLVETrue' -> "true"
instance FromJSON SearchListVideoEmbeddable where
parseJSON = parseJSONText "SearchListVideoEmbeddable"
instance ToJSON SearchListVideoEmbeddable where
toJSON = toJSONText
data SearchListEventType
= SLETCompleted
| SLETLive
| SLETUpcoming
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListEventType
instance FromText SearchListEventType where
fromText = \case
"completed" -> Just SLETCompleted
"live" -> Just SLETLive
"upcoming" -> Just SLETUpcoming
_ -> Nothing
instance ToText SearchListEventType where
toText = \case
SLETCompleted -> "completed"
SLETLive -> "live"
SLETUpcoming -> "upcoming"
instance FromJSON SearchListEventType where
parseJSON = parseJSONText "SearchListEventType"
instance ToJSON SearchListEventType where
toJSON = toJSONText
data ActivityContentDetailsRecommendationReason
= ACDRRUnspecified
| ACDRRVideoFavorited
| ACDRRVideoLiked
| ACDRRVideoWatched
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ActivityContentDetailsRecommendationReason
instance FromText ActivityContentDetailsRecommendationReason where
fromText = \case
"unspecified" -> Just ACDRRUnspecified
"videoFavorited" -> Just ACDRRVideoFavorited
"videoLiked" -> Just ACDRRVideoLiked
"videoWatched" -> Just ACDRRVideoWatched
_ -> Nothing
instance ToText ActivityContentDetailsRecommendationReason where
toText = \case
ACDRRUnspecified -> "unspecified"
ACDRRVideoFavorited -> "videoFavorited"
ACDRRVideoLiked -> "videoLiked"
ACDRRVideoWatched -> "videoWatched"
instance FromJSON ActivityContentDetailsRecommendationReason where
parseJSON = parseJSONText "ActivityContentDetailsRecommendationReason"
instance ToJSON ActivityContentDetailsRecommendationReason where
toJSON = toJSONText
data ContentRatingKijkwijzerRating
= KIJKWIJZER12
| KIJKWIJZER16
| KIJKWIJZER18
| KIJKWIJZER6
| KIJKWIJZER9
| KijkwijzerAl
| KijkwijzerUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingKijkwijzerRating
instance FromText ContentRatingKijkwijzerRating where
fromText = \case
"kijkwijzer12" -> Just KIJKWIJZER12
"kijkwijzer16" -> Just KIJKWIJZER16
"kijkwijzer18" -> Just KIJKWIJZER18
"kijkwijzer6" -> Just KIJKWIJZER6
"kijkwijzer9" -> Just KIJKWIJZER9
"kijkwijzerAl" -> Just KijkwijzerAl
"kijkwijzerUnrated" -> Just KijkwijzerUnrated
_ -> Nothing
instance ToText ContentRatingKijkwijzerRating where
toText = \case
KIJKWIJZER12 -> "kijkwijzer12"
KIJKWIJZER16 -> "kijkwijzer16"
KIJKWIJZER18 -> "kijkwijzer18"
KIJKWIJZER6 -> "kijkwijzer6"
KIJKWIJZER9 -> "kijkwijzer9"
KijkwijzerAl -> "kijkwijzerAl"
KijkwijzerUnrated -> "kijkwijzerUnrated"
instance FromJSON ContentRatingKijkwijzerRating where
parseJSON = parseJSONText "ContentRatingKijkwijzerRating"
instance ToJSON ContentRatingKijkwijzerRating where
toJSON = toJSONText
data VideoSuggestionsProcessingErrorsItem
= ArchiveFile
| AudioFile
| DocFile
| ImageFile
| NotAVideoFile
| ProjectFile
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoSuggestionsProcessingErrorsItem
instance FromText VideoSuggestionsProcessingErrorsItem where
fromText = \case
"archiveFile" -> Just ArchiveFile
"audioFile" -> Just AudioFile
"docFile" -> Just DocFile
"imageFile" -> Just ImageFile
"notAVideoFile" -> Just NotAVideoFile
"projectFile" -> Just ProjectFile
_ -> Nothing
instance ToText VideoSuggestionsProcessingErrorsItem where
toText = \case
ArchiveFile -> "archiveFile"
AudioFile -> "audioFile"
DocFile -> "docFile"
ImageFile -> "imageFile"
NotAVideoFile -> "notAVideoFile"
ProjectFile -> "projectFile"
instance FromJSON VideoSuggestionsProcessingErrorsItem where
parseJSON = parseJSONText "VideoSuggestionsProcessingErrorsItem"
instance ToJSON VideoSuggestionsProcessingErrorsItem where
toJSON = toJSONText
data VideoFileDetailsFileType
= VFDFTArchive
| VFDFTAudio
| VFDFTDocument
| VFDFTImage
| VFDFTOther
| VFDFTProject
| VFDFTVideo
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoFileDetailsFileType
instance FromText VideoFileDetailsFileType where
fromText = \case
"archive" -> Just VFDFTArchive
"audio" -> Just VFDFTAudio
"document" -> Just VFDFTDocument
"image" -> Just VFDFTImage
"other" -> Just VFDFTOther
"project" -> Just VFDFTProject
"video" -> Just VFDFTVideo
_ -> Nothing
instance ToText VideoFileDetailsFileType where
toText = \case
VFDFTArchive -> "archive"
VFDFTAudio -> "audio"
VFDFTDocument -> "document"
VFDFTImage -> "image"
VFDFTOther -> "other"
VFDFTProject -> "project"
VFDFTVideo -> "video"
instance FromJSON VideoFileDetailsFileType where
parseJSON = parseJSONText "VideoFileDetailsFileType"
instance ToJSON VideoFileDetailsFileType where
toJSON = toJSONText
data ContentRatingMtrcbRating
= MtrcbG
| MtrcbPg
| MTRCBR13
| MTRCBR16
| MTRCBR18
| MtrcbUnrated
| MtrcbX
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMtrcbRating
instance FromText ContentRatingMtrcbRating where
fromText = \case
"mtrcbG" -> Just MtrcbG
"mtrcbPg" -> Just MtrcbPg
"mtrcbR13" -> Just MTRCBR13
"mtrcbR16" -> Just MTRCBR16
"mtrcbR18" -> Just MTRCBR18
"mtrcbUnrated" -> Just MtrcbUnrated
"mtrcbX" -> Just MtrcbX
_ -> Nothing
instance ToText ContentRatingMtrcbRating where
toText = \case
MtrcbG -> "mtrcbG"
MtrcbPg -> "mtrcbPg"
MTRCBR13 -> "mtrcbR13"
MTRCBR16 -> "mtrcbR16"
MTRCBR18 -> "mtrcbR18"
MtrcbUnrated -> "mtrcbUnrated"
MtrcbX -> "mtrcbX"
instance FromJSON ContentRatingMtrcbRating where
parseJSON = parseJSONText "ContentRatingMtrcbRating"
instance ToJSON ContentRatingMtrcbRating where
toJSON = toJSONText
data ContentRatingFcoRating
= FcoI
| FcoIi
| FcoIia
| FcoIib
| FcoIii
| FcoUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingFcoRating
instance FromText ContentRatingFcoRating where
fromText = \case
"fcoI" -> Just FcoI
"fcoIi" -> Just FcoIi
"fcoIia" -> Just FcoIia
"fcoIib" -> Just FcoIib
"fcoIii" -> Just FcoIii
"fcoUnrated" -> Just FcoUnrated
_ -> Nothing
instance ToText ContentRatingFcoRating where
toText = \case
FcoI -> "fcoI"
FcoIi -> "fcoIi"
FcoIia -> "fcoIia"
FcoIib -> "fcoIib"
FcoIii -> "fcoIii"
FcoUnrated -> "fcoUnrated"
instance FromJSON ContentRatingFcoRating where
parseJSON = parseJSONText "ContentRatingFcoRating"
instance ToJSON ContentRatingFcoRating where
toJSON = toJSONText
data LiveStreamConfigurationIssueType
= AudioBitrateHigh
| AudioBitrateLow
| AudioBitrateMismatch
| AudioCodec
| AudioCodecMismatch
| AudioSampleRate
| AudioSampleRateMismatch
| AudioStereoMismatch
| AudioTooManyChannels
| BadContainer
| BitrateHigh
| BitrateLow
| FrameRateHigh
| FramerateMismatch
| GopMismatch
| GopSizeLong
| GopSizeOver
| GopSizeShort
| InterlacedVideo
| MultipleAudioStreams
| MultipleVideoStreams
| NoAudioStream
| NoVideoStream
| OpenGop
| ResolutionMismatch
| VideoBitrateMismatch
| VideoCodec
| VideoCodecMismatch
| VideoIngestionStarved
| VideoInterlaceMismatch
| VideoProFileMismatch
| VideoResolutionSuboptimal
| VideoResolutionUnsupported
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveStreamConfigurationIssueType
instance FromText LiveStreamConfigurationIssueType where
fromText = \case
"audioBitrateHigh" -> Just AudioBitrateHigh
"audioBitrateLow" -> Just AudioBitrateLow
"audioBitrateMismatch" -> Just AudioBitrateMismatch
"audioCodec" -> Just AudioCodec
"audioCodecMismatch" -> Just AudioCodecMismatch
"audioSampleRate" -> Just AudioSampleRate
"audioSampleRateMismatch" -> Just AudioSampleRateMismatch
"audioStereoMismatch" -> Just AudioStereoMismatch
"audioTooManyChannels" -> Just AudioTooManyChannels
"badContainer" -> Just BadContainer
"bitrateHigh" -> Just BitrateHigh
"bitrateLow" -> Just BitrateLow
"frameRateHigh" -> Just FrameRateHigh
"framerateMismatch" -> Just FramerateMismatch
"gopMismatch" -> Just GopMismatch
"gopSizeLong" -> Just GopSizeLong
"gopSizeOver" -> Just GopSizeOver
"gopSizeShort" -> Just GopSizeShort
"interlacedVideo" -> Just InterlacedVideo
"multipleAudioStreams" -> Just MultipleAudioStreams
"multipleVideoStreams" -> Just MultipleVideoStreams
"noAudioStream" -> Just NoAudioStream
"noVideoStream" -> Just NoVideoStream
"openGop" -> Just OpenGop
"resolutionMismatch" -> Just ResolutionMismatch
"videoBitrateMismatch" -> Just VideoBitrateMismatch
"videoCodec" -> Just VideoCodec
"videoCodecMismatch" -> Just VideoCodecMismatch
"videoIngestionStarved" -> Just VideoIngestionStarved
"videoInterlaceMismatch" -> Just VideoInterlaceMismatch
"videoProfileMismatch" -> Just VideoProFileMismatch
"videoResolutionSuboptimal" -> Just VideoResolutionSuboptimal
"videoResolutionUnsupported" -> Just VideoResolutionUnsupported
_ -> Nothing
instance ToText LiveStreamConfigurationIssueType where
toText = \case
AudioBitrateHigh -> "audioBitrateHigh"
AudioBitrateLow -> "audioBitrateLow"
AudioBitrateMismatch -> "audioBitrateMismatch"
AudioCodec -> "audioCodec"
AudioCodecMismatch -> "audioCodecMismatch"
AudioSampleRate -> "audioSampleRate"
AudioSampleRateMismatch -> "audioSampleRateMismatch"
AudioStereoMismatch -> "audioStereoMismatch"
AudioTooManyChannels -> "audioTooManyChannels"
BadContainer -> "badContainer"
BitrateHigh -> "bitrateHigh"
BitrateLow -> "bitrateLow"
FrameRateHigh -> "frameRateHigh"
FramerateMismatch -> "framerateMismatch"
GopMismatch -> "gopMismatch"
GopSizeLong -> "gopSizeLong"
GopSizeOver -> "gopSizeOver"
GopSizeShort -> "gopSizeShort"
InterlacedVideo -> "interlacedVideo"
MultipleAudioStreams -> "multipleAudioStreams"
MultipleVideoStreams -> "multipleVideoStreams"
NoAudioStream -> "noAudioStream"
NoVideoStream -> "noVideoStream"
OpenGop -> "openGop"
ResolutionMismatch -> "resolutionMismatch"
VideoBitrateMismatch -> "videoBitrateMismatch"
VideoCodec -> "videoCodec"
VideoCodecMismatch -> "videoCodecMismatch"
VideoIngestionStarved -> "videoIngestionStarved"
VideoInterlaceMismatch -> "videoInterlaceMismatch"
VideoProFileMismatch -> "videoProfileMismatch"
VideoResolutionSuboptimal -> "videoResolutionSuboptimal"
VideoResolutionUnsupported -> "videoResolutionUnsupported"
instance FromJSON LiveStreamConfigurationIssueType where
parseJSON = parseJSONText "LiveStreamConfigurationIssueType"
instance ToJSON LiveStreamConfigurationIssueType where
toJSON = toJSONText
data SearchListSafeSearch
= SLSSModerate
| SLSSNone
| SLSSStrict
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListSafeSearch
instance FromText SearchListSafeSearch where
fromText = \case
"moderate" -> Just SLSSModerate
"none" -> Just SLSSNone
"strict" -> Just SLSSStrict
_ -> Nothing
instance ToText SearchListSafeSearch where
toText = \case
SLSSModerate -> "moderate"
SLSSNone -> "none"
SLSSStrict -> "strict"
instance FromJSON SearchListSafeSearch where
parseJSON = parseJSONText "SearchListSafeSearch"
instance ToJSON SearchListSafeSearch where
toJSON = toJSONText
data SearchListVideoSyndicated
= SLVSAny
| SLVSTrue'
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoSyndicated
instance FromText SearchListVideoSyndicated where
fromText = \case
"any" -> Just SLVSAny
"true" -> Just SLVSTrue'
_ -> Nothing
instance ToText SearchListVideoSyndicated where
toText = \case
SLVSAny -> "any"
SLVSTrue' -> "true"
instance FromJSON SearchListVideoSyndicated where
parseJSON = parseJSONText "SearchListVideoSyndicated"
instance ToJSON SearchListVideoSyndicated where
toJSON = toJSONText
data ContentRatingDjctqRatingReasonsItem
= DjctqCriminalActs
| DjctqDrugs
| DjctqExplicitSex
| DjctqExtremeViolence
| DjctqIllegalDrugs
| DjctqImpactingContent
| DjctqInAppropriateLanguage
| DjctqLegalDrugs
| DjctqNudity
| DjctqSex
| DjctqSexualContent
| DjctqViolence
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingDjctqRatingReasonsItem
instance FromText ContentRatingDjctqRatingReasonsItem where
fromText = \case
"djctqCriminalActs" -> Just DjctqCriminalActs
"djctqDrugs" -> Just DjctqDrugs
"djctqExplicitSex" -> Just DjctqExplicitSex
"djctqExtremeViolence" -> Just DjctqExtremeViolence
"djctqIllegalDrugs" -> Just DjctqIllegalDrugs
"djctqImpactingContent" -> Just DjctqImpactingContent
"djctqInappropriateLanguage" -> Just DjctqInAppropriateLanguage
"djctqLegalDrugs" -> Just DjctqLegalDrugs
"djctqNudity" -> Just DjctqNudity
"djctqSex" -> Just DjctqSex
"djctqSexualContent" -> Just DjctqSexualContent
"djctqViolence" -> Just DjctqViolence
_ -> Nothing
instance ToText ContentRatingDjctqRatingReasonsItem where
toText = \case
DjctqCriminalActs -> "djctqCriminalActs"
DjctqDrugs -> "djctqDrugs"
DjctqExplicitSex -> "djctqExplicitSex"
DjctqExtremeViolence -> "djctqExtremeViolence"
DjctqIllegalDrugs -> "djctqIllegalDrugs"
DjctqImpactingContent -> "djctqImpactingContent"
DjctqInAppropriateLanguage -> "djctqInappropriateLanguage"
DjctqLegalDrugs -> "djctqLegalDrugs"
DjctqNudity -> "djctqNudity"
DjctqSex -> "djctqSex"
DjctqSexualContent -> "djctqSexualContent"
DjctqViolence -> "djctqViolence"
instance FromJSON ContentRatingDjctqRatingReasonsItem where
parseJSON = parseJSONText "ContentRatingDjctqRatingReasonsItem"
instance ToJSON ContentRatingDjctqRatingReasonsItem where
toJSON = toJSONText
data CdnSettingsIngestionType
= Dash
| Rtmp
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CdnSettingsIngestionType
instance FromText CdnSettingsIngestionType where
fromText = \case
"dash" -> Just Dash
"rtmp" -> Just Rtmp
_ -> Nothing
instance ToText CdnSettingsIngestionType where
toText = \case
Dash -> "dash"
Rtmp -> "rtmp"
instance FromJSON CdnSettingsIngestionType where
parseJSON = parseJSONText "CdnSettingsIngestionType"
instance ToJSON CdnSettingsIngestionType where
toJSON = toJSONText
data InvideoTimingType
= OffSetFromEnd
| OffSetFromStart
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable InvideoTimingType
instance FromText InvideoTimingType where
fromText = \case
"offsetFromEnd" -> Just OffSetFromEnd
"offsetFromStart" -> Just OffSetFromStart
_ -> Nothing
instance ToText InvideoTimingType where
toText = \case
OffSetFromEnd -> "offsetFromEnd"
OffSetFromStart -> "offsetFromStart"
instance FromJSON InvideoTimingType where
parseJSON = parseJSONText "InvideoTimingType"
instance ToJSON InvideoTimingType where
toJSON = toJSONText
data ContentRatingAgcomRating
= AgcomT
| AgcomUnrated
| AGCOMVM14
| AGCOMVM18
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingAgcomRating
instance FromText ContentRatingAgcomRating where
fromText = \case
"agcomT" -> Just AgcomT
"agcomUnrated" -> Just AgcomUnrated
"agcomVm14" -> Just AGCOMVM14
"agcomVm18" -> Just AGCOMVM18
_ -> Nothing
instance ToText ContentRatingAgcomRating where
toText = \case
AgcomT -> "agcomT"
AgcomUnrated -> "agcomUnrated"
AGCOMVM14 -> "agcomVm14"
AGCOMVM18 -> "agcomVm18"
instance FromJSON ContentRatingAgcomRating where
parseJSON = parseJSONText "ContentRatingAgcomRating"
instance ToJSON ContentRatingAgcomRating where
toJSON = toJSONText
data VideoConversionPingContext
= VCPCComment
| VCPCDislike
| VCPCLike
| VCPCShare
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoConversionPingContext
instance FromText VideoConversionPingContext where
fromText = \case
"comment" -> Just VCPCComment
"dislike" -> Just VCPCDislike
"like" -> Just VCPCLike
"share" -> Just VCPCShare
_ -> Nothing
instance ToText VideoConversionPingContext where
toText = \case
VCPCComment -> "comment"
VCPCDislike -> "dislike"
VCPCLike -> "like"
VCPCShare -> "share"
instance FromJSON VideoConversionPingContext where
parseJSON = parseJSONText "VideoConversionPingContext"
instance ToJSON VideoConversionPingContext where
toJSON = toJSONText
data CommentSnippetModerationStatus
= CSMSHeldForReview
| CSMSLikelySpam
| CSMSPublished
| CSMSRejected
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable CommentSnippetModerationStatus
instance FromText CommentSnippetModerationStatus where
fromText = \case
"heldForReview" -> Just CSMSHeldForReview
"likelySpam" -> Just CSMSLikelySpam
"published" -> Just CSMSPublished
"rejected" -> Just CSMSRejected
_ -> Nothing
instance ToText CommentSnippetModerationStatus where
toText = \case
CSMSHeldForReview -> "heldForReview"
CSMSLikelySpam -> "likelySpam"
CSMSPublished -> "published"
CSMSRejected -> "rejected"
instance FromJSON CommentSnippetModerationStatus where
parseJSON = parseJSONText "CommentSnippetModerationStatus"
instance ToJSON CommentSnippetModerationStatus where
toJSON = toJSONText
data SearchListVideoLicense
= SLVLAny
| SLVLCreativeCommon
| SLVLYouTube
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable SearchListVideoLicense
instance FromText SearchListVideoLicense where
fromText = \case
"any" -> Just SLVLAny
"creativeCommon" -> Just SLVLCreativeCommon
"youtube" -> Just SLVLYouTube
_ -> Nothing
instance ToText SearchListVideoLicense where
toText = \case
SLVLAny -> "any"
SLVLCreativeCommon -> "creativeCommon"
SLVLYouTube -> "youtube"
instance FromJSON SearchListVideoLicense where
parseJSON = parseJSONText "SearchListVideoLicense"
instance ToJSON SearchListVideoLicense where
toJSON = toJSONText
data LiveStreamStatusStreamStatus
= LSSSSActive
| LSSSSCreated
| LSSSSError'
| LSSSSInactive
| LSSSSReady
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable LiveStreamStatusStreamStatus
instance FromText LiveStreamStatusStreamStatus where
fromText = \case
"active" -> Just LSSSSActive
"created" -> Just LSSSSCreated
"error" -> Just LSSSSError'
"inactive" -> Just LSSSSInactive
"ready" -> Just LSSSSReady
_ -> Nothing
instance ToText LiveStreamStatusStreamStatus where
toText = \case
LSSSSActive -> "active"
LSSSSCreated -> "created"
LSSSSError' -> "error"
LSSSSInactive -> "inactive"
LSSSSReady -> "ready"
instance FromJSON LiveStreamStatusStreamStatus where
parseJSON = parseJSONText "LiveStreamStatusStreamStatus"
instance ToJSON LiveStreamStatusStreamStatus where
toJSON = toJSONText
data VideoStatusLicense
= CreativeCommon
| YouTube
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoStatusLicense
instance FromText VideoStatusLicense where
fromText = \case
"creativeCommon" -> Just CreativeCommon
"youtube" -> Just YouTube
_ -> Nothing
instance ToText VideoStatusLicense where
toText = \case
CreativeCommon -> "creativeCommon"
YouTube -> "youtube"
instance FromJSON VideoStatusLicense where
parseJSON = parseJSONText "VideoStatusLicense"
instance ToJSON VideoStatusLicense where
toJSON = toJSONText
data ContentRatingNfvcbRating
= NFVCB12
| Nfvcb12a
| NFVCB15
| NFVCB18
| NfvcbG
| NfvcbPg
| NfvcbRe
| NfvcbUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingNfvcbRating
instance FromText ContentRatingNfvcbRating where
fromText = \case
"nfvcb12" -> Just NFVCB12
"nfvcb12a" -> Just Nfvcb12a
"nfvcb15" -> Just NFVCB15
"nfvcb18" -> Just NFVCB18
"nfvcbG" -> Just NfvcbG
"nfvcbPg" -> Just NfvcbPg
"nfvcbRe" -> Just NfvcbRe
"nfvcbUnrated" -> Just NfvcbUnrated
_ -> Nothing
instance ToText ContentRatingNfvcbRating where
toText = \case
NFVCB12 -> "nfvcb12"
Nfvcb12a -> "nfvcb12a"
NFVCB15 -> "nfvcb15"
NFVCB18 -> "nfvcb18"
NfvcbG -> "nfvcbG"
NfvcbPg -> "nfvcbPg"
NfvcbRe -> "nfvcbRe"
NfvcbUnrated -> "nfvcbUnrated"
instance FromJSON ContentRatingNfvcbRating where
parseJSON = parseJSONText "ContentRatingNfvcbRating"
instance ToJSON ContentRatingNfvcbRating where
toJSON = toJSONText
data ContentRatingMdaRating
= MdaG
| MDAM18
| MDANC16
| MdaPg
| MDAPG13
| MDAR21
| MdaUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingMdaRating
instance FromText ContentRatingMdaRating where
fromText = \case
"mdaG" -> Just MdaG
"mdaM18" -> Just MDAM18
"mdaNc16" -> Just MDANC16
"mdaPg" -> Just MdaPg
"mdaPg13" -> Just MDAPG13
"mdaR21" -> Just MDAR21
"mdaUnrated" -> Just MdaUnrated
_ -> Nothing
instance ToText ContentRatingMdaRating where
toText = \case
MdaG -> "mdaG"
MDAM18 -> "mdaM18"
MDANC16 -> "mdaNc16"
MdaPg -> "mdaPg"
MDAPG13 -> "mdaPg13"
MDAR21 -> "mdaR21"
MdaUnrated -> "mdaUnrated"
instance FromJSON ContentRatingMdaRating where
parseJSON = parseJSONText "ContentRatingMdaRating"
instance ToJSON ContentRatingMdaRating where
toJSON = toJSONText
data ContentRatingAcbRating
= AcbC
| AcbE
| AcbG
| AcbM
| AcbMa15plus
| AcbP
| AcbPg
| AcbR18plus
| AcbUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingAcbRating
instance FromText ContentRatingAcbRating where
fromText = \case
"acbC" -> Just AcbC
"acbE" -> Just AcbE
"acbG" -> Just AcbG
"acbM" -> Just AcbM
"acbMa15plus" -> Just AcbMa15plus
"acbP" -> Just AcbP
"acbPg" -> Just AcbPg
"acbR18plus" -> Just AcbR18plus
"acbUnrated" -> Just AcbUnrated
_ -> Nothing
instance ToText ContentRatingAcbRating where
toText = \case
AcbC -> "acbC"
AcbE -> "acbE"
AcbG -> "acbG"
AcbM -> "acbM"
AcbMa15plus -> "acbMa15plus"
AcbP -> "acbP"
AcbPg -> "acbPg"
AcbR18plus -> "acbR18plus"
AcbUnrated -> "acbUnrated"
instance FromJSON ContentRatingAcbRating where
parseJSON = parseJSONText "ContentRatingAcbRating"
instance ToJSON ContentRatingAcbRating where
toJSON = toJSONText
data ContentRatingDjctqRating
= DJCTQ10
| DJCTQ12
| DJCTQ14
| DJCTQ16
| DJCTQ18
| DjctqL
| DjctqUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingDjctqRating
instance FromText ContentRatingDjctqRating where
fromText = \case
"djctq10" -> Just DJCTQ10
"djctq12" -> Just DJCTQ12
"djctq14" -> Just DJCTQ14
"djctq16" -> Just DJCTQ16
"djctq18" -> Just DJCTQ18
"djctqL" -> Just DjctqL
"djctqUnrated" -> Just DjctqUnrated
_ -> Nothing
instance ToText ContentRatingDjctqRating where
toText = \case
DJCTQ10 -> "djctq10"
DJCTQ12 -> "djctq12"
DJCTQ14 -> "djctq14"
DJCTQ16 -> "djctq16"
DJCTQ18 -> "djctq18"
DjctqL -> "djctqL"
DjctqUnrated -> "djctqUnrated"
instance FromJSON ContentRatingDjctqRating where
parseJSON = parseJSONText "ContentRatingDjctqRating"
instance ToJSON ContentRatingDjctqRating where
toJSON = toJSONText
data VideoStatusFailureReason
= Codec
| Conversion
| EmptyFile
| InvalidFile
| TooSmall
| UploadAborted
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable VideoStatusFailureReason
instance FromText VideoStatusFailureReason where
fromText = \case
"codec" -> Just Codec
"conversion" -> Just Conversion
"emptyFile" -> Just EmptyFile
"invalidFile" -> Just InvalidFile
"tooSmall" -> Just TooSmall
"uploadAborted" -> Just UploadAborted
_ -> Nothing
instance ToText VideoStatusFailureReason where
toText = \case
Codec -> "codec"
Conversion -> "conversion"
EmptyFile -> "emptyFile"
InvalidFile -> "invalidFile"
TooSmall -> "tooSmall"
UploadAborted -> "uploadAborted"
instance FromJSON VideoStatusFailureReason where
parseJSON = parseJSONText "VideoStatusFailureReason"
instance ToJSON VideoStatusFailureReason where
toJSON = toJSONText
data ContentRatingCatvRating
= Catv14plus
| Catv18plus
| CatvC
| CATVC8
| CatvG
| CatvPg
| CatvUnrated
deriving (Eq,Ord,Enum,Read,Show,Data,Typeable,Generic)
instance Hashable ContentRatingCatvRating
instance FromText ContentRatingCatvRating where
fromText = \case
"catv14plus" -> Just Catv14plus
"catv18plus" -> Just Catv18plus
"catvC" -> Just CatvC
"catvC8" -> Just CATVC8
"catvG" -> Just CatvG
"catvPg" -> Just CatvPg
"catvUnrated" -> Just CatvUnrated
_ -> Nothing
instance ToText ContentRatingCatvRating where
toText = \case
Catv14plus -> "catv14plus"
Catv18plus -> "catv18plus"
CatvC -> "catvC"
CATVC8 -> "catvC8"
CatvG -> "catvG"
CatvPg -> "catvPg"
CatvUnrated -> "catvUnrated"
instance FromJSON ContentRatingCatvRating where
parseJSON = parseJSONText "ContentRatingCatvRating"
instance ToJSON ContentRatingCatvRating where
toJSON = toJSONText