> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # DeleteFunctionProduction # Package: functions # Namespace: FunctionProductions # Method link: https://dev.wix.com/docs/api-reference/business-management/functions/function-productions/delete-function-production.md ## Permission Scopes: Manage Functions: SCOPE.DC-FUNCTIONS.MANAGE-FUNCTIONS ## Introduction Deletes a function production and all its associated entities. --- ## REST API ### Schema ``` Method: deleteFunctionProduction Description: Deletes a function production and all its associated entities. URL: https://www.wixapis.com/functions/v1/function-productions/{functionProductionId} Method: DELETE # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: functionProductionId Method parameters: param name: functionProductionId | type: none | required: true Return type: DeleteFunctionProductionResponse EMPTY-OBJECT {} ``` ### Examples ### Delete Function Production ```curl curl --request DELETE \ https://www.wixapis.com/functions/v1/productions/ecab2bd0-daeb-449b-8dc4-0e1f12bbbfce \ --header "Content-Type: application/json" \ --header "Authorization: " ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.functions.FunctionProductions.deleteFunctionProduction(functionProductionId) Description: Deletes a function production and all its associated entities. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: functionProductionId Method parameters: param name: functionProductionId | type: string | description: GUID of the function production to delete. | required: true Return type: PROMISE EMPTY-OBJECT {} ``` ### Examples ### deleteFunctionProduction ```javascript import { functionProductions } from '@wix/functions'; async function deleteFunctionProduction(functionProductionId) { const response = await functionProductions.deleteFunctionProduction(functionProductionId); }; ``` ### deleteFunctionProduction (with elevated permissions) ```javascript import { functionProductions } from '@wix/functions'; import { auth } from '@wix/essentials'; async function myDeleteFunctionProductionMethod(functionProductionId) { const elevatedDeleteFunctionProduction = auth.elevate(functionProductions.deleteFunctionProduction); const response = await elevatedDeleteFunctionProduction(functionProductionId); } ``` ### deleteFunctionProduction (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { functionProductions } from '@wix/functions'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { functionProductions }, // Include the auth strategy and host as relevant }); async function deleteFunctionProduction(functionProductionId) { const response = await myWixClient.functionProductions.deleteFunctionProduction(functionProductionId); }; ``` ---