multica-ai/multica · error · ErrRobotOwnedByArchivedAgent
dingtalk: this DingTalk robot is connected to an archived ag
Error message
dingtalk: this DingTalk robot is connected to an archived agent in this workspace
What it means
Error "dingtalk: this DingTalk robot is connected to an archived agent in this workspace" thrown in multica-ai/multica.
Source
Thrown at server/internal/integrations/dingtalk/install.go:44
// persistInstall transaction and the list / get / revoke management surface.
var (
// ErrInstallationNotFound surfaces "no row matches in this workspace".
ErrInstallationNotFound = errors.New("dingtalk installation not found")
// ErrRobotOwnedByAnotherWorkspace is returned when the pasted DingTalk robot
// is already connected to a live owner in a DIFFERENT Multica workspace — it
// would collide with the (channel_type, app_id) routing index. A DingTalk
// robot is one bot identity and maps to one installation/default agent;
// group-specific routes may target other agents inside that workspace.
ErrRobotOwnedByAnotherWorkspace = errors.New("dingtalk: this DingTalk robot is already connected to a different Multica workspace")
// ErrRobotOwnedBySameWorkspace is returned when the robot is already connected
// to a DIFFERENT (live, non-archived) agent in the SAME workspace, pointing
// the user at the Disconnect they can actually reach (#4810).
ErrRobotOwnedBySameWorkspace = errors.New("dingtalk: this DingTalk robot is already connected to another agent in this workspace")
// ErrRobotOwnedByArchivedAgent is returned when the robot's owning agent is
// archived (and so still holds the robot, since archiving is reversible). The
// user recovers by restoring that agent or disconnecting its robot.
ErrRobotOwnedByArchivedAgent = errors.New("dingtalk: this DingTalk robot is connected to an archived agent in this workspace")
)
// installQueries is the slice of generated queries InstallService needs. WithTx
// returns the same interface bound to a transaction so persistInstall runs its
// upsert atomically (and so tests can inject a fake without a real DB).
type installQueries interface {
WithTx(tx pgx.Tx) installQueries
LockDingTalkInstallationOwner(ctx context.Context, arg db.LockDingTalkInstallationOwnerParams) error
GetDingTalkInstallationOwnerForUpdate(ctx context.Context, arg db.GetDingTalkInstallationOwnerForUpdateParams) (db.GetDingTalkInstallationOwnerForUpdateRow, error)
DeleteDingTalkInstallationForReplacement(ctx context.Context, arg db.DeleteDingTalkInstallationForReplacementParams) (pgtype.UUID, error)
UpsertChannelInstallation(ctx context.Context, arg db.UpsertChannelInstallationParams) (db.ChannelInstallation, error)
ReclaimDeadChannelInstallationByAppID(ctx context.Context, arg db.ReclaimDeadChannelInstallationByAppIDParams) (pgtype.UUID, error)
GetChannelInstallationOwnerByAppID(ctx context.Context, arg db.GetChannelInstallationOwnerByAppIDParams) (db.GetChannelInstallationOwnerByAppIDRow, error)
ListChannelInstallationsByWorkspace(ctx context.Context, arg db.ListChannelInstallationsByWorkspaceParams) ([]db.ChannelInstallation, error)
GetChannelInstallationInWorkspace(ctx context.Context, arg db.GetChannelInstallationInWorkspaceParams) (db.ChannelInstallation, error)
SetChannelInstallationStatus(ctx context.Context, arg db.SetChannelInstallationStatusParams) error
}
View on GitHub (pinned to 2c0912b6ec)
Solutions
- Restore the archived agent or disconnect the robot from it before reconnecting.
When it happens
Trigger: Thrown at server/internal/integrations/dingtalk/install.go:44 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of multica-ai/multica@2c0912b6ec (2026-08-15).
Data as JSON: /api/errors/c96c41650f0844e8.
Report an issue: GitHub.