Skip to main content
Glama
umzcio
by umzcio

tdx-ticket-create

Create new tickets in TeamDynamix for IT service management, specifying type, title, priority, responsible parties, and custom attributes.

Instructions

Create a new TDX ticket

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
appIdNoTDX app ID (defaults to env TDX_APP_ID)
typeIdYesTicket type ID
titleYesTicket title
descriptionNoTicket description (HTML)
accountIdNoAccount/department ID
priorityIdNoPriority ID
statusIdNoStatus ID
requestorUidNoRequestor person UID
responsibleUidNoResponsible person UID
responsibleGroupIdNoResponsible group ID
formIdNoForm ID
sourceIdNoSource ID
serviceIdNoService ID
goesOffHoldDateNoISO date when ticket goes off hold
attributesNoCustom attributes

Implementation Reference

  • The handler for tdx-ticket-create which prepares the request body and calls the TDX client.
    async (params) => {
      const app = params.appId ?? defaultAppId;
      const body: Record<string, unknown> = {
        TypeID: params.typeId,
        Title: params.title,
      };
      if (params.description !== undefined) body.Description = params.description;
      if (params.accountId !== undefined) body.AccountID = params.accountId;
      if (params.priorityId !== undefined) body.PriorityID = params.priorityId;
      if (params.statusId !== undefined) body.StatusID = params.statusId;
      if (params.requestorUid !== undefined) body.RequestorUid = params.requestorUid;
      if (params.responsibleUid !== undefined) body.ResponsibleUid = params.responsibleUid;
      if (params.responsibleGroupId !== undefined) body.ResponsibleGroupID = params.responsibleGroupId;
      if (params.formId !== undefined) body.FormID = params.formId;
      if (params.sourceId !== undefined) body.SourceID = params.sourceId;
      if (params.serviceId !== undefined) body.ServiceID = params.serviceId;
      if (params.goesOffHoldDate !== undefined) body.GoesOffHoldDate = params.goesOffHoldDate;
      if (params.attributes) {
        body.Attributes = params.attributes.map((a) => ({ ID: a.id, Value: String(a.value) }));
      }
      try {
        const result = await client.post(`/${app}/tickets`, body);
        return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
      } catch (e: unknown) {
        return { content: [{ type: "text", text: String(e) }], isError: true };
      }
    }
  • The Zod schema definition for the input parameters of tdx-ticket-create.
    {
      appId: z.number().optional().describe("TDX app ID (defaults to env TDX_APP_ID)"),
      typeId: z.number().describe("Ticket type ID"),
      title: z.string().describe("Ticket title"),
      description: z.string().optional().describe("Ticket description (HTML)"),
      accountId: z.number().optional().describe("Account/department ID"),
      priorityId: z.number().optional().describe("Priority ID"),
      statusId: z.number().optional().describe("Status ID"),
      requestorUid: z.string().optional().describe("Requestor person UID"),
      responsibleUid: z.string().optional().describe("Responsible person UID"),
      responsibleGroupId: z.number().optional().describe("Responsible group ID"),
      formId: z.number().optional().describe("Form ID"),
      sourceId: z.number().optional().describe("Source ID"),
      serviceId: z.number().optional().describe("Service ID"),
      goesOffHoldDate: z.string().optional().describe("ISO date when ticket goes off hold"),
      attributes: z.array(z.object({
        id: z.number().describe("Custom attribute ID"),
        value: z.union([z.string(), z.number(), z.boolean()]).describe("Attribute value"),
      })).optional().describe("Custom attributes"),
    },
  • Registration of the tdx-ticket-create tool on the MCP server.
    server.tool(
      "tdx-ticket-create",
      "Create a new TDX ticket",
      {
        appId: z.number().optional().describe("TDX app ID (defaults to env TDX_APP_ID)"),
        typeId: z.number().describe("Ticket type ID"),
        title: z.string().describe("Ticket title"),
        description: z.string().optional().describe("Ticket description (HTML)"),
        accountId: z.number().optional().describe("Account/department ID"),
        priorityId: z.number().optional().describe("Priority ID"),
        statusId: z.number().optional().describe("Status ID"),
        requestorUid: z.string().optional().describe("Requestor person UID"),
        responsibleUid: z.string().optional().describe("Responsible person UID"),
        responsibleGroupId: z.number().optional().describe("Responsible group ID"),
        formId: z.number().optional().describe("Form ID"),
        sourceId: z.number().optional().describe("Source ID"),
        serviceId: z.number().optional().describe("Service ID"),
        goesOffHoldDate: z.string().optional().describe("ISO date when ticket goes off hold"),
        attributes: z.array(z.object({
          id: z.number().describe("Custom attribute ID"),
          value: z.union([z.string(), z.number(), z.boolean()]).describe("Attribute value"),
        })).optional().describe("Custom attributes"),
      },
      async (params) => {
        const app = params.appId ?? defaultAppId;
        const body: Record<string, unknown> = {
          TypeID: params.typeId,
          Title: params.title,
        };
        if (params.description !== undefined) body.Description = params.description;
        if (params.accountId !== undefined) body.AccountID = params.accountId;
        if (params.priorityId !== undefined) body.PriorityID = params.priorityId;
        if (params.statusId !== undefined) body.StatusID = params.statusId;
        if (params.requestorUid !== undefined) body.RequestorUid = params.requestorUid;
        if (params.responsibleUid !== undefined) body.ResponsibleUid = params.responsibleUid;
        if (params.responsibleGroupId !== undefined) body.ResponsibleGroupID = params.responsibleGroupId;
        if (params.formId !== undefined) body.FormID = params.formId;
        if (params.sourceId !== undefined) body.SourceID = params.sourceId;
        if (params.serviceId !== undefined) body.ServiceID = params.serviceId;
        if (params.goesOffHoldDate !== undefined) body.GoesOffHoldDate = params.goesOffHoldDate;
        if (params.attributes) {
          body.Attributes = params.attributes.map((a) => ({ ID: a.id, Value: String(a.value) }));
        }
        try {
          const result = await client.post(`/${app}/tickets`, body);
          return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
        } catch (e: unknown) {
          return { content: [{ type: "text", text: String(e) }], isError: true };
        }
      }
    );

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/umzcio/TeamDynamix-MCP-Connector'

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