Browse documentation

get_type_info

[analysis]

Gets detailed information about a type (members, inheritance, interfaces, docs, and location).

Try it locally in the Glider playground

Parameters

NameTypeRequiredDescription
typeNamestringNoType name (simple or fully qualified). Provide this or symbolKey.
symbolKeystringNoA key returned by find_code. Pass it unchanged. Provide this or typeName.
projectNamestringNoOptional project name filter.
includeMembersbooleanNoInclude member list in response. Default is true. Default: true
maxMembersnumberNoMaximum number of members to return. Default is 100. Default: 100
memberKindsstringNoFilter members by kind, comma-separated: 'Method', 'Property', 'Field', 'Event', or 'Constructor'.
pathStylestringNoPath style: 'absolute' (default) or 'relative' (to solution root). Default: "absolute"
responseDetailstringNocompact returns results and actionable state. full adds diagnostic metadata under responseDiagnostics. Default: "compact"

Examples

Replace sample paths and symbol keys with values from your workspace.

Get type info

Arguments
{
  "typeName": "UserService"
}
Full MCP request
Full MCP request
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_type_info",
    "arguments": {
      "typeName": "UserService"
    }
  }
}
Illustrative response
{
  "success": true,
  "name": "UserService",
  "fullName": "Acme.App.Services.UserService",
  "kind": "Class",
  "accessibility": "Public",
  "baseType": "BaseService",
  "declaredBaseType": null,
  "interfaces": [
    "IUserService"
  ],
  "filePath": "/path/to/UserService.cs",
  "lineNumber": 10,
  "members": [
    {
      "name": "GetUserAsync",
      "kind": "Method",
      "type": "Task",
      "accessibility": "Public",
      "signature": "Task GetUserAsync(int userId)"
    }
  ]
}

Response Notes

Returns type details including members and inheritance. declaredBaseType names the base a class declares when the compiler rejected it (an illegal base), otherwise null. If a key does not resolve, discover the type again with find_code. Results use top-level fields with success. Compact is the default; full adds responseDiagnostics. Both modes retain errors, coverage, partial state, and recovery advice.

For a failed symbol-key request, success=false includes errorCode, parameter, error, and suggestions in compact, full, and batch operation results. Batch keeps a bounded summary outside the requested detail budget. If the hard server limit omits details, failureDetailsOmitted or writeStateOmitted identifies the omission. errorCode is invalid_symbol_key, symbol_not_found, ambiguous_symbol_key, wrong_symbol_kind, source_unavailable, unsupported_symbol, or invalid_arguments. Follow the suggestions for the specific failure. Correct the named selector for invalid_arguments. For symbol_not_found, repeat discovery in the selected workspace and pass a returned key unchanged. An absent identity does not prove that a key is stale.