{"id":20487167,"url":"https://github.com/tiagopog/iugu-elixir","last_synced_at":"2026-01-30T04:19:11.534Z","repository":{"id":75480969,"uuid":"113642016","full_name":"tiagopog/iugu-elixir","owner":"tiagopog","description":"Elixir client for the Iugu's API","archived":false,"fork":false,"pushed_at":"2019-03-03T04:09:37.000Z","size":67,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-07T00:06:31.270Z","etag":null,"topics":["client","elixir","elixir-phoenix","invoice","iugu","payment","payment-gateway"],"latest_commit_sha":null,"homepage":"","language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tiagopog.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-12-09T04:37:51.000Z","updated_at":"2024-12-12T11:35:42.000Z","dependencies_parsed_at":"2023-06-06T15:15:13.610Z","dependency_job_id":null,"html_url":"https://github.com/tiagopog/iugu-elixir","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/tiagopog%2Fiugu-elixir","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagopog%2Fiugu-elixir/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagopog%2Fiugu-elixir/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiagopog%2Fiugu-elixir/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tiagopog","download_url":"https://codeload.github.com/tiagopog/iugu-elixir/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240491987,"owners_count":19810004,"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":["client","elixir","elixir-phoenix","invoice","iugu","payment","payment-gateway"],"created_at":"2024-11-15T16:40:12.507Z","updated_at":"2026-01-30T04:19:06.514Z","avatar_url":"https://github.com/tiagopog.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Iugu\n\nElixir client library to work with the [Iugu's REST API](https://dev.iugu.com/v1.0).\n\nSince the lib is still in its early days one may find some missing endpoints,\nso please check the [Endpoint Coverage](https://github.com/b2beauty/iugu-elixir/wiki/Endpoint-Coverage)\nwiki page for more details.\n\n## Installation\n\nIf [available in Hex](https://hex.pm/docs/publish), the package can be installed as:\n\n1. Add `iugu` to your list of dependencies in `mix.exs`:\n\n```elixir\ndef deps do\n  [{:iugu, \"~\u003e 0.1.0\"}]\n end\n```\n\n2. Ensure `iugu` is started before your application:\n\n```elixir\ndef application do\n  [applications: [:iugu]]\nend\n```\n\n## Usage\n\n### Credentials\n\n1. Get your [Iugu's API KEY](https://dev.iugu.com/v1.0/reference#autentica%C3%A7%C3%A3o);\n\n2. Set the key on your project:\n\n#### Via config\n\nDirectly:\n\n```elixir\n# config/config.exs\nconfig :iugu,\n  api_key: \"foobar\"\n```\n\nOr export the key to your environment and access it via `System.get_env/1` (recommended):\n\n```sh\n# .env\nIUGU_API_KEY=foobar\n```\n\n```elixir\n# config/config.exs\nconfig :iugu,\n  api_key: System.get_env(\"IUGU_API_KEY\")\n```\n\nThis way you can call the resource actions with no need to pass the `%Iugu.Resource{}` as argument:\n\n```elixir\nIugu.Customer.list() #=\u003e {:ok, [...], 42}\n```\n\n#### Via struct\n\nIt's also possible to set the key into a `%Iugu.Request{}` struct:\n\n  ```elixir\n  %Iugu.Request{api_key: \"foobar\"} |\u003e Iugu.Customer.list()\n  ```\n\n### Resources\n\nThe CRUD actions are present in almost all the resources, here's an example for \"customers\":\n\n##### Create\n\n```elixir\n%Iugu.Customer{name: \"Foobar\", email: \"foo@bar.com\"} |\u003e Iugu.Customer.create()\n#=\u003e {:ok, %Iugu.Customer{name: \"Foobar\", email: \"foo@bar.com\",...}}\n```\n\n##### Show\n\n```elixir\nIugu.Customer.show(\"6DB324B6859D4D46A3B8689AC745A943\")\n#=\u003e {:ok, %Iugu.Customer{cc_emails: nil, city: \"Campo Mourão\", complement: \"Cobertura\",...}}\n```\n\n##### List\n\n```elixir\nIugu.Customer.list()\n#=\u003e {:ok, [%Iugu.Customer{cc_emails: nil, city: \"Campo Mourão\", complement: \"Cobertura\",...}], 128}\n```\n\nFor more usage examples, please check the [Usage](https://github.com/b2beauty/iugu-elixir/wiki/Usage) wiki page.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagopog%2Fiugu-elixir","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftiagopog%2Fiugu-elixir","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiagopog%2Fiugu-elixir/lists"}