← Back to Skills Marketplace
udaymanish6

OpenClaw Restart Resume

by udaymanish6 · GitHub ↗ · v1.0.3 · MIT-0
cross-platform ✓ Security Clean
59
Downloads
1
Stars
0
Active Installs
4
Versions
Install in OpenClaw
/install gateway-restart-resume
Description
Use when an OpenClaw agent is asked from any gateway-backed medium to restart, stop, reload, update, or repair the gateway and the agent must reply again aft...
README (SKILL.md)

OpenClaw Restart Resume

GitHub: https://github.com/udaymanish6/openclaw-restart-resume

ClawHub: https://clawhub.ai/udaymanish6/gateway-restart-resume

Overview

Gateway restart is a conversation-continuity problem. An in-gateway OpenClaw agent that restarts the gateway kills the runtime that would normally send the follow-up reply. Before taking any gateway-killing action, create a durable resume path that can verify recovery and report back through the same medium, conversation, channel, thread, or user route.

When to Use

Use this skill when:

  • A user asks through Discord, Slack, Matrix, SMS, email, web chat, CLI relay, ACP, cron, or another OpenClaw-backed medium to restart, stop, reload, update, or repair the gateway.
  • The action may stop the gateway, restart the service manager, reload plugins, or replace the running OpenClaw package.
  • The agent is running inside OpenClaw, or may be running inside OpenClaw.
  • The user expects a post-restart status reply.

Do not use this skill for external shell operators that can survive the restart themselves, except as a checklist for user-facing notifications.

Restart Resume Protocol

  1. Classify execution context.

    • If running inside OpenClaw, assume the restart will terminate the current turn.
    • If running outside OpenClaw, still use the notification and verification steps when the request came from a user-facing channel.
  2. Confirm permission.

    • If the user did not explicitly ask for restart/stop/update, ask first.
    • Do not restart for vague requests such as "fix it" until the restart is explained and approved.
  3. Capture reply target.

    • Record the medium, account/profile if relevant, conversation id, channel id, thread id, message id, user id if needed, and agent id.
    • Prefer the exact original route. If the medium has no thread concept, record the smallest addressable conversation target.
    • Store only routing metadata needed to reply. Do not store raw message bodies, tokens, env contents, or secrets.
  4. Send pre-restart acknowledgement.

    • Tell the user the gateway is restarting and that a follow-up will be sent after verification.
    • Keep it short because the gateway may stop immediately afterward.
  5. Create durable resume callback before restart.

    • Prefer a one-shot or short-delay OpenClaw cron job, task, or native gateway callback that survives the gateway restart.
    • The callback must include the reply target and verification checklist.
    • If callback creation fails, do not restart. Tell the user the restart was not attempted because no follow-up path exists.
  6. Restart only after the callback exists.

    • Use the narrowest approved restart action.
    • Avoid broad update/reinstall operations unless the user requested them and the current admin runbook supports them.
  7. Resume callback verifies recovery.

    • Check gateway/service status.
    • Check health endpoint or gateway probe.
    • Check connectivity or send capability for the original medium when the local OpenClaw version supports it.
    • Check plugin or task health only when relevant to the restart reason.
  8. Send final reply.

    • Reply in the original medium and conversation/thread when available.
    • Use the operator report format below unless the original medium requires a shorter message.
    • State whether restart completed, what was verified, duration if known, and any remaining warning.
    • If verification fails, report the failed check and the safest next action.

Medium-Agnostic Reply Rules

  • Discord/Slack/Matrix: reply in the original thread when available; otherwise reply in the original channel/conversation.
  • SMS/chat apps: keep the final message compact and avoid multi-line technical detail unless the user asked for it.
  • Email: include a concise subject-like first line, then the verification report.
  • CLI relay or ACP: return structured status when the caller expects JSON/tool output; include human-readable summary when routed to a person.
  • Cron or automation-triggered restarts: send the final report to the configured notification target and record the result in durable run history if available.
  • If the original medium is unavailable after restart, use the configured fallback notification target only when policy allows it; otherwise leave a durable ops note for the operator.

Resume Payload

The durable callback should carry a minimal payload:

{
  "reason": "user-requested gateway restart",
  "agentId": "\x3Cagent-id>",
  "reply": {
    "medium": "\x3Cdiscord|slack|matrix|sms|email|web|cli|acp|cron|other>",
    "account": "\x3Caccount-id-if-needed>",
    "target": "\x3Cconversation-or-addressable-target>",
    "channelId": "\x3Cchannel-id-if-needed>",
    "threadId": "\x3Cthread-id-if-needed>",
    "userId": "\x3Cuser-id-if-needed>",
    "messageId": "\x3Coriginal-message-id-if-needed>"
  },
  "verify": [
    "gateway status",
    "health",
    "original medium connectivity"
  ],
  "createdAt": "\x3Ciso-timestamp>"
}

