huly-api
SKILL.md
Huly API
Overview
Use this skill whenever swarm agents need durable communication in Huly:
trackertasks board (issues)chunterchannels (chat messages)documentteamspaces (mission docs)
Every autonomous mission should update all three surfaces. Default destinations for this workspace:
- Tracker issues board:
DefaultProject(https://huly.proompteng.ai/workbench/proompteng/tracker/tracker%3Aproject%3ADefaultProject/issues) - Documents teamspace:
PROOMPTENG - Chat channel URL:
https://huly.proompteng.ai/workbench/proompteng/chunter/chunter%3Aspace%3AGeneral%7Cchunter%3Aclass%3AChannel?message
Required Environment
Load credentials from the huly-api Kubernetes secret via AgentRun spec.secrets.
HULY_API_BASE_URL(should target transactor, for examplehttp://transactor.huly.svc.cluster.local)HULY_BASE_URL(optional human-facing base URL, oftenhttp://front.huly.svc.cluster.local)HULY_API_TOKEN(bearer token)- Optional:
HULY_WORKSPACE(workspace slug for operator context)HULY_WORKSPACE_ID(workspace UUID; helper can also infer from JWT)HULY_PROJECT(task board project identifier/name/id)HULY_TEAMSPACE(document teamspace name/id)HULY_CHANNEL(chat channel name/id)- per-agent tokens:
HULY_API_TOKEN_<SWARM_AGENT_IDENTITY>orHULY_API_TOKEN_<SWARM_AGENT_WORKER_ID>
Helper Script
Use scripts/huly-api.py.
Mandatory channel interaction loop
For every mission stage, run this in order:
- Read recent channel history:
python3 skills/huly-api/scripts/huly-api.py \
--operation list-channel-messages \
--worker-id "${SWARM_AGENT_WORKER_ID}" \
--worker-identity "${SWARM_AGENT_IDENTITY}" \
--require-worker-token \
--channel "${ACTIVE_HULY_CHANNEL}" \
--limit 30
- React to at least one relevant teammate message by posting a natural direct reply with decision impact in-thread:
python3 skills/huly-api/scripts/huly-api.py \
--operation post-channel-message \
--worker-id "${SWARM_AGENT_WORKER_ID}" \
--worker-identity "${SWARM_AGENT_IDENTITY}" \
--require-worker-token \
--channel "${ACTIVE_HULY_CHANNEL}" \
--reply-to-message-id "${RELEVANT_MESSAGE_ID}" \
--message "Thanks for the context. I picked this up and I am implementing X next."
- Post a worker-authored stage update after completing the mission action:
python3 skills/huly-api/scripts/huly-api.py \
--operation post-channel-message \
--worker-id "${SWARM_AGENT_WORKER_ID}" \
--worker-identity "${SWARM_AGENT_IDENTITY}" \
--require-worker-token \
--channel "${ACTIVE_HULY_CHANNEL}" \
--message "${OWNER_UPDATE_MESSAGE}"
Mission-level sync (recommended)
python3 skills/huly-api/scripts/huly-api.py \
--operation upsert-mission \
--worker-id "${SWARM_AGENT_WORKER_ID}" \
--worker-identity "${SWARM_AGENT_IDENTITY}" \
--mission-id jangar-discover-20260302 \
--title "Jangar discover cycle" \
--summary "Top platform risks and next actions" \
--details "Includes evidence, risk deltas, and PR links" \
--stage discover \
--status running \
--swarm-agent-worker-id "${SWARM_AGENT_WORKER_ID}" \
--swarm-agent-identity "${SWARM_AGENT_IDENTITY}" \
--message "${OWNER_UPDATE_MESSAGE}" \
--project "DefaultProject" \
--teamspace "PROOMPTENG" \
--channel "general"
This creates/updates:
- one task-board issue
- one mission document
- one channel message
Single-surface operations
python3 skills/huly-api/scripts/huly-api.py --operation create-issue --title "..." --mission-id "..."
python3 skills/huly-api/scripts/huly-api.py --operation create-document --title "..." --mission-id "..."
python3 skills/huly-api/scripts/huly-api.py --operation repair-project-issues --project "DefaultProject" --limit 500
python3 skills/huly-api/scripts/huly-api.py --operation repair-project-issues --project "DefaultProject" --limit 500 --fill-empty-issue-descriptions
python3 skills/huly-api/scripts/huly-api.py --operation dedupe-project-mission-issues --project "DefaultProject" --limit 1000 --dry-run
python3 skills/huly-api/scripts/huly-api.py --operation repair-teamspace-documents --teamspace "PROOMPTENG" --limit 500
python3 skills/huly-api/scripts/huly-api.py --operation post-channel-message --message "..."
python3 skills/huly-api/scripts/huly-api.py --operation post-channel-message --channel "general" --reply-to-message-id "<parent-message-id>" --message "In-thread reply"
python3 skills/huly-api/scripts/huly-api.py --operation list-channel-messages --channel "general" --limit 30
python3 skills/huly-api/scripts/huly-api.py --operation account-info --worker-id "${SWARM_AGENT_WORKER_ID}" --require-worker-token
python3 skills/huly-api/scripts/huly-api.py --operation verify-chat-access --worker-id "${SWARM_AGENT_WORKER_ID}" --worker-identity "${SWARM_AGENT_IDENTITY}" --require-worker-token --channel "general" --message "Hi team, I am starting this stage and will post progress here."
Raw HTTP mode (debug)
python3 skills/huly-api/scripts/huly-api.py --operation http --method GET --path /api/v1/account/<workspace-id>
Operating Rules
- Every mission stage must publish artifacts to all three Huly modules: tasks, channels, and docs.
- Each swarm agent should authenticate with its own Huly organization account (no shared actor credentials).
- Always target Tracker
DefaultProjectissues and DocsPROOMPTENGteamspace unless a run explicitly overrides them. - Resolve
ACTIVE_HULY_CHANNELdynamically from runtime context (preferswarmRequirementChannel, thenHULY_CHANNEL, then default). - Read channel history before taking action, then react to relevant teammate messages with explicit in-thread follow-up replies using
--reply-to-message-id. - Use
--require-worker-tokenfor dedicated-account checks so shared fallback tokens are rejected. - For strict identity mapping, set per-worker
HULY_EXPECTED_ACTOR_ID_<SWARM_AGENT_IDENTITY>and use--require-expected-actor-id. - Run
verify-chat-accessbefore autonomous delivery stages with a worker-authored--message. - Include
swarmAgentWorkerIdandswarmAgentIdentityin issue/document artifacts. - Keep channel messages human-readable by default; avoid appending metadata blocks.
- If you need metadata in chat for a specific audit/debug flow, use
--append-channel-metadata. upsert-missionautomatically infers these fields from--worker-id/--worker-identity(orSWARM_AGENT_WORKER_ID/SWARM_AGENT_IDENTITY) if explicit--swarm-agent-worker-id/--swarm-agent-identityflags are not provided.
- If you need metadata in chat for a specific audit/debug flow, use
- Keep channel updates concise, written by the worker, and linked to issue/doc/PR/deploy evidence.
- Issue descriptions must be long-form and knowledge-base quality. The helper now stores issue descriptions through collaborator refs (not raw inline markdown) so tracker descriptions reliably render and persist.
upsert-missionnow reuses existing mission issues by mission id prefix ([mission:<id>]) to avoid duplicate ticket creation.- Use
repair-project-issuesto migrate legacy issues that still have inline markdown/plain text inIssue.description. - Use
repair-project-issues --fill-empty-issue-descriptionswhen historical issues have truly empty description fields. - Use
dedupe-project-mission-issuesto move older duplicate mission issues toCanceledwhile keeping the most recent active issue. - Document content must be long-form and knowledge-base quality. The helper now stores mission document bodies through collaborator content refs (not raw inline markdown) so Huly editor/collaborator consistently loads and renders content.
- Use
repair-teamspace-documentsto migrate legacy docs that still have inline markdown inDocument.content. - If Huly auth fails, stop and return a clear unblock request instead of silently continuing.
Weekly Installs
16
Repository
proompteng/labGitHub Stars
6
First Seen
11 days ago
Security Audits
Installed on
cline16
gemini-cli16
github-copilot16
codex16
kimi-cli16
cursor16