Skip to main content
Version: 2024.3

Asset Queries

Asset queries support getting single assets, single asset folders and asset listings.

Get Single Asset

Base structure for getting single asset:

{
getAsset(id: 4) {
...
}
}

See also following examples:

Get Single Asset Folder

Base structure for getting single asset folder (same as for assets):

{
getAssetFolder(id: 4) {
...
}
}

Get List of Assets

Base structure for getting a list of assets, restricted by IDs:

{
getAssetListing(ids: "4,5") {
edges {
...

See also following examples:

Pagination

Pagination can be applied as query parameters.

{
# 'first' is the limit
# 'after' the offset
getAssetListing(first: 3, after: 1) {
edges {
...
}
}
}

Simple Sorting

Sorting can be applied as query parameters, for example sort by filename, descending.

{
getManufacturerListing(sortBy: "filename", sortOrder: "DESC") {
edges {
node {
id
name
}
}
}
}

Filtering

You can use Pimcore's webservice filter logic as described here for filtering listing requests.

For details see filtering documentation page

Localization of Queries

Queries can be localized For details see the localization documentation page.