feat: add GetColorList for available task colors

Adds GetColorList() to query the available task colors from the
Kanboard instance. Returns a map of color_id to display name
(e.g., "yellow" -> "Yellow").

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Oliver Jakoubek 2026-01-27 12:13:18 +01:00
commit c15d52633f
4 changed files with 115 additions and 3 deletions

17
application.go Normal file
View file

@ -0,0 +1,17 @@
package kanboard
import (
"context"
"fmt"
)
// GetColorList returns the available task colors.
// Returns a map of color_id to display name (e.g., "yellow" -> "Yellow").
func (c *Client) GetColorList(ctx context.Context) (map[string]string, error) {
var result map[string]string
if err := c.call(ctx, "getColorList", nil, &result); err != nil {
return nil, fmt.Errorf("getColorList: %w", err)
}
return result, nil
}