{"id":17304086,"url":"https://github.com/owainlewis/cloudant-hs","last_synced_at":"2026-07-12T00:32:11.998Z","repository":{"id":32429543,"uuid":"36007303","full_name":"owainlewis/cloudant-hs","owner":"owainlewis","description":"Haskell client for IBM Cloudant","archived":false,"fork":false,"pushed_at":"2026-07-05T20:32:12.000Z","size":76,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-07-05T22:11:16.608Z","etag":null,"topics":["cloudant","couchdb","database","haskell","haskell-library"],"latest_commit_sha":null,"homepage":"","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/owainlewis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-21T10:46:56.000Z","updated_at":"2026-07-05T20:32:14.000Z","dependencies_parsed_at":"2022-08-26T21:19:34.756Z","dependency_job_id":null,"html_url":"https://github.com/owainlewis/cloudant-hs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/owainlewis/cloudant-hs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owainlewis%2Fcloudant-hs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owainlewis%2Fcloudant-hs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owainlewis%2Fcloudant-hs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owainlewis%2Fcloudant-hs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/owainlewis","download_url":"https://codeload.github.com/owainlewis/cloudant-hs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owainlewis%2Fcloudant-hs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35378722,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-11T02:00:05.354Z","response_time":104,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cloudant","couchdb","database","haskell","haskell-library"],"created_at":"2024-10-15T11:52:08.627Z","updated_at":"2026-07-12T00:32:11.979Z","avatar_url":"https://github.com/owainlewis.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cloudant\n\n![](https://cloudant.com/wp-content/themes/cloudant/images/ibm_cloudant.png)\n\nThis package provides a Haskell interface to the IBM Cloudant database.\nIt should also have full compatibility with CouchDB\n\n## Configuration\n\nThe configuration needed for Cloudant is fairly minimal. We need\n\n1. The full host name of your database (e.g https://owainlewis.cloudant.com)\n2. An API Key which is made up of a username and password\n\n```haskell\n-- Remote cloudant config\nconf :: Config\nconf = Config \"https://owainlewis.cloudant.com\" $ ApiKey \"USER\" \"PASS\"\n\n-- Local configuration for testing against CouchDB\nlocalConfig :: Config\nlocalConfig = Config \"http://192.168.59.103\" $ ApiKey \"admin\" \"password\"\n```\n\n## Return types\n\nAll responses are in the form **IO (Either Error Response)**\n\n## Example\n\n```haskell\n{-# LANGUAGE DeriveGeneric     #-}\n{-# LANGUAGE OverloadedStrings #-}\nmodule Example where\n\nimport           Data.Aeson\nimport qualified Data.ByteString.Lazy  as LBS\nimport           GHC.Generics          (Generic)\nimport           Network.Cloudant.Core as Cloudant\nimport           Network.Cloudant.Util (localConfig)\n\ndata Customer = Customer {\n    firstName :: String\n  , lastName  :: String\n  , email     :: String\n} deriving ( Show, Generic )\n\ninstance ToJSON Customer\ninstance FromJSON Customer\n\ncustomer1 :: Customer\ncustomer1 = Customer \"Jack\" \"Dorsey\" \"jack@twitter.com\"\n\nasJSON :: ToJSON s =\u003e s -\u003e LBS.ByteString\nasJSON customer = encode . toJSON $ customer\n\n-- Create a new database\nCloudant.createDatabase localconfig \"customers\"\n\n-- Add a document to the database\n-- This will automatically serialize any document type with a ToJSON instance\n\n-- The signature for createDocument is\n-- createDocument :: ToJSON a =\u003e Config -\u003e String -\u003e a -\u003e IO (Either String TF.OKResponse)\n\nCloudant.createDocument localConfig \"customers\" (Customer \"Jack\" \"Dorsey\" \"jack@twitter.com\")\n\n```\n\n## Database Info\n\n```haskell\nλ\u003e databaseInfo localConfig \"customers\"\nRight (DatabaseInfo {dbName = \"customers\", documentCount = 3, diskSize = 16482})\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fowainlewis%2Fcloudant-hs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fowainlewis%2Fcloudant-hs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fowainlewis%2Fcloudant-hs/lists"}