ethora-app-update
Modify application details for the logged-in user, including display name, domain, description, color, and bot status, directly within the Ethora MCP Server platform.
Instructions
Updates the application fields for the logged-in user who has created the app.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| appDescription | No | Set the application description | |
| appId | Yes | appId for app | |
| botStatus | Yes | Set the bot status to on or off, if on bot is enabled | |
| displayName | No | displayName of the application | |
| domainName | No | If the domainName is set to 'abcd', your web application will be available at abcd.ethora.com. | |
| primaryColor | No | Set thie color of the application in #F54927 format |
Implementation Reference
- src/tools.ts:151-181 (handler)The handler function for the 'ethora-app-update' MCP tool. It conditionally builds a changes object from optional input parameters and calls the appUpdate API function, returning the result or error.async function ({ appId, displayName, domainName, appDescription, primaryColor, botStatus }) { try { let changes: any = {} if (displayName) { changes.displayName = displayName } if (domainName) { changes.domainName = domainName } if (appDescription) { changes.appDescription = appDescription } if (primaryColor) { changes.primaryColor = primaryColor } if (botStatus) { changes.botStatus = botStatus } let result = await appUpdate(appId, changes) let toolRes: CallToolResult = { content: [{ type: "text", text: JSON.stringify(result.data) }] } return toolRes } catch (error) { let toolRes: CallToolResult = { content: [{ type: "text", text: "error: network error" }] } return toolRes } }
- src/tools.ts:142-149 (schema)Zod input schema defining the parameters for the 'ethora-app-update' tool: required appId and optional fields for updating app properties.inputSchema: { appId: z.string().describe("appId for app"), displayName: z.string().optional().describe("displayName of the application"), domainName: z.string().optional().describe("If the domainName is set to 'abcd', your web application will be available at abcd.ethora.com."), appDescription: z.string().optional().describe("Set the application description"), primaryColor: z.string().optional().describe("Set thie color of the application in #F54927 format"), botStatus: z.enum(["on", "off"]).describe("Set the bot status to on or off, if on bot is enabled") }
- src/tools.ts:138-150 (registration)Registration of the 'ethora-app-update' tool using server.registerTool, including description and input schema.server.registerTool( 'ethora-app-update', { description: 'Updates the application fields for the logged-in user who has created the app.', inputSchema: { appId: z.string().describe("appId for app"), displayName: z.string().optional().describe("displayName of the application"), domainName: z.string().optional().describe("If the domainName is set to 'abcd', your web application will be available at abcd.ethora.com."), appDescription: z.string().optional().describe("Set the application description"), primaryColor: z.string().optional().describe("Set thie color of the application in #F54927 format"), botStatus: z.enum(["on", "off"]).describe("Set the bot status to on or off, if on bot is enabled") } },
- src/apiClientDappros.ts:138-143 (helper)Helper function appUpdate that makes the HTTP PUT request to update the app via the API client.export function appUpdate(appId: string, changes: any) { return httpClientDappros.put( `/apps/${appId}`, changes ) }
- src/index.ts:13-13 (registration)Top-level call to registerTools which includes registration of 'ethora-app-update'.registerTools(server);