MCPcopy Index your code
hub / github.com/Elara6331/go-lemmy

github.com/Elara6331/go-lemmy @v0.19.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.19.0 ↗ · + Follow
355 symbols 595 edges 11 files 120 documented · 34%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Go-Lemmy

Go Reference

Go bindings to the Lemmy API, automatically generated from Lemmy's source code using the generator in cmd/gen.

Examples

Examples can be found in the examples directory.

How to generate

First, clone the lemmy-js-client repo at whatever version you need:

git clone https://github.com/LemmyNet/lemmy-js-client -b 0.18.3

Inside it, build the JSON docs file:

npm run docs -- --json docs.json

Next, build the generator:

go build ./cmd/gen

Remove all the existing generated code:

rm **/*.gen.go

Execute the generator:

./gen -json-file <path_to_docs.json> -out-dir .

And that's it! Your generated code should be ready for use.

Core symbols most depended-on inside this repo

resError
called by 91
lemmy.go
req
called by 63
lemmy.go
getReq
called by 28
lemmy.go
String
called by 22
optional.go
ClientLogin
called by 3
lemmy.go
Value
called by 2
optional.go
Generate
called by 2
cmd/gen/generator/routes.go
NewWithClient
called by 1
lemmy.go

Shape

Struct 214
Method 112
Function 20
TypeAlias 9

Languages

Go100%

Modules by API surface

types.gen.go213 symbols
routes.gen.go91 symbols
optional.go14 symbols
cmd/gen/extractor/extractor.go11 symbols
lemmy.go10 symbols
cmd/gen/generator/struct.go7 symbols
cmd/gen/generator/routes.go4 symbols
cmd/gen/main.go2 symbols
examples/posts/main.go1 symbols
examples/comments/main.go1 symbols
examples/basic/main.go1 symbols

For agents

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

⬇ download graph artifact

Ask about this repo answers extend the page