delete_rf_prediction
Delete a reach and frequency prediction in Meta Ads Manager. This action permanently removes the prediction.
Instructions
Delete a reach & frequency prediction. This action is irreversible.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prediction_id | Yes | Prediction ID to delete |
Implementation Reference
- src/tools/reach_frequency.ts:79-94 (handler)The actual handler function for the 'delete_rf_prediction' tool. It calls client.delete with the prediction_id and returns success/error response.
// ─── delete_rf_prediction ───────────────────────────────────── server.tool( "delete_rf_prediction", "Delete a reach & frequency prediction. This action is irreversible.", { prediction_id: z.string().describe("Prediction ID to delete"), }, async ({ prediction_id }) => { try { const { data, rateLimit } = await client.delete(`/${prediction_id}`); return { content: [{ type: "text" as const, text: JSON.stringify({ success: true, ...data as object, _rateLimit: rateLimit }, null, 2) }] }; } catch (error) { return { content: [{ type: "text" as const, text: `Failed: ${error instanceof Error ? error.message : String(error)}` }], isError: true }; } } ); - src/tools/reach_frequency.ts:83-85 (schema)Input schema for the 'delete_rf_prediction' tool: requires a single string parameter 'prediction_id'.
{ prediction_id: z.string().describe("Prediction ID to delete"), }, - src/tools/reach_frequency.ts:80-81 (registration)Registration of the tool via server.tool() with name 'delete_rf_prediction' and description 'Delete a reach & frequency prediction. This action is irreversible.'
server.tool( "delete_rf_prediction", - src/index.ts:83-83 (registration)Top-level registration: registerReachFrequencyTools(server, client) is called, which registers all reach/frequency tools including delete_rf_prediction.
registerReachFrequencyTools(server, client);