MCPcopy Index your code
hub / github.com/canonical/candid

github.com/canonical/candid @v1.12.8

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.12.8 ↗ · + Follow
2,279 symbols 8,889 edges 233 files 1,044 documented · 46% updated 2mo agov1.12.0 · 2022-07-01★ 4321 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Candid Identity service

The Candid server provides a macaroon-based authentication service.

Installation

The easiest way to start using the candid service is with the snap:

snap install candid

The configuration file used by the snap can be found in /var/snap/candid/current/config.yaml.

Development

Requirements

Candid requires go1.23 or later to build. This is available in the go snap:

snap install go

Go will additionally require installing the following packages in order that it can fetch and build candid dependencies:

apt install build-essential bzr git

Source

Get the source from github.com/canonical/candid.

git clone https://github.com/canonical/candid

It is recommended that you check out the source outside of any $GOPATH ($HOME/go by default). If you do wish to check out into a $GOPATH then you will need to set the environment variable GO111MODULE=on.

Testing

The store/mgostore component additionally requires a running mongodb server, this may be running on a different system. The location of the mongodb server should be specified in an environment variable called MGOCONNECTIONSTRING, if this does not exist then the standard port (27017) on localhost will be assumed. To disable testing of store/mgostore completely then set the environment variable MGOTESTDISABLE=1.

The store/sqlstore component additionally requires a running postgresql, this may be running on a different system. The posgresql system to use is specified using the standard postgresql environment variables. To skip running postgresql tests set the environment variable PGTESTDISABLE=1.

Tests are run by running make check in the root of the source tree. The tests for a single package can be run by running go test in the package directory.

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Method 1,265
Function 531
Struct 396
Class 30
Interface 30
TypeAlias 19
FuncType 7
Route 1

Languages

Go92%
Python8%

Modules by API surface

charms/candid/lib/charms/operator_libs_linux/v2/snap.py84 symbols
params/params.go44 symbols
internal/discharger/discharge_test.go43 symbols
internal/v1/users_test.go40 symbols
store/sqlstore/store.go34 symbols
meeting/meeting_test.go34 symbols
internal/auth/auth.go32 symbols
internal/v1/users.go30 symbols
store/memstore/store.go29 symbols
internal/mfa/webauthn.go29 symbols
idp/openid/openid-connect.go29 symbols
idp/ldap/ldap.go29 symbols

Datastores touched

(mongodb)Database · 1 repos
identityDatabase · 1 repos
idmDatabase · 1 repos
candidDatabase · 1 repos

For agents

$ claude mcp add candid \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page