47fac22230
- .claude/CLAUDE.md - .claude/commands/subagentes.md - .claude/rules/INDEX.md - .mcp.json - bash/functions/cybersecurity/analyze_dns.md - bash/functions/cybersecurity/audit_http_headers.md - bash/functions/cybersecurity/audit_ssh_config.md - bash/functions/cybersecurity/check_firewall.md - bash/functions/cybersecurity/detect_suspicious_users.md - bash/functions/cybersecurity/encrypt_file.md - ... Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1.5 KiB
1.5 KiB
name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, params, output, tested, tests, test_file_path, file_path
| name | kind | lang | domain | version | purity | signature | description | tags | uses_functions | uses_types | returns | returns_optional | error_type | imports | params | output | tested | tests | test_file_path | file_path | |||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| metabase_get_user | function | go | infra | 1.0.0 | impure | func MetabaseGetUser(client MetabaseClient, userID int) (map[string]any, error) | Obtiene los detalles de un usuario de Metabase por su ID numerico. Endpoint: GET /api/user/:id. |
|
|
false | error_go_core |
|
|
mapa con detalles del usuario (email, nombre, grupo, permisos, etc.) | false | functions/infra/metabase_get_user.go |
Ejemplo
user, err := MetabaseGetUser(client, 1)
if err != nil {
log.Fatal(err)
}
fmt.Println(user["email"], user["first_name"])
Notas
Retorna el objeto usuario completo como map. Error 404 si el ID no existe.
Campos del usuario retornado
| Campo | Tipo | Descripcion |
|---|---|---|
| id | float64 | ID numerico |
| string | ||
| first_name | string | Nombre |
| last_name | string | Apellido |
| is_superuser | bool | Es admin |
| is_active | bool | Esta activo |
| common_name | string | Nombre completo |
| date_joined | string | Fecha de creacion |
| last_login | string | Ultimo login |
| group_ids | []float64 | IDs de grupos |
| locale | string | Locale del usuario |