Skip to main content
Glama

get_current_user

Retrieve the profile of the user associated with the current API key to verify identity and access permissions in MantisBT bug tracking.

Instructions

Retrieve the profile of the user associated with the current API key.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The 'get_current_user' tool is registered and implemented directly within the registerUserTools function in src/tools/users.ts. The handler logic performs an API call to 'users/me' using the MantisClient.
      server.registerTool(
        'get_current_user',
        {
          title: 'Get Current User',
          description: 'Retrieve the profile of the user associated with the current API key.',
          inputSchema: z.object({}),
          annotations: {
            readOnlyHint: true,
            destructiveHint: false,
            idempotentHint: true,
          },
        },
        async () => {
          try {
            const result = await client.get<MantisUser>('users/me');
            return {
              content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
            };
          } catch (error) {
            const msg = error instanceof Error ? error.message : String(error);
            return { content: [{ type: 'text', text: errorText(msg) }], isError: true };
          }
        }
      );
    }

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/dpesch/mantisbt-mcp-server'

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