packages feed

todoist-sdk-0.1.2.1: todoist-sdk.cabal

cabal-version:      2.2

name:               todoist-sdk
version:            0.1.2.1
synopsis:           Unofficial Haskell SDK for the Todoist REST API
description:
  TodoistSDK provides a type-safe, tagless-final interface to the Todoist REST API. It includes comprehensive coverage of Projects, Tasks, Comments, Sections, and Labels endpoints with both real HTTP and tracing interpreters for testing. The library uses mtl-style type classes for operation definitions and provides a clean builder pattern for request construction.

license:            MIT
license-file:       LICENSE
author:             Sam S. Almahri
maintainer:         sam.salmahri@gmail.com
homepage:           https://github.com/samahri/TodoistSDK
bug-reports:        https://github.com/samahri/TodoistSDK/issues
copyright:          2025 Sam S. Almahri
category:           Web
build-type:         Simple
extra-doc-files:
  README.md
  CHANGELOG.md

tested-with:        ghc ==9.10.2

source-repository head
  type:     git
  location: https://github.com/samahri/TodoistSDK


-- Internal library - not exposed to end users but available to tests
library todoist-sdk-internal
  hs-source-dirs:     src/internal
  exposed-modules:
    Web.Todoist.Internal.Config
    Web.Todoist.Internal.Error
    Web.Todoist.Internal.HTTP
    Web.Todoist.Internal.Request
    Web.Todoist.Internal.Types
    Web.Todoist.Internal.Json

  default-language:   Haskell2010
  default-extensions:
    InstanceSigs
    OverloadedStrings
    NoImplicitPrelude

  build-depends:
    , aeson         >=2.2.3.0   && <2.3
    , base          >=4.7       && <5
    , bytestring    >=0.12.2.0  && <0.12.3
    , req           >=3.13.4    && <3.14
    , text          >=2.1.2     && <2.2
    , transformers  >=0.6.1.1   && <0.6.2.0

  ghc-options:
    -Wall
    -Wcompat
    -Widentities
    -Wincomplete-record-updates
    -Wincomplete-uni-patterns
    -Wmissing-export-lists
    -Wmissing-home-modules
    -Wpartial-fields
    -Wredundant-constraints

-- Public library - this is what end users depend on
library
  hs-source-dirs:     src
  exposed-modules:
    Web.Todoist
    Web.Todoist.Domain.Project
    Web.Todoist.Domain.Task
    Web.Todoist.Domain.Comment
    Web.Todoist.Domain.Section
    Web.Todoist.Domain.Label
    Web.Todoist.Domain.Types
    Web.Todoist.Lens
    Web.Todoist.Util.Builder
    Web.Todoist.Util.QueryParam
    Web.Todoist.Runner
    Web.Todoist.Runner.IO
    Web.Todoist.Runner.IO.Core
    Web.Todoist.Runner.IO.Interpreters
    Web.Todoist.Runner.Trace

  default-language:   Haskell2010
  default-extensions:
    InstanceSigs
    OverloadedStrings
    NoImplicitPrelude

  build-depends:
    , aeson                >=2.2.3.0   && <2.3
    , base                 >=4.7       && <5
    , bytestring           >=0.12.2.0  && <0.12.3
    , microlens            >=0.4.13    && <0.5
    , req                  >=3.13.4    && <3.14
    , text                 >=2.1.2     && <2.2
    , todoist-sdk-internal
    , transformers         >=0.6.1.1   && <0.6.2.0

  ghc-options:
    -Wall
    -Wcompat
    -Widentities
    -Wincomplete-record-updates
    -Wincomplete-uni-patterns
    -Wmissing-export-lists
    -Wmissing-home-modules
    -Wpartial-fields
    -Wredundant-constraints

test-suite todoist-sdk-test
  type:               exitcode-stdio-1.0
  main-is:            Spec.hs
  hs-source-dirs:     test
  other-modules:
    Web.Todoist.TestHelpers
    Web.Todoist.Runner.TodoistIOSpec
    Web.Todoist.Runner.TodoistIO.TaskSpec
    Web.Todoist.Runner.TodoistIO.CommentSpec
    Web.Todoist.Runner.TodoistIO.SectionSpec
    Web.Todoist.Runner.TodoistIO.LabelSpec
    Web.Todoist.BuilderSpec

  default-language:   Haskell2010
  default-extensions:
    InstanceSigs
    OverloadedStrings
    NoImplicitPrelude

  build-depends:
    , aeson                >=2.2.3.0  && <2.3
    , base                 >=4.7      && <5
    , bytestring           >=0.12.2.0 && <0.12.3
    , hspec                >=2.11
    , hspec-discover       >=2.11
    , text                 >=2.1.2    && <2.2
    , todoist-sdk
    , todoist-sdk-internal

  build-tool-depends: hspec-discover:hspec-discover
  ghc-options:
    -Wall
    -Wcompat
    -Widentities
    -Wincomplete-record-updates
    -Wincomplete-uni-patterns
    -Wmissing-export-lists
    -Wmissing-home-modules
    -Wpartial-fields
    -Wredundant-constraints
    -threaded
    -rtsopts
    -with-rtsopts=-N

test-suite integration-tests
  type:               exitcode-stdio-1.0
  main-is:            Spec.hs
  hs-source-dirs:     integration-test
  other-modules:
    ProjectIntegrationSpec
    TaskIntegrationSpec
    CommentIntegrationSpec
    SectionIntegrationSpec
    LabelIntegrationSpec
    Helpers

  default-language:   Haskell2010
  default-extensions:
    InstanceSigs
    OverloadedStrings
    NoImplicitPrelude

  build-depends:
    , base                 >=4.7      && <5
    , dotenv               >=0.11
    , hspec                >=2.11
    , hspec-discover       >=2.11
    , random               >=1.2
    , text                 >=2.1.2    && <2.2
    , todoist-sdk
    , todoist-sdk-internal
    , transformers         >=0.6.1.1  && <0.6.2.0

  build-tool-depends: hspec-discover:hspec-discover
  ghc-options:
    -Wall
    -Wcompat
    -Widentities
    -Wincomplete-record-updates
    -Wincomplete-uni-patterns
    -Wmissing-export-lists
    -Wmissing-home-modules
    -Wpartial-fields
    -Wredundant-constraints
    -threaded
    -rtsopts
    -with-rtsopts=-N