content library item: find

Returns identifiers of all the visible (as determined by authorization policy) library items matching the requested content.library.item.find_spec.

Request:

HTTP request

POST https://{server}/rest/com/vmware/content/library/item?~action=find

Request Body Structure:

{
    "spec"{
        "cached"true,
        "library_id""obj-103",
        "name""string",
        "source_id""obj-103",
        "type""string"
    }
}

Request Body Parameters:

Name Type Description
bold = required
spec find_spec Specification describing what properties to filter on.
spec.name string The name of the library item. The name is case-insensitive. See content.library.item_model.name.

Optional. If not specified all library item names are searched.

spec.library_id string The identifier of the library containing the item. See content.library.item_model.library_id.

Optional. If not specified all libraries are searched.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.Library. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.Library.

spec.source_id string The identifier of the library item as reported by the publisher. See content.library.item_model.source_id.

Optional. If not specified all library items are searched.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.library.Item. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.library.Item.

spec.type string The type of the library item. The type is case-insensitive. See content.library.item_model.type.

Optional. If not specified all types are searched.

spec.cached boolean Whether the item is cached. Possible values are 'true' or 'false'. See content.library.item_model.cached.

Optional. If not specified all library items are searched.

Response:

HTTP Status Code: 200

Representation:

{
    "value"[
        "obj-103",
        "obj-103"
    ]
}

Response Type:

Name Type Description
bold = required
value string[] The array of identifiers of all the visible library items matching the given spec.

Errors:

HTTP Status Code Type Description
400 invalid_argument if no properties are specified in the spec.