# Products ## Insert Bulk Products - [POST /loaddata/P](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-loaddata-p.md): Inserts multiple products to the Master Data table. The /loaddata operation is a very efficient and quick way to insert bulk data to the Master Data table. The main advantage is its greater speed when loading thousands of records (compared to e.g. /integrate). Use the ISO 8601 date format (YYYY-MM-DD) if a date is included in the table. >Please note: > If no joinFields are provided in the request, then this operation will insert entire records. It means that in this case (without joinFields) with /loaddata it is not possible to update just some fields (for this use the /integrate endpoint instead). The source data must always contain the entire row’s content. ## Upsert a Product - [POST /integrate/P](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-integrate-type-code.md): Upserts a product. - To add a new product that does not exist, specify the sku parameter in the request. - To update an existing product, specify the sku or typedId parameter of the existing product. The /integrate method performs a partial update – it does not delete values from fields that have not been specified in the update request. Use the /integrate/{TypeCode}/returnolddata endpoint to return also the data of the previous version in the response. --- > Please note: >This method is intended to be used with one or two objects and it allows you to update particular fields. The request will overwrite the existing data of the record being updated, regardless of other changes. >To work with more products in bulk please use the /loaddata/P endpoint. --- This operation is particularly useful if the caller does not (and should not) know about typed IDs and other internal data fields, i.e. typically in an integration scenario. The only mandatory pre-requisite for this operation is that the object's defined business key fields (vary per object type) are present in every request. No typed ID or version fields are required. This also means that no version checking is performed, thus the request will overwrite existing data of that record, regardless of other changes. >Information: >You can upsert multiple records using one request. To do so, add multiple data objects into your JSON. See the example below. json [ { "data": { "sku": "111111", "typedId": "2147501227.P", "label": "The New Label", "unitOfMeasure": "EA", "currency": "USD", "formulaName": "priceLogic2", "attribute1": "1", "attribute2": "2", "userGroupEdit": "Administrators", "userGroupViewDetails": "PricingManagers" } }, { "data": { "sku": "222222", "label": "The New Label 2", "unitOfMeasure": "EA", "currency": "EUR", "formulaName": "priceLogic2", "attribute1": "1", "attribute2": "2", "userGroupEdit": "Administrators", "userGroupViewDetails": "PricingManagers" } } ] --- ## Add a Product - [POST /add/P](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-add-p.md): Inserts a product to the Master Data - Products table. ## Update a Product - [POST /update/P](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-update-p.md): Updates an existing product. ## Search a Product - [POST /productmanager.quicksearch](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.quicksearch.md): Performs a search by sku and label fields. Returns all lists containing the search term. Enter the search term in the request body in the q parameter. > Information: Use the /productmanager.quicksearch/{query} (Search a Product (URL)) endpoint to pass the search term in the URL. ## Search a Product (URL) - [POST /productmanager.quicksearch/{query}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.quicksearch-query.md): Performs a search by sku and label fields. Returns all lists containing the search term. Enter the search term query URL-encoded to prevent an invalid API call when using special characters in the URL. > Information: Use the /productmanager.quicksearch (Search a Product) endpoint to pass the search term in the request body. ## List Products - [POST /productmanager.fetchformulafilteredproducts](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.fetchformulafilteredproducts.md): Retrieves a list of Products. A filter can be applied (see the request example). You can choose fields to be returned in the response by employing the resultFields or valueFields filter: resultFields: returns key-value pairs as objects. This is the more friendly response compared to valueFields but the server fetches all fields from the database in the backend which might result in a slower performance. See the listProductsResponseExample_resultFields response example. valueFields: returns just an array of values. Use this option if a better performance is required. See the listProductsResponseExample_valueFields response example. ## Delete a Product - [POST /delete/P](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-delete-p.md): Deletes a product. >Please note: >Only one object can be deleted per request (unless batched). Some object types may be blocked from being deleted by the update command as special processing is done by a dedicated manager command. Some object types are only soft-deleted, some are hard-deleted in the database. This behavior cannot be influenced by the client. >You can upsert multiple records using one request. To do so, add multiple data objects into your JSON. See the example below. json [ { "data": { "typedId": "2147501223.P" } }, { "data": { "typedId": "2147501224.P" } }, { "data": { "typedId": "2147501225.P" } } ] ## Get a Product Set - [POST /productmanager.fetchproductsetcompetition/{label}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.fetchproductsetcompetition-label.md): Retrieves products from the specified product set (configured for Competition Data API). >Information: >You can retrieve the product set's label (that is required in the URL of this endpoint as a parameter) using the /fetch/PCOMPCO endpoint. --- Required Permission| Roles with the Required Permission | ---------|----------| PRODUCTCOMPETITION_FETCH | Data Integration (DATAINTEGRATION), View Competition Data (PB_COMPETITION_RO), Manage Products (PB_PRODUCTEDITOR), Administer Products (PB_PRODUCTS), Investigate for Support (SUPPORT), Administer Plasma (PLASMA), Manage Product Details Only (PB_PDETAILSEDITOR), Manage Products & Use EC (PB_PRODUCTEDITOR_EC), Manage Competition Data (PB_COMPETITION) ## Get Competition Data - [POST /productmanager.fetchproductcompetition](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.fetchproductcompetition.md): Retrieves products from the Competition Data table. --- Please note: Returns the entire Competition Data table. The table can grow very large when no mechanism is put in place to delete stale records, and if you employ multiple data providers, this will return all data, irrespective of the source. Additionally to the regular /fetch command, this command supports (i.e. transparently handles) also global data as configured. This means that if, for example, the product competition data is configured to come from the global partition, this command will retrieve it from there. The regular fetch command will always only return data for the local partition. --- Required Permission| Roles with the Required Permission | ---------|----------| PRODUCTCOMPETITION_FETCH | Data Integration (DATAINTEGRATION), View Competition Data (PB_COMPETITION_RO), Manage Products (PB_PRODUCTEDITOR), Administer Products (PB_PRODUCTS), Investigate for Support (SUPPORT), Administer Plasma (PLASMA), Manage Product Details Only (PB_PDETAILSEDITOR), Manage Products & Use EC (PB_PRODUCTEDITOR_EC), Manage Competition Data (PB_COMPETITION) ## Import Competition Data - [POST /productmanager.importproductcompetition](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.importproductcompetition.md): Adds products to the Competition Data table. Returns the number of updated, inserted, and failed records during the import. Creates a new row for each product. ## List BoM for a Product - [POST /productmanager.bomtree/{sku}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-productmanager.bomtree-sku.md): Retrieves all Bill of Materials for the specified product. ## Execute an Assigned Logic - [POST /formulamanager.execute/{sku}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-formulamanager.execute-sku.md): Executes a logic that is assigned to the given product (specified by sku or typedId) and calculates the result. The result content is defined partially by the visibility flags that are part of the logic master data. ## Execute a Logic - [POST /formulamanager.execute/{sku}/{uniqueName}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-formulamanager.execute-sku-uniquename.md): Executes a logic (specified by uniqueName) that is assigned to the given product (specified by sku or typedId) and calculates the result. The result content is defined partially by the visibility flags that are part of the logic master data. ## List Recommendations - [POST /recommendations.recommend](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/products/post-recommendations.recommend.md): Retrieves recommended Quote items for a customer, segment, or a product. See also: Configure Recommended Items Knowledge base article. If the endpoint receives a request data containing a Quote typedId and a QuoteProductFilter logic is configured in the partition (see Quote Product Picker Filter Logic), then the endpoint will evaluate this logic with the corresponding Quote and gives the resulting Filter object to the recommendation model evaluation. ## Get a Product Set - [POST /productmanager.fetchproductsetcompetition/{label}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/competition-data/post-productmanager.fetchproductsetcompetition-label.md): Retrieves products from the specified product set (configured for Competition Data API). >Information: >You can retrieve the product set's label (that is required in the URL of this endpoint as a parameter) using the /fetch/PCOMPCO endpoint. --- Required Permission| Roles with the Required Permission | ---------|----------| PRODUCTCOMPETITION_FETCH | Data Integration (DATAINTEGRATION), View Competition Data (PB_COMPETITION_RO), Manage Products (PB_PRODUCTEDITOR), Administer Products (PB_PRODUCTS), Investigate for Support (SUPPORT), Administer Plasma (PLASMA), Manage Product Details Only (PB_PDETAILSEDITOR), Manage Products & Use EC (PB_PRODUCTEDITOR_EC), Manage Competition Data (PB_COMPETITION) ## Get Competition Data - [POST /productmanager.fetchproductcompetition](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/competition-data/post-productmanager.fetchproductcompetition.md): Retrieves products from the Competition Data table. --- Please note: Returns the entire Competition Data table. The table can grow very large when no mechanism is put in place to delete stale records, and if you employ multiple data providers, this will return all data, irrespective of the source. Additionally to the regular /fetch command, this command supports (i.e. transparently handles) also global data as configured. This means that if, for example, the product competition data is configured to come from the global partition, this command will retrieve it from there. The regular fetch command will always only return data for the local partition. --- Required Permission| Roles with the Required Permission | ---------|----------| PRODUCTCOMPETITION_FETCH | Data Integration (DATAINTEGRATION), View Competition Data (PB_COMPETITION_RO), Manage Products (PB_PRODUCTEDITOR), Administer Products (PB_PRODUCTS), Investigate for Support (SUPPORT), Administer Plasma (PLASMA), Manage Product Details Only (PB_PDETAILSEDITOR), Manage Products & Use EC (PB_PRODUCTEDITOR_EC), Manage Competition Data (PB_COMPETITION) ## Import Competition Data - [POST /productmanager.importproductcompetition](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/competition-data/post-productmanager.importproductcompetition.md): Adds products to the Competition Data table. Returns the number of updated, inserted, and failed records during the import. Creates a new row for each product. ## Execute an Assigned Logic - [POST /formulamanager.execute/{sku}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/logics/post-formulamanager.execute-sku.md): Executes a logic that is assigned to the given product (specified by sku or typedId) and calculates the result. The result content is defined partially by the visibility flags that are part of the logic master data. ## Execute a Logic - [POST /formulamanager.execute/{sku}/{uniqueName}](https://api.pricefx.com/openapi/reference/pricefx-server_openapi/logics/post-formulamanager.execute-sku-uniquename.md): Executes a logic (specified by uniqueName) that is assigned to the given product (specified by sku or typedId) and calculates the result. The result content is defined partially by the visibility flags that are part of the logic master data.