Document every exported symbol and how callers use the library.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-29 19:25:44 +02:00
co-authored by Cursor
parent d7768d44d6
commit afbd76445d
11 changed files with 1226 additions and 107 deletions
+4
View File
@@ -38,6 +38,8 @@ func (p AppAPIPreferences) ocsClient() OCSClient {
}
// Get loads the configured preference key for the requesting user.
// A missing key returns an empty string and a nil error.
// It returns an error when the OCS call fails or the body cannot be decoded.
func (p AppAPIPreferences) Get() (string, error) {
ocs := p.ocsClient()
body, _ := json.Marshal(map[string]any{"configKeys": []string{p.Key}})
@@ -49,6 +51,8 @@ func (p AppAPIPreferences) Get() (string, error) {
}
// Set stores value for the configured preference key.
// The value is stored as non-sensitive.
// It returns an error when the OCS call fails.
func (p AppAPIPreferences) Set(value string) error {
ocs := p.ocsClient()
body, _ := json.Marshal(map[string]any{