Skip to main content
Glama

mcp-google-sheets

add-page.ts1.55 kB
import { createAction, Property } from '@activepieces/pieces-framework'; import { HttpMethod, httpClient } from '@activepieces/pieces-common'; import { wonderchatAuth } from '../..'; export const addPage = createAction({ name: 'addPage', displayName: 'Add Page', description: 'Add new pages to your chatbot’s knowledge base.', auth: wonderchatAuth, props: { chatbotId: Property.ShortText({ displayName: 'Chatbot Id', description: 'The ID of your chatbot (can be found in the URL when viewing your bot: /bot/YOUR_BOT_ID)', required: true, }), urls: Property.Array({ displayName: 'URLs', description: 'List of webpage URLs to add to your chatbot\'s knowledge base (e.g., "https://wonderchat.io")', required: false, }), sessionCookie: Property.LongText({ displayName: 'Session cookie', description: 'Session cookie for crawling sites behind login', required: false, }), }, async run({ auth, propsValue }) { const apiKey = auth; const { chatbotId, urls, sessionCookie } = propsValue; const requestbody: any = { apiKey, chatbotId, }; if (sessionCookie) { requestbody.sessionCookie = sessionCookie; } if (urls) { requestbody.urls = urls; } const response = await httpClient.sendRequest({ method: HttpMethod.POST, url: 'https://app.wonderchat.io/api/v1/add-pages', headers: { 'Content-Type': 'application/json'}, body: requestbody, }); return response.body; }, });

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/activepieces/activepieces'

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