Skip to main content
Glama

update-secret

Modify existing secrets in SecureCode's vault by updating values, descriptions, tags, or domains while maintaining encryption and audit logging.

Instructions

Update an existing secret's value, description, tags, or domain. Only provided fields are changed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesThe name of the secret to update
valueNoNew secret value (omit to keep current value)
descriptionNoNew description
tagsNoNew tags (replaces ALL existing tags)
domainNoNew domain
filterTagsNoFilter tags to disambiguate same-name secrets (different from the "tags" field which sets new tags)

Implementation Reference

  • Handler for the 'update-secret' tool. It uses the SecureCodeClient to update a secret's metadata or value and wraps the result for the MCP server.
    // Tool: update-secret
    server.tool(
      'update-secret',
      'Update an existing secret\'s value, description, tags, or domain. Only provided fields are changed.',
      {
        name: z.string().describe('The name of the secret to update'),
        value: z.string().optional().describe('New secret value (omit to keep current value)'),
        description: z.string().optional().describe('New description'),
        tags: z.record(z.string(), z.string()).optional().describe('New tags (replaces ALL existing tags)'),
        domain: z.string().optional().describe('New domain'),
        filterTags: z.record(z.string(), z.string()).optional().describe('Filter tags to disambiguate same-name secrets (different from the "tags" field which sets new tags)'),
      },
      async ({ name, value, description, tags, domain, filterTags }) => {
        try {
          const secret = await getClient().updateSecret(name, { value, description, tags, domain }, filterTags);
          return wrapResponse([{ type: 'text', text: `Secret "${secret.name}" updated successfully` }]);
        } catch (error) {
          return errorResult(error);
        }
      }
    );

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/juanisidoro/securecode-mcp'

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