{"id":37028898,"url":"https://github.com/verizon/helm","last_synced_at":"2026-01-14T03:27:39.719Z","repository":{"id":57736413,"uuid":"83335577","full_name":"Verizon/helm","owner":"Verizon","description":"A native Scala client for interacting with Consul","archived":true,"fork":false,"pushed_at":"2019-08-11T15:03:04.000Z","size":165,"stargazers_count":81,"open_issues_count":3,"forks_count":24,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-12-11T09:20:28.665Z","etag":null,"topics":["consul","infrastructure","reasonable"],"latest_commit_sha":null,"homepage":null,"language":"Scala","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Verizon.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":"2017-02-27T17:06:46.000Z","updated_at":"2024-03-17T22:28:36.000Z","dependencies_parsed_at":"2022-08-24T11:20:57.725Z","dependency_job_id":null,"html_url":"https://github.com/Verizon/helm","commit_stats":null,"previous_names":[],"tags_count":45,"template":false,"template_full_name":null,"purl":"pkg:github/Verizon/helm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Verizon%2Fhelm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Verizon%2Fhelm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Verizon%2Fhelm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Verizon%2Fhelm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Verizon","download_url":"https://codeload.github.com/Verizon/helm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Verizon%2Fhelm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408843,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"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":["consul","infrastructure","reasonable"],"created_at":"2026-01-14T03:27:39.196Z","updated_at":"2026-01-14T03:27:39.712Z","avatar_url":"https://github.com/Verizon.png","language":"Scala","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Helm\n\n![Logo](docs/src/img/logo.png)\n\n[![Build Status](https://travis-ci.org/Verizon/helm.svg?branch=master)](https://travis-ci.org/Verizon/helm)\n[![Maven Central](https://maven-badges.herokuapp.com/maven-central/io.verizon.helm/core_2.11/badge.svg)](https://maven-badges.herokuapp.com/maven-central/io.verizon.helm/core_2.11)\n[![codecov](https://codecov.io/gh/Verizon/helm/branch/master/graph/badge.svg)](https://codecov.io/gh/Verizon/helm)\n\nA native [Scala](http://scala-lang.org) client for interacting with [Consul](https://www.consul.io/). There is currently one supported client, which uses [http4s](http://http4s.org) to make HTTP calls to Consul. Alternative implementations could be added with relative ease by providing an additional free interpreter for the `ConsulOp` algebra.\n\n## Getting Started\n\nAdd the following to your `build.sbt`:\n\n    libraryDependencies += \"io.verizon.helm\" %% \"http4s\" % \"1.4.78-scalaz-7.1\"\n\nThe *Helm* binaries are located on maven central, so no additional resolvers are needed.\n\n### Algebra\n\nConsul operations are specified by the `ConsulOp` algebra.  Two\nexamples are `get` and `set`:\n\n```\nimport helm._\nimport ConsulOp.ConsulOpF\n\nval s: ConsulOpF[Unit] = : ConsulOp.kvSet(\"key\", \"value\")\n\nval g: ConsulOpF[Option[String]] = : ConsulOp.kvGet(\"key\")\n```\n\nThese are however just descriptions of what operations the program might perform in the future, just creating these operations does not\nactually execute the operations. In order to perform the gets and sets, we need to use the [http4s](http://http4s.org) interpreter.\n\n### The http4s interpreter\n\nFirst we create an interpreter, which requires an http4s client and\na base url for consul:\n\n```\nimport cats.effect.IO\nimport helm.http4s._\nimport org.http4s.Uri.uri\nimport org.http4s.client.blaze.Http1Client\n\nval client = Http1Client[IO]().unsafeRunSync\nval baseUrl = uri(\"http://127.0.0.1:8500\")\n\nval interpreter = new Http4sConsulClient(baseUrl, client)\n```\n\nNow we can apply commands to our http4s client to get back IOs\nwhich actually interact with consul.\n\n```\nimport cats.effect.IO\n\nval s: IO[Unit] = helm.run(interpreter, ConsulOp.kvSet(\"testkey\", \"testvalue\"))\n\nval g: IO[Option[String]] = helm.run(interpreter, ConsulOp.kvGet(\"testkey\"))\n\n// actually execute the calls\ns.unsafeRunSync\ng.unsafeRunSync\n```\n\nTypically, the *Helm* algebra would be a part of a `Coproduct` with other algebras in a larger program, so running the `IO` immediately after `helm.run` is not typical.\n\n## Contributing\n\nContributions are welcome; particularly to expand the algebra with additional operations that are supported by Consul but not yet supported by *Helm*.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fverizon%2Fhelm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fverizon%2Fhelm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fverizon%2Fhelm/lists"}