diff options
author | William Carroll <wpcarro@gmail.com> | 2020-12-12T02·43+0000 |
---|---|---|
committer | William Carroll <wpcarro@gmail.com> | 2020-12-12T02·43+0000 |
commit | 8c5e4e77edacf082b5ab2d8aede49aa0ddfb9b5e (patch) | |
tree | b216303b8755d7d945a35a2a3d12d77b3828ceeb /assessments/semiprimes/server/mix.exs | |
parent | 45877a8b9cbe728e2dd66c361b3d6625810b31a0 (diff) |
Expose functions at API layer
Creating a simple HTTP RESTful API for exposing our `Server.semiprime` function. It supports some help messages, primitive parsing and error handling, and singular vs. batch processing of arguments. For more sophisticated parsing and error-checking, I prefer to use Haskell's Servant library.
Diffstat (limited to 'assessments/semiprimes/server/mix.exs')
-rw-r--r-- | assessments/semiprimes/server/mix.exs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/assessments/semiprimes/server/mix.exs b/assessments/semiprimes/server/mix.exs index 2bbd357c3854..9062f927e7a8 100644 --- a/assessments/semiprimes/server/mix.exs +++ b/assessments/semiprimes/server/mix.exs @@ -22,7 +22,11 @@ defmodule Server.MixProject do # Run "mix help deps" to learn about dependencies. defp deps do [ - {:cortex, "~> 0.1", only: [:dev, :test]} + {:cortex, "~> 0.1", only: [:dev, :test]}, + {:plug_cowboy, "~> 2.4.1"}, + {:cowboy, "~> 2.8.0"}, + {:plug, "~> 1.11.0"}, + {:poison, "~> 4.0.1"} ] end end |