Skip to main content
Glama
scmdr

SourceSync.ai MCP Server

by scmdr

deleteNamespace

Permanently deletes a namespace by its ID to remove unused or obsolete organizational structures from the SourceSync.ai knowledge management platform.

Instructions

Permanently deletes a namespace by its ID.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
namespaceIdNo
tenantIdNo

Implementation Reference

  • src/index.ts:192-206 (registration)
    MCP server registration of the 'deleteNamespace' tool, including the input schema reference and the handler function that wraps the SourceSync client call in safeApiCall for error handling.
    server.tool(
      'deleteNamespace',
      'Permanently deletes a namespace by its ID.',
      deleteNamespaceSchema.shape,
      async (params: DeleteNamespaceParams) => {
        return safeApiCall(async () => {
          const { namespaceId, tenantId } = params
    
          // Create a client with the provided API key
          const client = createClient({ namespaceId, tenantId })
    
          return await client.deleteNamespace()
        })
      },
    )
  • Core implementation of the deleteNamespace method in the SourceSyncApiClient class, executing the HTTP DELETE request to the API endpoint /v1/namespaces/{namespaceId} using the configured wretch client.
    public async deleteNamespace(): Promise<SourceSyncDeleteNamespaceResponse> {
      return this.client
        .url(`/v1/namespaces/${this.namespaceId}`)
        .delete()
        .json<SourceSyncDeleteNamespaceResponse>()
    }
  • Zod schema defining the input parameters for the deleteNamespace tool: optional namespaceId and tenantId.
    export const deleteNamespaceSchema = z.object({
      namespaceId: namespaceIdSchema,
      tenantId: tenantIdSchema,
    })
  • TypeScript type definition for the API response of the deleteNamespace operation.
    export type SourceSyncDeleteNamespaceResponse = SourceSyncApiResponse<{
      identifier: string
    }>
  • Inferred TypeScript type for DeleteNamespaceParams from the Zod schema.
    export type DeleteNamespaceParams = z.infer<typeof deleteNamespaceSchema>
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure. It states the action is 'permanent', which is crucial for a destructive operation, but lacks details on permissions required, error conditions (e.g., if namespace doesn't exist), side effects, or response format. This leaves significant gaps for a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, direct sentence with no wasted words. It front-loads the key information ('permanently deletes') and is appropriately sized for the tool's complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive mutation tool with no annotations, 0% schema coverage, and no output schema, the description is insufficient. It lacks details on parameters, error handling, prerequisites, and behavioral context, making it incomplete for safe and effective use by an AI agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate but fails to do so. It mentions 'namespaceId' implicitly but doesn't explain its format or purpose. It omits 'tenantId' entirely, leaving both parameters undocumented. This is inadequate for a tool with two parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('permanently deletes') and resource ('a namespace by its ID'), making the purpose unambiguous. However, it doesn't differentiate from sibling tools like 'deleteDocuments' or 'revokeConnection', which also perform deletion operations on different resources.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., whether the namespace must be empty), contrast with similar tools like 'deleteDocuments' or 'revokeConnection', or specify conditions under which deletion is appropriate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/scmdr/sourcesyncai-mcp'

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