# Fetching assets

This API reference document contains information on fetching assets

Hygraph automatically generates 4 query types for assets. These are:

![Asset queries](https://hygraph.com/images/classic-docs/api-reference/assets/asset-queries.png)

- `asset`
- `assets`
- `assetVersion`
- `assetsConnection`

These queries work just like regular [queries](https://hygraph.com/classic-docs/api-reference/content-api/queries), and can be [filtered](https://hygraph.com/classic-docs/api-reference/content-api/filtering) by their [fields](https://hygraph.com/classic-docs/api-reference/schema/field-types#asset).

Here are some sample queries:

  **asset**

```graphql
# Fetch the fileName, local, size and stage of the asset with the provided id
query MyQuery {
  asset(where: {id: "<YOUR_ASSET_ID>"}) {
    fileName
    locale
    size
    stage
  }
}
```

  
  **assets**

```graphql
# Fetch the fileName, size and locale of all assets in stage PUBLISHED
query MyQuery {
  assets(stage: PUBLISHED) {
    fileName
    size
    locale
  }
}
```

  
  **assetVersion**

```graphql
# Fetch an asset version, filtered by revision number, unique identifier, and stage
query MyQuery {
  assetVersion(
    where: {revision: 10, id: "<YOUR_ASSET_ID>", stage: DRAFT}
  ) {
    createdAt
    data
  }
}
```

  
  **assetsConnection**

```graphql
# Fetch assets with assetUploadStatus ASSET_CREATE_PENDING
query MyQuery {
  assetsConnection(where: {assetUploadStatus: ASSET_CREATE_PENDING}) {
    edges {
      node {
        id
      }
    }
  }
}
```
