Skip to main content
Glama
Unstructured-IO

Unstructured API MCP Server

Official

update_weaviate_destination

Modify a Weaviate destination connector by updating its cluster URL or collection using the specified destination ID. Returns updated connector details for integration.

Instructions

Update an weaviate destination connector.

Args: destination_id: ID of the destination connector to update cluster_url (optional): URL of the weaviate cluster collection (optional): Name of the collection(like a file) to use in the weaviate cluster Returns: String containing the updated destination connector information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cluster_urlNo
collectionNo
destination_idYes

Implementation Reference

  • Core handler function that executes the update logic for Weaviate destination connectors by fetching current config, applying updates to cluster_url and/or collection, and invoking the client API to persist changes.
    async def update_weaviate_destination( ctx: Context, destination_id: str, cluster_url: Optional[str] = None, collection: Optional[str] = None, ) -> str: """Update an weaviate destination connector. Args: destination_id: ID of the destination connector to update cluster_url (optional): URL of the weaviate cluster collection (optional): Name of the collection(like a file) to use in the weaviate cluster Note: The collection is a table in the Weaviate cluster. In the platform, the collection name can be generated automatically; however, this is not yet supported via the API. Therefore, the collection name is required. Please note that the schema cannot be empty and must contain at least a record_id: Text. Returns: String containing the updated destination connector information """ client = ctx.request_context.lifespan_context.client # Get the current destination connector configuration try: get_response = await client.destinations.get_destination_async( request=GetDestinationRequest(destination_id=destination_id), ) current_config = get_response.destination_connector_information.config except Exception as e: return f"Error retrieving destination connector: {str(e)}" # Update configuration with new values config = dict(current_config) if cluster_url is not None: config["cluster_url"] = cluster_url if collection is not None: config["collection"] = collection destination_connector = UpdateDestinationConnector(config=config) try: response = await client.destinations.update_destination_async( request=UpdateDestinationRequest( destination_id=destination_id, update_destination_connector=destination_connector, ), ) result = create_log_for_created_updated_connector( response, connector_name="Weaviate", connector_type="Destination", created_or_updated="Updated", ) return result except Exception as e: return f"Error updating weaviate destination connector: {str(e)}"
  • Dispatch registration mapping the 'weaviate' destination type to the update_weaviate_destination handler function within the update_destination_connector tool.
    update_functions = { "astradb": update_astradb_destination, "databricks_delta_table": update_databricks_delta_table_destination, "databricks_volumes": update_databricks_volumes_destination, "mongodb": update_mongodb_destination, "neo4j": update_neo4j_destination, "pinecone": update_pinecone_destination, "s3": update_s3_destination, "weaviate": update_weaviate_destination, }
  • Registers the generic update_destination_connector tool with the MCP server, which internally dispatches to update_weaviate_destination for Weaviate updates.
    def register_destination_connectors(mcp: FastMCP): """Register all destination connector tools with the MCP server.""" mcp.tool()(create_destination_connector) mcp.tool()(update_destination_connector) mcp.tool()(delete_destination_connector)
  • Documentation defining the input schema for Weaviate-specific configuration updates in the update_destination_connector tool.
    weaviate: cluster_url: (Optional[str]): URL of the Weaviate cluster collection: (Optional[str]): Name of the collection in the Weaviate cluster

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/Unstructured-IO/UNS-MCP'

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