Function getCollectionItems

  • Retrieves items from a collection that the user has access to.

    Parameters

    • collectionId: string

      The collection's unique identifier. (This query also supports 'favorites' as the collectionID).

    • query: {
          limit?: number;
          name?: string;
          next?: string;
          noActions?: boolean;
          prev?: string;
          query?: string;
          resourceId?: string;
          resourceLink?: string;
          resourceType?: ItemResourceTypeEnum;
          shared?: boolean;
          sort?:
              | "-name"
              | "+name"
              | "+createdAt"
              | "-createdAt"
              | "+updatedAt"
              | "-updatedAt";
          spaceId?: string;
      }

      an object with query parameters

      • Optionallimit?: number

        The maximum number of resources to return for a request. The limit must be an integer between 1 and 100 (inclusive).

      • Optionalname?: string

        The case-insensitive string used to search for a resource by name.

      • Optionalnext?: string

        The cursor to the next page of resources. Provide either the next or prev cursor, but not both.

      • OptionalnoActions?: boolean

        If set to true, the user's available actions for each item will not be evaluated meaning the actions-array will be omitted from the response (reduces response time).

      • Optionalprev?: string

        The cursor to the previous page of resources. Provide either the next or prev cursor, but not both.

      • Optionalquery?: string

        The case-insensitive string used to search for a resource by name or description.

      • OptionalresourceId?: string

        The case-sensitive string used to search for an item by resourceId. If resourceId is provided, then resourceType must be provided. Provide either the resourceId or resourceLink, but not both.

      • OptionalresourceLink?: string

        The case-sensitive string used to search for an item by resourceLink. If resourceLink is provided, then resourceType must be provided. Provide either the resourceId or resourceLink, but not both.

      • OptionalresourceType?: ItemResourceTypeEnum

        The case-sensitive string used to search for an item by resourceType.

      • Optionalshared?: boolean

        Whether or not to return items in a shared space.

      • Optionalsort?: "-name" | "+name" | "+createdAt" | "-createdAt" | "+updatedAt" | "-updatedAt"

        The property of a resource to sort on (default sort is +createdAt). The supported properties are createdAt, updatedAt, and name. A property must be prefixed by + or - to indicate ascending or descending sort order respectively.

      • OptionalspaceId?: string

        The space's unique identifier (supports 'personal' as spaceId).

    • Optionaloptions: ApiCallOptions

    Returns Promise<GetCollectionItemsHttpResponse>

    GetCollectionItemsHttpError