user-info
The user-info skill retrieves the current session user's profile information including name, position, email, phone, and department details via the `get_user_info` function. Use this skill when you need to access authenticated user data within a session, with phone numbers desensitized by default unless explicit user consent is obtained first.
git clone --depth 1 https://github.com/dtyq/magic /tmp/user-info && cp -r /tmp/user-info/backend/super-magic/agents/skills/user-info ~/.claude/skills/user-infoSKILL.md
# User Info Skill
Retrieve the current session user's profile via `get_user_info`.
---
## Basic Usage
```python
from sdk.tool import tool
result = tool.call("get_user_info", {})
print(result.content)
```
Example output:
```
User: Zhang San. Position: Engineering Lead. Work Number: 10086. Email: zhang@example.com. Phone: 138****0000 (desensitized). Departments: Engineering, Architecture.
```
For structured access, use `result.data`:
| Field | Type | Notes |
|-------|------|-------|
| `id` | string | User ID |
| `nickname` | string | Display name |
| `real_name` | string | Legal name |
| `work_number` | string | Employee number (may be empty) |
| `position` | string | Job title |
| `email` | string | Email address |
| `phone` | string | Phone, desensitized by default (e.g. `138****0000`) |
| `departments` | array | Each item: `{id, name, path}` |
---
## Getting the Full Phone Number
Phone is masked by default to protect privacy. To get the full number, you must first ask for explicit user consent.
**Step 1 — Ask for consent:**
```python
from sdk.tool import tool
result = tool.call("ask_user", {
"questions": '<question type="confirm">I need your full phone number to proceed. Do you allow me to access it?</question>'
})
print(result.content)
```
**Step 2 — If the user consents, request the full number:**
```python
result = tool.call("get_user_info", {
"include_sensitive_fields": ["phone"]
})
print(result.content)
```
**If the user declines:** use the desensitized value or drop the requirement. Do not ask again.
---
## Constraints
- Never pass `include_sensitive_fields` without prior explicit user approval in the same conversation.
- Do not retry after a user refuses access to sensitive fields.
- Use the desensitized phone value for display, logging, or non-critical tasks where the full number is not strictly needed.Query the list of all agents (employees) available to the current user. Use when generating code that requires a real agentId, or when the user asks "which agents/employees do I have".
|
Migrate existing antd-style CSS-in-JS (createStyles) components to Tailwind CSS utility classes with full dark mode support, following the project's style system transition strategy. Use when the user asks to migrate, convert, or rewrite antd-style components to Tailwind, or when working on new components in files that already use antd-style.
Open and operate webpages in a real browser: navigate, read rendered content, inspect interactive elements, click, type, submit forms, press keys, select options, check boxes, hover, scroll, upload files, wait for page changes, manage pages, take and save screenshots, analyze visual layout, and inspect page errors and network activity.
Core canvas design skill covering project management, multimedia principles, AI image generation, web image search, and design marker processing. Load for any canvas design task. CRITICAL - When user message contains [@design_canvas_project:...] or [@design_marker:...] mentions, or when the user wants to generate video/animation/clip on a canvas project, you MUST load this skill first before any operations.
Use when details may have been lost after context compaction, or when the Agent needs to inspect earlier compacted messages or previously created sub-agents.
Manage persistence for user-installed third-party CLI tools in the Super Magic sandbox. Use when the user wants to install, configure, adopt, restore, inspect, or remove a CLI, or when an external skill, webpage, or installer asks to run CLI install commands such as curl|sh, npm install -g, pipx install, uv tool install, go install, cargo install, or brew install. Do not persist runtime-provided CLIs.
Expert code review of current git changes with a senior engineer lens. Detects SOLID violations, security risks, and proposes actionable improvements.