Pricefx REST API Reference
Pricefx REST API
/Pricefx API Reference/- Syntax Check
Get a Logic
Get a Default Pricing Logic Name
Set a Default Pricing Logic
Update a Logic
Update a Logic (Partial)
Update a Logic (No syntax check)
List Elements
Execute an Assigned Logic
Execute a Logic
Delete a Logic
List Logics
Generate Parameters
List Logic Parameters (Input Fields)
List Libraries
Execute a Logic (Without a Context)
Execute a Logic Without a Context in a Service
Execute a Logic (Read-Only)
Execute a Logic Without a Context in a Service (Read-Only)
Copy a Logic
List Functions
Test a Logic
Execute Library Function
Syntax Check
The Pricefx Backend API
Download OpenAPI description
Overview
URL
Pricefx
Languages
Servers
Mock server
https://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi
URL:
https://{baseUrl}/pricefx/{partition}
Security
basic or X-PriceFx-jwt
JSON that represents the whole draft formula (the same format as used for the update command).
- Mock serverhttps://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.testparams
- URL:https://companynode.pricefx.com/pricefx/companypartition/formulamanager.testparams
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
-u <username>:<password> \
https://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.testparams \
-H 'Content-Type: application/json' \
-d '{
"data": {
"targetDate": "2021-12-10",
"item": "P0000012345",
"testFormula": {
"elements": [
{
"allowOverride": false,
"combinationType": "FUNCTION",
"displayOptions": 16,
"elementGroups": [],
"elementName": "NewElement",
"elementTimeout": 0,
"hideOnNull": false,
"hideWarnings": false,
"protectedExpression": false,
"summarize": false,
"formulaExpression": "api.inputBuilderFactory()\n .createStringUserEntry(\"MyStringParameter\")\n .getInput()"
}
],
"status": "ACTIVE",
"uniqueName": "admin",
"validAfter": "2020-01-01",
"__PROC": {
"sourceId": "CalculationLogic/MichalS+2020-01-01",
"typeCode": "F",
"fsId": "CalculationLogic/MichalS+2020-01-01",
"type": "CalculationLogic"
}
}
}
}'Response
application/json
{ "response": { "node": "string", "data": {}, "status": 0 } }
Request
Checks syntax for the provided logic fragment. As logic fragments (i.e. calculation schema entries or logic elements) can also reference previous logic element results, the parameter knownElements is available to declare a number of “names” as valid for the purpose of the syntax check.
Security
basic or X-PriceFx-jwt
- Mock serverhttps://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.check
- URL:https://companynode.pricefx.com/pricefx/companypartition/formulamanager.check
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
-u <username>:<password> \
https://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.check \
-H 'Content-Type: application/json' \
-d '{
"data": {
"formulaExpression": "api.inputBuilderFactory()\n .createStringUserEntry(\"MyStringParameter\")\n .getInput()",
"knownElements": [
"string",
"string"
]
}
}'Security
basic or X-PriceFx-jwt
- Mock serverhttps://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.params/{uniqueName}
- URL:https://companynode.pricefx.com/pricefx/companypartition/formulamanager.params/{uniqueName}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
-u <username>:<password> \
'https://api.pricefx.com/_mock/openapi/reference/pricefx-server_openapi/formulamanager.params/{uniqueName}'Response
application/json
{ "response": { "node": "string", "data": {}, "status": 0 } }
See the Key-Value Database Storage Knowledge Base article for more details.
Operations
Here you can find all fields of the corresponding entity (represented by the type code).
Use the /metadata.describe endpoint to find out the correct data type of the field that is used in your partition.
Comments