Get resource inventories

get

/rest/ofscCore/v1/resources/{resourceId}/inventories

This operation retrieves data on the resource pool inventories of the specified resource.

Request

Path Parameters
Query Parameters

Response

Supported Media Types

200 Response

Body ()
Root Schema : Resource inventories
Type: object
Title: Resource inventories
Collection of inventories for a resource
Show Source
Nested Schema : Resource inventories
Type: array
Title: Resource inventories
Array of resource inventories
Show Source
Nested Schema : Inventory
Type: object
Title: Inventory
Equipment that can be installed or deinstalled during an activity
Show Source
  • Title: Activity Id
    Id of activity this inventory is assigned to. This field will be empty for inventories with status=resource
  • Title: Exchanged Inventory Id
    If an inventory was exchanged by resource with another inventory, then this field contains Inventory Id of the inventory it was exchanged with
  • Title: Inventory Id
    Unique identifier of inventory in Oracle Field Service Cloud
  • Title: Inventory Type
    Type of the inventory as defined in OFSC. The inventory type marks inventory as serialized (identified by its serial number) or non-serialized (having no serial number).
  • Title: Quantity
    Quantity of inventory
  • Title: Resource Id
    Resource that has this inventory (or resource that is assigned an activity that has this inventory)
  • Title: Serial Number
    Serial number that is unique among inventories of the same type
  • Title: Status
    Allowed Values: [ "customer", "resource", "installed", "deinstalled" ]
    Current status of inventory: whether it is located e.g. at customers site, or in technicians truck

Default Response

Error response
Body ()
Root Schema : Error
Type: object
Show Source

Examples

The following example shows how to get resource inventories for resources by submitting a GET request on the REST resource.

Example of Request Header

The following shows an example of the request header.

GET /rest/ofscCore/v1/resources/33035/inventories HTTP/1.0
Authorization: Basic c29hcEB5YW1hdG86MQ==
Host: api.etadirect.com    Accept: */*

Example of Response Header

The following shows an example of the response header.

HTTP/1.1 200 OK
Server: nginx/1.6.2
Date: Mon, 06 Jul 2015 13:20:14 GMT
Content-Type: application/json; charset=utf-8
Connection: close

Example of Response Body

The following example shows the contents of the response body in JSON format.

 
{
        "items": [
            {
                "inventoryId": 20997542,
                "status": "provider",
                "inventoryType": "TV",
                "serialNumber": "PLBJ1C3AB",
                "quantity": 1,
                "resourceId": "44035"
            },
            {
                "inventoryId": 20996913,
                "status": "provider",
                "inventoryType": "DT",
                "serialNumber": "58NBME39T065517",
                "quantity": 1,
                "resourceId": "44035"
            },
            {
                "inventoryId": 20996675,
                "status": "provider",
                "inventoryType": "DT",
                "serialNumber": "HRSC63602",
                "quantity": 1,
                "resourceId": "44035"
            },
            {
                "inventoryId": 20997195,
                "status": "provider",
                "inventoryType": "AT",
                "serialNumber": "PMUD106F8",
                "quantity": 1,
                "resourceId": "44035"
            }
        ],
        "total": 4,
        "links": [
            {
                "rel": "canonical",
                "href": "https://api.etadirect.com/wwwroot-master/rest/ofscCore/v1/resources/44035/inventories"
            },
            {
                "rel": "describedby",
                "href": "https://api.etadirect.com/wwwroot-master/rest/ofscCore/v1/metadata-catalog/resources"
            }
        ]
}