Skip to main content
Skip table of contents

Item' UDF

Use this endpoint to manage the User Defined Fields (UDFs) for Fetching (Read) and Update (Write) operations.


Why we are doing this?
Several R2 Customers are working with a 3rd party Data Analytics tool to integrate the Items info of R2 and the 3rd party tool. Such that the updating this data becomes an automated task. Thereby removing any manual intervention and errors due to it. Lastly, this automation ensures that the Item information is 'always' up-to-date as per the manufacturers standards.

This data is stored in the UDF of the Items. The field names and their values are updated directly within the UDF segment of the Item Information.

GET By ID

Fetch User Defined Field fields (along with their respective values) of Items from Items using the Item’s ID

End Point: /items/{id}?siteid={siteid}

You can retrieve all information of a specific item for a specific site in R2 using this service.

This service also provides pricing information of a specific item.

Sample response payload

CODE
{
 "productid": "string",
 "description": "string",
 "active": true,
 "serial": true,
 "misctype": "Misc",
 "iscapitalizedcost": true,
 "nswithassets": true,
 "pricingmethod": "Package",
 "ismiscitem": true,
 "isaccessory": true,
 "isconsigned": true,
 "keywords": "string",
 "subcategoryid": "string",
 "upc": "string",
 "turnaroundtime": "string",
 "dateadded": "MM/dd/yyyy HH:mm",
 "sortpriority": "string",
 "warrantyperiodinmonths": 0,
 "manufacturer": "string",
 "partno": "string",
 "model": "string",
 "madein": "string",
 "url": "string",
 "stock": 0,
 "canrent": true,
 "cansell": true,
 "qconreturn": true,
 "cansubrent": true,
 "checkavail": true,
 "servicecharge": true,
 "damagewaiver": true,
 "ismaintainstatistics": true,
 "discountpercent": 0,
 "consumable": true,
 "printonorder": true,
 "issearchable": true,
 "retailprice": 0,
 "lowestretailprice": 0,
 "msrp": 0,
 "nbv": 0,
 "nbvason": "MM/dd/yyyy HH:mm",
 "sitereplacementcost": 0,
 "basereplacementcost": 0,
 "siteaveragecost": 0,
 "baseaveragecost": 0,
 "sitepurchaseprice": 0,
 "purchaseprice": 0,
 "isdepreciable": true,
 "depreciationtype": "Fixed",
 "depreciationpercent": 0,
 "depreciationlife": 0,
 "depreciationsalvagepercent": 0,
 "availgroupid": "string",
 "exchangegroupid": "string",
 "commissiongroupid": "string",
 "metergroupid": "string",
 "reportgroupid": "string",
 "departmentgroupid": "string",
 "attributegroupid": "string",
 "taxgroupid": "string",
 "maintenancegroupid": "string",
 "pricinggroupid": "string",
 "depreciationgroupid": "string",
 "matrixpricegroupid": "string",
 "accountgroupid": "string",
 "rentglaccountid": "string",
 "salesglaccountid": "string",
 "subrentglaccountid": "string",
 "expensesaccountglaccountid": "string",
 "cogsglaccountid": "string",
 "depreciationglaccountid": "string",
 "inventoryglaccountid": "string",
 "accountdepreciationglaccountid": "string",
 "writeoffglaccountid": "string",
 "discountglaccountid": "string",
 "length": 0,
 "width": 0,
 "height": 0,
 "weight": 0,
 "pricing": 
          [
           {
            "groupid": "string",
            "date": "MM/dd/yyyy HH:mm",
            "unit": "Weekly",
            "price": 0,
            "minprice": 0,
            "cost": 0,
            "overheadcost": 0
           }
          ]
 "udfs": 
        [
         {
          "caption": "string",
          "value": "string"
         }
        ],
 "iscontainer": true
}

PUT By ID

Update User Defined Field values of Items from Items using the Item’s ID.

End Point: /items/{id}

After a successful update, you will see the entire object in the response.

Sample response payload

CODE
{
 "recordid" "string"
 "productid": "string",
 "description": "string",
 "longdescription"  "string"
 "active" "boolean": true,
 "pricingmethod" "string"
 "ismiscitem" "boolean": true ,
 "keywords": "string",
 "upc": "string",
 "turnaroundtime": "string",
 "sortpriority": "string",
 "warrantyperiodinmonths": 0,
 "manufacturer": "string",
 "partno": "string",
 "model": "string",
 "madein": "string",
 "url": "string",
 "damagewaiver": true,
 "ismaintainstatistics": true,
 "discountpercent": 0,
 "consumable": true,
 "printonorder": true,
 "issearchable": true,
 "msrp": 0,
 "sitereplacementcost": 0,
 "siteaveragecost": 0,
 "availgroupid": "string",
 "exchangegroupid": "string",
 "commissiongroupid": "string",
 "metergroupid": "string",
 "reportgroupid": "string",
 "departmentgroupid": "string",
 "attributegroupid": "string",
 "taxgroupid": "string",
 "pricinggroupid": "string",
 "depreciationgroupid": "string",
 "matrixpricegroupid": "string",
 "accountgroupid": "string",
 "rentglaccountid": "string",
 "salesglaccountid": "string",
 "subrentglaccountid": "string",
 "expensesaccountglaccountid": "string",
 "cogsglaccountid": "string",
 "depreciationglaccountid": "string",
 "inventoryglaccountid": "string",
 "accountdepreciationglaccountid": "string",
 "writeoffglaccountid": "string",
 "discountglaccountid": "string",
 "length": 0,
 "width": 0,
 "height": 0,
 "weight": 0,
 "udfs": 
        [
         {
          "caption": "string",
          "value": "string"
         }
        ],
}

Rules pertaining to pagesize and page-count.

  1. A new parameter named ‘pagesize’ added to the API request.

    • This indicates ‘count’ of records requested page.

    • Minimum Count = 25.

    • Maximum Count = 100.

  2. A new parameter named ‘page-count’ added in the response header.

    • The indicates ‘number’ of pages being returned.

    • page-count = Total number of records/pagesize being used.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.