---
title: "MediaImage"
description: "代表 Shopline 托管图片"
doc_type: graphql
doc_category: storefront
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common-objects/objects/media-image'
  md: 'https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common-objects/objects/media-image.md'
---
# MediaImage

代表 Shopline 托管图片

- **API Version:** v20270301
- **API Type:** Storefront
- **API Protocol:** GraphQL
- **Operation Type:** Object

## Type Signature

`MediaImage`

## Fields

* `alt`

  [String](https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common/scalars/string.md)

  分享媒体性质或内容的单词或短语

* `id`

  [ID!](https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common/scalars/id.md)

  全局唯一的媒体ID

* `image`

  [Image](https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common-objects/objects/image.md)

  媒体的图片

* `mediaContentType`

  [MediaContentType!](https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common-objects/enums/media-content-type.md)

  媒体内容类型

* `previewImage`

  [Image](https://developer.shopline.com/zh-hans-cn/docs/storefront-api/common-objects/objects/image.md)

  媒体的预览图像

## Schema Definition

```graphql
type MediaImage { 
	alt: String
	id: ID!
	image: Image
	mediaContentType: MediaContentType!
	previewImage: Image 
}
```

## Error Handling

关于更多通用错误码说明，参考：[状态码和错误码](https://developer.shopline.com/zh-hans-cn/docs/apps/api-instructions-for-use/storefront-api/overview.md#status-and-error-codes)。

