Function getCollections

  • Retrieves the collections that the user has access to. This endpoint does not return the user's favorites collection, which can be retrieved with /v1/collections/favorites.

    Parameters

    • query: {
          creatorId?: string;
          id?: string;
          includeItems?: string;
          limit?: number;
          name?: string;
          next?: string;
          prev?: string;
          query?: string;
          sort?:
              | "-name"
              | "+name"
              | "+createdAt"
              | "-createdAt"
              | "+updatedAt"
              | "-updatedAt";
          type?: CollectionTypes;
          types?: CollectionTypes[];
      }

      an object with query parameters

      • OptionalcreatorId?: string

        The case-sensitive string used to search for a resource by creatorId.

      • Optionalid?: string
      • OptionalincludeItems?: string
      • Optionallimit?: number
      • Optionalname?: string
      • Optionalnext?: string

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

      • Optionalprev?: string
      • Optionalquery?: string
      • 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.

      • Optionaltype?: CollectionTypes
      • Optionaltypes?: CollectionTypes[]
    • Optionaloptions: ApiCallOptions

    Returns Promise<GetCollectionsHttpResponse>

    GetCollectionsHttpError