Sanitize or omit fields that are not needed for routing. Never include secrets, full config, env files, transcript bodies, or private message contents.

Verification Checklist

Use the local OpenClaw version's native tools when available. Equivalent checks are acceptable.

openclaw gateway status
openclaw health
openclaw channels status --probe

When the restart was part of an update or plugin repair, also verify the relevant narrow checks, for example:

openclaw doctor --non-interactive --no-workspace-suggestions
openclaw plugins doctor
openclaw tasks audit

Do not claim the restart succeeded unless fresh verification output supports it.

Failure Handling

  • Callback creation fails: do not restart; explain that there is no durable way to report back.
  • Restart command fails before shutdown: report the command failure immediately in the current medium.
  • Gateway returns but the original medium is disconnected: report through any still-available approved fallback route, or leave a durable task/ops note for the operator.
  • Gateway does not return: the callback should record the failure in durable state and stop retrying after a bounded number of attempts.
  • Auth/token errors appear: do not read or paste secrets. Report the config path/key names only and ask for explicit operator direction.

Common Mistakes

  • Restarting first and trying to schedule the follow-up afterward.
  • Treating "gateway command returned" as proof that the original medium recovered.
  • Storing raw messages or secret-bearing config in the resume payload.
  • Creating a repeating cron when a one-shot callback is enough.
  • Retrying forever after a failed restart.
  • Sending the final reply to a default destination instead of the original medium/conversation/thread.

Output Message Format

Prefer this operator report for human-facing media that can handle multi-line messages.

Before restart:

Restarting the OpenClaw gateway now.
I created a resume check and will reply here after the gateway is back and verified.

After success:

Gateway restart complete.

Verified:
- Gateway: \x3Crunning/admin-capable/version if known>
- Health: \x3Cok/degraded>
- Original medium: \x3Cconnected/reply sent/not directly testable>
- Extra checks: \x3Cplugins/tasks/update checks or "not needed">

Duration: \x3Cduration or "not recorded">
Warnings: \x3Cnone or short warning>
Next action: \x3Cnone or operator action>

After degraded recovery:

Gateway restart completed, but verification is degraded.

Passed:
- \x3Cpassed check>

Needs attention:
- \x3Cfailed or warning check>

I did not take further action automatically. Safest next action: \x3Cnext step>.

After failure:

Gateway restart did not verify cleanly.

Failed check: \x3Ccheck>
Last known state: \x3Cstate>
Safest next action: \x3Cnext step>
Usage Guidance
Install this only for OpenClaw environments where agents are allowed to help with gateway restarts. Operators should still require explicit restart approval, use the narrowest restart action, keep the resume callback one-shot and bounded, and ensure no secrets or message contents are stored in the callback payload.
Capability Assessment
Purpose & Capability
The stated purpose is to preserve user communication across a gateway restart, and the artifact instructions match that purpose by requiring acknowledgement, a durable callback, verification, and a final status reply.
Instruction Scope
The skill explicitly requires user permission for restart, rejects vague restart authority, limits stored data to routing metadata, and warns against storing secrets, raw messages, env contents, or transcripts.
Install Mechanism
The package contains only markdown and a small YAML agent prompt file; install instructions use the normal clawhub install flow and there are no scripts, dependencies, or executable files.
Credentials
The operational context is high impact because gateway restart, update, and plugin repair can disrupt service, but that authority is disclosed, user-directed, and framed as a protocol rather than automatic execution.
Persistence & Privilege
The skill recommends a one-shot or short-delay durable callback to report after restart; this is purpose-aligned and bounded, with explicit guidance not to create repeating cron jobs or retry forever.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install gateway-restart-resume
  3. After installation, invoke the skill by name or use /gateway-restart-resume
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.3
Add visible GitHub repository links to README and skill metadata.
v1.0.2
Add public README with use-case context, install link, and community star request.
v1.0.1
Make restart resume protocol medium-agnostic and add structured operator report output templates.
v1.0.0
Initial standalone protocol for OpenClaw gateway restart follow-up callbacks.
Metadata
Slug gateway-restart-resume
Version 1.0.3
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 4
Frequently Asked Questions

What is OpenClaw Restart Resume?

Use when an OpenClaw agent is asked from any gateway-backed medium to restart, stop, reload, update, or repair the gateway and the agent must reply again aft... It is an AI Agent Skill for Claude Code / OpenClaw, with 59 downloads so far.

How do I install OpenClaw Restart Resume?

Run "/install gateway-restart-resume" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is OpenClaw Restart Resume free?

Yes, OpenClaw Restart Resume is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does OpenClaw Restart Resume support?

OpenClaw Restart Resume is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created OpenClaw Restart Resume?

It is built and maintained by udaymanish6 (@udaymanish6); the current version is v1.0.3.

💬 Comments