AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents
TypeScript ai-agentai-agent-toolsai-agentsai-agents-frameworkmcpmcp-servermcp-toolsmcpsn8n-alternativeno-code-automationworkflowworkflow-automationworkflows
import { HttpMethod } from '@activepieces/pieces-common';
import { createAction, Property } from '@activepieces/pieces-framework';
import { ampecoAuth } from '../../../common/auth';
import { handleApiError, makeAmpecoApiCall, prepareQueryParams, processPathParameters } from '../../../common/utils';
/**
* Generated from API version: 3.96.4
*/
// Endpoint: DELETE /public-api/resources/charge-points/v2.0/{chargePoint}/evses/{evse}
export const chargePointEvseDeleteAction = createAction({
auth: ampecoAuth,
name: 'chargePointEvseDelete',
displayName: 'Resources - Charge Points - Charge Point Evse Delete',
description: 'Delete an EVSE.',
audience: 'both',
aiMetadata: { description: 'Permanently delete an EVSE from a charge point, identified by charge point ID and EVSE ID. Destructive and not reversible; a repeat call on an already-deleted EVSE will fail rather than succeed silently.', idempotent: false },
props: {
chargePoint: Property.Number({
displayName: 'Charge Point',
required: true,
}),
evse: Property.Number({
displayName: 'Evse',
required: true,
}),
include: Property.StaticMultiSelectDropdown({
displayName: 'Include',
required: false,
options: {
options: [
{ label: 'chargingProfile', value: 'chargingProfile' },
{ label: 'connectors', value: 'connectors' }
],
},
}),
},
async run(context): Promise<unknown> {
try {
const url = processPathParameters('/public-api/resources/charge-points/v2.0/{chargePoint}/evses/{evse}', context.propsValue);
const queryParams = prepareQueryParams(context.propsValue, ['include']);
const body = undefined;
return await makeAmpecoApiCall(
context.auth,
url,
HttpMethod.DELETE,
body,
queryParams
) as unknown;
} catch (error) {
handleApiError(error);
}
},
});