Methods & Playground

Get Assets By Group

Return the list of assets given a group (key, value) pair.

Use groupKey: "collection" to fetch assets in a Token Metadata or mpl-core collection. Use groupKey: "group" to fetch members of an mpl-core GroupV1 account — collections, assets, and nested groups that belong to the group.

To get the group name and member count without listing every asset, use getGrouping.

Parameters

NameRequiredDescription
groupKeyThe key of the group (e.g., "collection" or "group" for mpl-core groups).
groupValueThe value of the group.
sortBySorting criteria. This is specified as an object { sortBy: <value>, sortDirection: <value> }, where sortBy is one of ["created", "updated", "recentAction", "id", "none"] and sortDirection is one of ["asc", "desc"]
limitThe maximum number of assets to retrieve.
pageThe index of the "page" to retrieve.
beforeRetrieve assets before the specified ID.
afterRetrieve assets after the specified ID.
optionsDisplay options object. See Display Options for details.

Playground