Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Error
- = HTTPError !HttpException
- | ParseError !Text
- | JsonError !Text
- | UserError !Text
- type OwnerName = Name Owner
- type PullRequestId = Id PullRequest
- type RepoName = Name Repo
- type Token = ByteString
- newtype URL = URL Text
- leaveComment :: Maybe OwnerName -> RepoName -> PullRequestId -> Token -> Maybe Text -> FilePath -> Checklist -> IO (Either Error (Maybe URL))
- mkOwnerName :: Text -> OwnerName
- mkPullRequestId :: Int -> PullRequestId
- mkRepoName :: Text -> RepoName
- pullRequestBaseSha :: Maybe OwnerName -> RepoName -> PullRequestId -> Token -> Maybe Text -> IO (Either Error Text)
Documentation
Errors have been tagged according to their source, so you can more easily dispatch and handle them.
HTTPError !HttpException | A HTTP error occurred. The actual caught error is included. |
ParseError !Text | An error in the parser itself. |
JsonError !Text | The JSON is malformed or unexpected. |
UserError !Text | Incorrect input. |
Instances
Show Error | |
Exception Error | |
Defined in GitHub.Data.Definitions toException :: Error -> SomeException # fromException :: SomeException -> Maybe Error # displayException :: Error -> String # |
type PullRequestId = Id PullRequest Source #
type Token = ByteString #
Data representing URLs in responses.
N.B. syntactical validity is not verified.
Instances
Eq URL | |
Data URL | |
Defined in GitHub.Data.URL gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> URL -> c URL # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c URL # dataTypeOf :: URL -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c URL) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c URL) # gmapT :: (forall b. Data b => b -> b) -> URL -> URL # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> URL -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> URL -> r # gmapQ :: (forall d. Data d => d -> u) -> URL -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> URL -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> URL -> m URL # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> URL -> m URL # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> URL -> m URL # | |
Ord URL | |
Show URL | |
Generic URL | |
ToJSON URL | |
Defined in GitHub.Data.URL | |
FromJSON URL | |
Binary URL | |
NFData URL | |
Defined in GitHub.Data.URL | |
type Rep URL | |
Defined in GitHub.Data.URL |
leaveComment :: Maybe OwnerName -> RepoName -> PullRequestId -> Token -> Maybe Text -> FilePath -> Checklist -> IO (Either Error (Maybe URL)) Source #
mkOwnerName :: Text -> OwnerName Source #
mkPullRequestId :: Int -> PullRequestId Source #
mkRepoName :: Text -> RepoName Source #