( resource: TextResourceContents | BlobResourceContents, )
| 138 | } |
| 139 | |
| 140 | function getResourceData( |
| 141 | resource: TextResourceContents | BlobResourceContents, |
| 142 | ): string { |
| 143 | if ('text' in resource) return resource.text as string |
| 144 | if ('blob' in resource) return resource.blob as string |
| 145 | return '' |
| 146 | } |
| 147 | |
| 148 | export async function callMCPTool( |
| 149 | clientId: string, |