{"modulePath":"github.com/bborbe/agent-task-executor","version":"v0.25.0","isLatest":false,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package gitrestclient\n\n## Types\n\n```go\ntype GitRestClient interface {\n\t// Get retrieves the current content of the file at relPath.\n\tGet(ctx context.Context, relPath string) ([]byte, error)\n\t// List returns relative paths matching the single-level glob pattern (e.g. \"tasks/*.md\").\n\tList(ctx context.Context, glob string) ([]string, error)\n\t// IsReady reports whether git-rest's /readiness returns 200.\n\t// Returns (false, nil) when git-rest returns 503 — that is a valid not-ready state, not an error.\n\t// Returns (false, err) only on network failure or unexpected response.\n\tIsReady(ctx context.Context) (bool, error)\n}\n```\nGitRestClient is the HTTP client for git-rest's /api/v1/files REST API. All paths are relative to the repo root (e.g. \"tasks/foo.md\"). The executor uses only the read surface (List/Get/IsReady) — it never writes vault files through git-rest (spec 005 Security).\n\n```go\nfunc NewGitRestClient(baseURL, gatewaySecret, gatewayInitiator string) GitRestClient\n```\nNewGitRestClient creates a GitRestClient targeting the git-rest instance at baseURL. gatewaySecret is the shared secret enforced by git-rest's gateway-secret auth; when empty, no auth headers are sent (backward-compat with auth-disabled git-rest). gatewayInitiator is the caller identity logged by git-rest on auth failure (pass a stable value, e.g. \"agent-task-executor\").\n\n","path":"github.com/bborbe/agent-task-executor/pkg/gitrestclient","name":"gitrestclient","synopsis":"","isRedistributable":true}
