Skip to main content
Glama
get-estimate.ts1.38 kB
import { createAction, Property } from "@activepieces/pieces-framework"; import { housecallProAuth, makeHousecallProRequest } from "../common"; import { HttpMethod } from "@activepieces/pieces-common"; export const getEstimate = createAction({ auth: housecallProAuth, name: "get_estimate", displayName: "Get estimate by ID", description: "Retrieve a single estimate by ID", props: { estimate_id: Property.ShortText({ displayName: "Estimate ID", required: true, }), expand: Property.StaticMultiSelectDropdown({ displayName: "Expand", required: false, options: { options: [ { label: "customer", value: "customer" }, { label: "address", value: "address" }, { label: "assigned_employees", value: "assigned_employees" }, { label: "options", value: "options" }, { label: "attachments", value: "attachments" }, ], }, }), }, async run({ auth, propsValue }) { const queryParams: Record<string, string> = {}; if (propsValue["expand"] && propsValue["expand"].length) { queryParams["expand"] = propsValue["expand"].join(","); } const response = await makeHousecallProRequest( auth, `/estimates/${propsValue["estimate_id"]}`, HttpMethod.GET, undefined, queryParams ); 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