Skip to main content
Glama

update_card

Modify existing Trello card details including name, description, due date, status, position, or archive status to keep project tasks current and organized.

Instructions

Update properties of an existing Trello card. Use this to change card details like name, description, due date, or status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
apiKeyYesTrello API key (automatically provided by Claude.app from your stored credentials)
tokenYesTrello API token (automatically provided by Claude.app from your stored credentials)
cardIdYesID of the card to update (you can get this from board details or card searches)
nameNoNew name/title for the card
descNoNew description for the card
closedNoSet to true to archive the card, false to unarchive
dueNoSet due date (ISO 8601 format) or null to remove due date
dueCompleteNoMark the due date as complete (true) or incomplete (false)
idListNoMove card to a different list by providing the list ID
posNoChange position in the list: "top", "bottom", or specific number

Implementation Reference

  • The handler function for updating a Trello card, which validates inputs and calls the Trello client.
    export async function handleUpdateCard(args: unknown) {
      try {
        const updateData = validateUpdateCard(args);
        const { apiKey, token, cardId, ...updates } = updateData;
        
        const client = new TrelloClient({ apiKey, token });
        const response = await client.updateCard(cardId, updates);
        const card = response.data;
        
        const result = {
          summary: `Updated card: ${card.name}`,
          card: {
            id: card.id,
            name: card.name,
            description: card.desc || 'No description',
            url: card.shortUrl,
            listId: card.idList,
            boardId: card.idBoard,
            position: card.pos,
            due: card.due,
            dueComplete: card.dueComplete,
            closed: card.closed,
            labels: card.labels?.map(label => ({
              id: label.id,
  • Schema definition for validating the update_card input arguments.
    export const updateCardSchema = z.object({
      apiKey: z.string().min(1, 'API key is required'),
      token: z.string().min(1, 'Token is required'),
      cardId: trelloIdSchema,
      name: z.string().min(1).max(16384).optional(),
      desc: z.string().max(16384).optional(),
      closed: z.boolean().optional(),
      due: z.string().datetime().nullable().optional(),
      dueComplete: z.boolean().optional(),
      idList: trelloIdOptionalSchema,
      pos: z.union([z.number().min(0), z.enum(['top', 'bottom'])]).optional(),
      idMembers: z.array(trelloIdSchema).optional(),
      idLabels: z.array(trelloIdSchema).optional()
    });
  • Definition and registration of the update_card tool.
    export const updateCardTool: Tool = {
      name: 'update_card',
      description: 'Update properties of an existing Trello card. Use this to change card details like name, description, due date, or status.',
      inputSchema: {
        type: 'object',
        properties: {
          apiKey: {
            type: 'string',
            description: 'Trello API key (automatically provided by Claude.app from your stored credentials)'
          },
          token: {
            type: 'string',
            description: 'Trello API token (automatically provided by Claude.app from your stored credentials)'
          },
          cardId: {
            type: 'string',
            description: 'ID of the card to update (you can get this from board details or card searches)',
            pattern: '^[a-f0-9]{24}$'
          },
          name: {
            type: 'string',
            description: 'New name/title for the card'
          },
          desc: {
            type: 'string',
            description: 'New description for the card'
          },
          closed: {
            type: 'boolean',
            description: 'Set to true to archive the card, false to unarchive'
          },
          due: {
            type: ['string', 'null'],
            format: 'date-time',
            description: 'Set due date (ISO 8601 format) or null to remove due date'
          },
          dueComplete: {
            type: 'boolean',
            description: 'Mark the due date as complete (true) or incomplete (false)'
          },
          idList: {
            type: 'string',
            description: 'Move card to a different list by providing the list ID',
            pattern: '^[a-f0-9]{24}$'
          },
          pos: {
            oneOf: [
              { type: 'number', minimum: 0 },
              { type: 'string', enum: ['top', 'bottom'] }
            ],
            description: 'Change position in the list: "top", "bottom", or specific number'
          }
        },
        required: ['apiKey', 'token', 'cardId']
      }
    };

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/kocakli/Trello-Desktop-MCP'

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