Skip to main content
Glama
ambit1977

Google Tag Manager MCP Server

by ambit1977

reset_auth

Clear saved authentication credentials for the Google Tag Manager MCP Server to resolve connection issues or switch accounts.

Instructions

保存された認証情報をリセットします

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core implementation of resetAuth: deletes the saved token file and clears OAuth2 client credentials.
    async resetAuth() { if (existsSync(this.tokenPath)) { try { const fs = await import('fs/promises'); await fs.unlink(this.tokenPath); } catch (error) { // ファイル削除に失敗しても続行 } } this.oAuth2Client.setCredentials({}); return { success: true, message: '認証情報をリセットしました' }; }
  • MCP tool handler for 'reset_auth': retrieves OAuth2Auth instance from GTMClient and calls resetAuth(), returns result as text content.
    case 'reset_auth': { const oauth2Auth = this.gtmClient.getOAuth2Auth(); const result = await oauth2Auth.resetAuth(); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2), }, ], }; }
  • src/index.js:67-73 (registration)
    Tool registration in listTools response: defines 'reset_auth' tool with name, description, and empty input schema.
    name: 'reset_auth', description: '保存された認証情報をリセットします', inputSchema: { type: 'object', properties: {}, }, },
  • Input schema for reset_auth tool: empty object (no parameters required).
    type: 'object', properties: {}, }, },
  • Helper method in GTMClient to retrieve the OAuth2Auth instance used by the reset_auth handler.
    getOAuth2Auth() { return this.oauth2Auth; }

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/ambit1977/GTM-MCP'

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