Execute Library Function

post/formulamanager.executelibraryfunction/{formulaName}/{elementName}/{functionName}

Executes a specific function from a formula library element without requiring a full formula logic implementation.
Parameters are provided via the request payload and the calculated result is returned.

Note:

  • This endpoint does not work with inputs bindings. Provide ordered function arguments instead.
  • Used by the Pricefx MCP server to enable Groovy-configured MCP Tools.
  • Requires the PRICINGFORMULA_EXECUTE permission.
Securitybasic or X-PriceFx-jwt
Request
path Parameters
formulaName
required
string

Name of the formula library containing the function.

elementName
required
string

Name of the library element containing the function.

functionName
required
string

Name of the function to execute.

Request Body schema: application/json
object
allowObjectMods
boolean

Specifies whether the logic may internally perform modifications. Defaults to false.

functionArgs
Array of any

An array of input arguments, that will be passed in order to the function call. Note, do not provide the parameter names, only the ordered literal values you want passed in.

Responses
200

OK

400

Bad request. Validation or execution error. Possible causes:

  • Missing or invalid path segments
  • Library formula not found
  • Formula exists but not of type LIBRARY
  • Library element not found within the logic
  • allowObjectMods has wrong type (must be a boolean)
  • functionArgs must be an array/list
  • An exception occurred during function execution
401

Unauthorized. Authentication required or failed.

403

Forbidden. Insufficient permissions. Requires PRICINGFORMULA_EXECUTE

500

Internal Server Error

Request samples
application/json
{
  • "data": {
    • "allowObjectMods": true,
    • "functionArgs": [
      • null
      ]
    }
}