Skip to main content
Glama

reactivate_agent

Reactivate a deactivated agent in the Lightning Wallet MCP server to restore its ability to manage Bitcoin Lightning payments and access paid APIs using the operator key.

Instructions

Reactivate a previously deactivated agent. REQUIRES OPERATOR KEY.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
agent_idYesAgent ID to reactivate

Implementation Reference

  • The actual implementation of the reactivateAgent method in the LightningFaucetClient class.
     * Reactivate an agent
     */
    async reactivateAgent(agentId: number): Promise<{
      agentId: number;
      message: string;
      rawResponse: ApiResponse;
    }> {
      const result = await this.request<ApiResponse & { message?: string }>('update_agent', {
        agent_id: agentId,
        updates: { is_active: true },
      });
    
      return {
        agentId,
        message: result.message || 'Agent reactivated',
        rawResponse: result,
      };
    }
  • The MCP tool handler for the 'reactivate_agent' tool, which calls the client method.
    case 'reactivate_agent': {
      const parsed = ReactivateAgentSchema.parse(args);
      const result = await session.requireClient().reactivateAgent(parsed.agent_id);
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify({
              success: true,
              message: result.message || 'Agent reactivated',
              agent_id: result.agentId,
            }, null, 2),
          },
        ],
      };
    }
  • Input validation schema for the 'reactivate_agent' tool.
    const ReactivateAgentSchema = z.object({
      agent_id: z.number().int().positive().describe('Agent ID to reactivate'),
    });
  • src/index.ts:571-580 (registration)
    Registration of the 'reactivate_agent' tool within the MCP server definition.
      name: 'reactivate_agent',
      description: 'Reactivate a previously deactivated agent. REQUIRES OPERATOR KEY.',
      inputSchema: {
        type: 'object',
        properties: {
          agent_id: { type: 'integer', description: 'Agent ID to reactivate' },
        },
        required: ['agent_id'],
      },
    },

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lightningfaucet/lightning-wallet-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server