{"id":13521012,"url":"https://github.com/goodhamgupta/authzed_ex","last_synced_at":"2026-01-18T07:08:04.685Z","repository":{"id":44148439,"uuid":"509099787","full_name":"goodhamgupta/authzed_ex","owner":"goodhamgupta","description":"Unofficial SpiceDB client library for Elixir","archived":false,"fork":false,"pushed_at":"2025-09-06T15:04:19.000Z","size":121,"stargazers_count":20,"open_issues_count":0,"forks_count":9,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-18T04:17:32.652Z","etag":null,"topics":["authorization","authzed-client","elixir","fine-grained-authorization","permissions","sdk","spicedb","spicedb-client","zanzibar"],"latest_commit_sha":null,"homepage":"","language":"Elixir","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/goodhamgupta.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-06-30T13:51:11.000Z","updated_at":"2025-09-06T15:03:42.000Z","dependencies_parsed_at":"2024-02-16T05:24:24.671Z","dependency_job_id":"6e549fd3-331a-48ff-83ea-fe50091bf5b7","html_url":"https://github.com/goodhamgupta/authzed_ex","commit_stats":{"total_commits":48,"total_committers":4,"mean_commits":12.0,"dds":0.08333333333333337,"last_synced_commit":"d0bde1f3e3326161fc4b2f428d063570f7243de3"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/goodhamgupta/authzed_ex","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goodhamgupta%2Fauthzed_ex","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goodhamgupta%2Fauthzed_ex/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goodhamgupta%2Fauthzed_ex/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goodhamgupta%2Fauthzed_ex/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/goodhamgupta","download_url":"https://codeload.github.com/goodhamgupta/authzed_ex/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goodhamgupta%2Fauthzed_ex/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28532671,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-18T00:39:45.795Z","status":"online","status_checked_at":"2026-01-18T02:00:07.578Z","response_time":98,"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":["authorization","authzed-client","elixir","fine-grained-authorization","permissions","sdk","spicedb","spicedb-client","zanzibar"],"created_at":"2024-08-01T06:00:26.272Z","updated_at":"2026-01-18T07:08:04.669Z","avatar_url":"https://github.com/goodhamgupta.png","language":"Elixir","funding_links":[],"categories":["Clients","Elixir"],"sub_categories":["Third-party Libraries"],"readme":"# Authzed Elixir Client\n\n[![Hex pm](http://img.shields.io/hexpm/v/authzed.svg?style=flat)](https://hex.pm/packages/authzed)\n[![Build Status](https://github.com/goodhamgupta/authzed_ex/actions/workflows/main.yml/badge.svg)](https://github.com/goodhamgupta/authzed_ex/actions)\n\nThis repository houses the Elixir client library for Authzed.\n\n[Authzed] is a database and service that stores, computes, and validates your application's permissions.\n\nDevelopers create a schema that models their permissions requirements and use a client library, such as this one, to apply the schema to the database, insert data into the database, and query the data to efficiently check permissions in their applications.\n\nSupported client API versions:\n- [v1](https://docs.authzed.com/reference/api#authzedapiv1)\n- [v1alpha1](https://docs.authzed.com/reference/api#authzedapiv1alpha1)\n- [v0](https://docs.authzed.com/reference/api#authzedapiv0) - Deprecated\n\nYou can find more info on each API on the [Authzed API reference documentation].\nAdditionally, Protobuf API documentation can be found on the [Buf Registry Authzed API repository].\n\n**NOTE**: Current Authzed SDK commit version on Buf available [here](https://buf.build/authzed/api/activity/commit/ae0019fd4971464faeac85b2e146bdb8)\n\n[Authzed]: https://authzed.com\n[Authzed API Reference documentation]: https://docs.authzed.com/reference/api\n[Buf Registry Authzed API repository]: https://buf.build/authzed/api/docs/main\n\n## Basic Usage\n\nIf you're using a local SpiceDB instance, you can start the instance with Docker and Docker Compose using the command:\n\n```ex\nmake start-infra\n```\n\n### Installation\n\nThe package can be installed by adding `authzed` to your list of dependencies in `mix.exs`:\n\n```elixir\ndef deps do\n  [\n    {:authzed, \"~\u003e 0.0.1\"}\n  ]\nend\n```\n\n### Initializing a client\n\nIn order to successfully connect, you will have to provide a [Bearer Token] with your own API Token from the [Authzed dashboard] in place of `somerandomkeyhere` in the following example:\n\n[Bearer Token]: https://datatracker.ietf.org/doc/html/rfc6750#section-2.1\n[Authzed Dashboard]: https://app.authzed.com\n\n```ex\n\nalias Authzed.Api.V1.{Client, GRPCUtil}\n\nclient = Client.new(\n    \"localhost:50051\",\n    GRPCUtil.insecure_bearer_auth_token(\"somerandomkeyhere\")\n)\n```\n\n### Performing an API call\n\n```ex\n\nalias Authzed.Api.V1.{\n  CheckPermissionRequest,\n  ObjectReference,\n  SubjectReference,\n}\n\n# Is Emilia in the set of users that can read post #1?\npost_one = ObjectReference.new(object_type: \"post\", object_id: \"1\")\n\nemilia =\n  SubjectReference.new(object: ObjectReference.new(object_type: \"user\", object_id: \"emilia\"))\n\n{:ok, response} =\nclient.permissions_service.check_permission(\n  client.channel,\n  CheckPermissionRequest.new(\n    resource: post_one,\n    permission: \"view\",\n    subject: emilia\n  )\n)\n\nassert response.permissionship == :PERMISSIONSHIP_HAS_PERMISSION\n```\n\n### Telemetry\n\nSince version `0.0.6` telemetry events are published by the GRPC library. \nSee [docs](https://hexdocs.pm/grpc/GRPC.Telemetry.html) for details.\n\n## Running Tests\n\nRun the tests using the command:\n\n```sh\nmake run-tests\n```\n\n- Note that this will create a SpiceDB instance with the option `serve-testing`. creating an in-memory spicedb server which serves completely isolated datastores per client-supplied auth token used.\n\n## Generate Protobuf Definitions\n\nWe use Buf to generate the protobuf and GRPC definitions for Elixir. You can use the command\n\n```sh\nmake generate\n```\n\nto regenerate the definitions and move them to their respective folders.\n\n**NOTE** \n- Install protoc-gen-elixir using the instructions in the [Elixir Protobuf Repository](https://github.com/elixir-protobuf/protobuf#generate-elixir-code)\n- If you're using asdf to manage elixir versions, run the command `asdf reshim elixir` to add the `protoc-gen-elixir` executable to the PATH.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoodhamgupta%2Fauthzed_ex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoodhamgupta%2Fauthzed_ex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoodhamgupta%2Fauthzed_ex/lists"}