{"id":21534621,"url":"https://github.com/danesparza/consul-api","last_synced_at":"2025-04-10T01:43:28.588Z","repository":{"id":23319418,"uuid":"26679348","full_name":"danesparza/consul-api","owner":"danesparza","description":":mountain_cableway: C# API client for Consul","archived":false,"fork":false,"pushed_at":"2016-02-29T18:19:32.000Z","size":490,"stargazers_count":23,"open_issues_count":0,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-24T03:24:01.558Z","etag":null,"topics":["c-sharp","client","consul","consul-api","nuget"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/danesparza.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":"2014-11-15T12:33:52.000Z","updated_at":"2023-08-10T09:08:07.000Z","dependencies_parsed_at":"2022-08-21T21:10:20.827Z","dependency_job_id":null,"html_url":"https://github.com/danesparza/consul-api","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danesparza%2Fconsul-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danesparza%2Fconsul-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danesparza%2Fconsul-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danesparza%2Fconsul-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/danesparza","download_url":"https://codeload.github.com/danesparza/consul-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248142355,"owners_count":21054629,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["c-sharp","client","consul","consul-api","nuget"],"created_at":"2024-11-24T03:12:06.834Z","updated_at":"2025-04-10T01:43:28.564Z","avatar_url":"https://github.com/danesparza.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"consul-api [![Build status](https://ci.appveyor.com/api/projects/status/b6l1hfiknqjxogrf?svg=true)](https://ci.appveyor.com/project/danesparza/consul-api)\n==========\n\nConsul-API is a .NET client for the highly availble service discovery and configuration system, [Consul](https://www.consul.io/).  It aims to be an easy-to-use client. Need [Consul installation instructions](https://www.consul.io/intro/getting-started/install.html)?\n\n### Quick Start\n\nInstall the [NuGet package](https://www.nuget.org/packages/Consul-api/) from the package manager console:\n\n```powershell\nInstall-Package Consul-api\n```\nNext, you will need to provide consul-api with your Consul server endpoint in code. \n\nIn your application, call:\n\n```CSharp\n// Pass the Consul server location on the constructor:\nConsulManager client = new ConsulManager(\"http://your-consul-server.com:8500\");\n\n// Next, make any API call you'd like:\nConfigItem configItem = client.GetConfigItem(configKey);\n```\n\n### Examples\n\n##### Getting a single configuration item:\n\n```CSharp\nusing Consul;\nusing Consul.Config;\n\n// Create a consul client and get the config value for a specified key\nConsulManager client = new ConsulManager(\"http://your-consul-server.com:8500\");\nConfigItem configItem = client.GetConfigItem(\"testing/testconfigitem\");\n\n// If we can find the value ... \nif(configItem != null)\n{\n    // Print out the config value...\n    Console.WriteLine(\"The value for key '{0}' is '{1}' (The raw base64 value is: {2})\", configItem.Key, configItem.Value, configItem.Base64Value);\n}\n\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanesparza%2Fconsul-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanesparza%2Fconsul-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanesparza%2Fconsul-api/lists"}