!SNN      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLM#Brandon Chinn <brandon@leapyear.io> experimentalportableNone_ N github-rest!The ID of your GitHub application  github-rest-The token to use to authenticate with GitHub.  github-rest /https://developer.github.com/v3/#authentication  github-rest vhttps://developer.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app github-rest.Create a JWT token that expires in 10 minutes. github-rest<Load a RSA private key as a Signer from the given file path.  #Brandon Chinn <brandon@leapyear.io> experimentalportableNone&'=? github-rest%A type representing a key-value pair.O github-rest Convert a  into a P. github-rest/Convert the given KeyValues into a JSON Object. github-rest0Represent the given KeyValue as a pair of Texts.1#Brandon Chinn <brandon@leapyear.io> experimentalportableNone"#V github-rest A call to a GitHub API endpoint. github-restUThe GitHub API endpoint, with colon-prefixed components that will be replaced; e.g. "/users/:username/repos" github-rest8Key-value pairs to replace colon-prefixed components in ; e.g. #[ "username" := ("alice" :: Text) ] github-rest3Key-value pairs to send in the request body; e.g. A[ "sort" := ("created" :: Text), "direction" := ("asc" :: Text) ] github-rest5Return the endpoint path, populated by the values in .  github-rest"Render the method of the endpoint.   Safe"p! github-rest"Helper type for GitHub pagination. Bhttps://developer.github.com/v3/guides/traversing-with-pagination/Q github-restParse a single page link, like: Chttps://api.github.com/search/code?q=addClass+user%3Amozilla&page=2 ; rel="next"Returns ("next", "search'code?q=addClass+user%3Amozilla&page=2")R github-restRSplit the given text by the given delimiter, stripping any surrounding whitespace.S github-restBDrop the given strings at the beginning and end of the given text.!"#$%&'!"#$%&'#Brandon Chinn <brandon@leapyear.io> experimentalportableNonek9H, github-rest;A type class for monads that can query the GitHub REST API.Example: -- create the "foo" branch queryGitHub GHEndpoint { method = POST , endpoint = "/repos/:owner/:repo/git/refs" , endpointVals = [ "owner" := "alice" , "repo" := "my-project" ] , ghData = [ "ref" := "refs/heads/foo" , "sha" := "1234567890abcdef" ] }NIt's recommended that you create functions for the API endpoints you're using: deleteBranch branch = queryGitHub GHEndpoint { method = DELETE , endpoint = "/repos/:owner/:repo/git/refs/:ref" , endpointVals = [ "owner" := "alice" , "repo" := "my-project" , "ref" := "heads/" <> branch ] , ghData = [] }- github-restQuery GitHub, returning Right (payload, links) if successful, where payload, is the response that GitHub sent back and linkst containing any pagination links GitHub may have sent back. If the response could not be decoded as JSON, returns *Left (error message, response from server).SErrors on network connection failures or if GitHub sent back an error message. Use  githubTry& if you wish to handle GitHub errors.. github-rest-, except calls T if JSON decoding fails./ github-rest.#, except ignoring pagination links.0 github-restRepeatedly calls .@ for each page returned by GitHub and concatenates the results.1 github-rest/, except ignores the result.,-./01,-./01#Brandon Chinn <brandon@leapyear.io> experimentalportableNone"#MPdE8< github-rest'A simple monad that can run REST calls.? github-rest.The token to use to authenticate with the API.@ github-rest5The user agent to use when interacting with the API: 4https://developer.github.com/v3/#user-agent-requiredA github-restThe media type will be sent as: application/vnd.github.VERSION+json. For the standard API endpoints, "v3" should be sufficient here. See &https://developer.github.com/v3/media/B github-restRun the given <, action with the given token and user agent.4The token will be sent with each API request -- see  ?. The user agent is also required for each API request -- see  4https://developer.github.com/v3/#user-agent-required. ,-./01<=>?@AB ,-./01<=>?@AB#Brandon Chinn <brandon@leapyear.io> experimentalportableNoneLK github-rest4Handle 422 exceptions thrown by the GitHub REST API.Most client errors are 422, since we should always be sending valid JSON. If an endpoint throws different error codes, use githubTry'. .https://developer.github.com/v3/#client-errorsL github-rest9Handle the given exception thrown by the GitHub REST API.M github-rest?Get the given key from the Value, erroring if it doesn't exist.'  ,-./01<=>?@ABKLM',-./01<=>?@AB KLM SafeNZUVWXYZ[\]           !""#$%&'()*++,-./0123456789:;<=>?@ABCDEFFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghi(github-rest-1.0.0-5VjeMuQo86sChLe0g8CQEU GitHub.RESTGitHub.REST.AuthGitHub.REST.KeyValueGitHub.REST.EndpointGitHub.REST.PageLinksGitHub.REST.Monad.ClassGitHub.REST.MonadPaths_github_rest(http-types-0.12.3-A2cx1Lg5j0cKG76Sfj8L06Network.HTTP.Types.MethodPATCHOPTIONSCONNECTTRACEDELETEPUTHEADPOSTGET StdMethodToken AccessToken BearerToken fromToken getJWTToken loadSigner $fShowTokenKeyValue:= kvToValuekvToText $fToJSON[]$fShowKeyValue GHEndpointmethodendpoint endpointValsghData GitHubData EndpointVals endpointPath renderMethod PageLinks pageFirstpagePrevpageNextpageLastparsePageLinks$fMonoidPageLinks$fSemigroupPageLinks $fEqPageLinks$fShowPageLinksMonadGitHubRESTqueryGitHubPage'queryGitHubPage queryGitHubqueryGitHubAll queryGitHub_$fMonadGitHubRESTWriterT$fMonadGitHubRESTWriterT0$fMonadGitHubRESTStateT$fMonadGitHubRESTStateT0$fMonadGitHubRESTRWST$fMonadGitHubRESTRWST0$fMonadGitHubRESTMaybeT$fMonadGitHubRESTIdentityT$fMonadGitHubRESTExceptT$fMonadGitHubRESTReaderTGitHubT GitHubState$sel:token:GitHubState$sel:userAgent:GitHubState$sel:apiVersion:GitHubState runGitHubT$fMonadGitHubRESTGitHubT$fMonadUnliftIOGitHubT$fFunctorGitHubT$fApplicativeGitHubT$fMonadGitHubT$fMonadFailGitHubT$fMonadIOGitHubT$fMonadTransGitHubT githubTry githubTry'.:AppIdtoPair$aeson-1.4.5.0-9WciqreC8Dh4Ox91K72izuData.Aeson.Types.InternalPair parsePageLinksplit dropAroundbaseGHC.Basefailversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName