POST api/Image/UploadBase64

base64上传图片

Request Information

URI Parameters

None.

Body Parameters

Base64ImageUploadDto
NameDescriptionTypeAdditional information
Secene

文件上传场景

ImageScene

None.

SaveFileExt

文件保存后缀(前端无需传入)

ImageExt

None.

FileBytes

文件byte流(前端无需传入)

Collection of byte

None.

OImage

原图规格

ImageCanCut

None.

ThumbImages

缩略图规格

Collection of ImageBasic

None.

ThirdId

业务三方数据id(可用于存储房源id等)

integer

None.

ThirdGroupId

业务三方分组id,可用于存储房源相册分组id等特有场景的id信息

integer

None.

fileBase64

文件流base64

string

None.

Request Formats

application/json

Sample:

An exception has occurred while using the formatter 'JsonpMediaTypeFormatter' to generate sample for media type 'application/json'. Exception message: 无法访问已关闭的流。

text/json

Sample:

An exception has occurred while using the formatter 'JsonpMediaTypeFormatter' to generate sample for media type 'text/json'. Exception message: 无法访问已关闭的流。

application/xml, text/xml

Sample:
<Base64ImageUploadDto xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Mh.Common.Service.Dto.Image">
  <FileBytes>QEA=</FileBytes>
  <OImage>
    <Height>4</Height>
    <Width>3</Width>
    <X>1</X>
    <Y>2</Y>
  </OImage>
  <SaveFileExt>jpg</SaveFileExt>
  <Secene>Editor</Secene>
  <ThirdGroupId>2</ThirdGroupId>
  <ThirdId>1</ThirdId>
  <ThumbImages>
    <ImageBasic>
      <Height>2</Height>
      <Width>1</Width>
    </ImageBasic>
    <ImageBasic>
      <Height>2</Height>
      <Width>1</Width>
    </ImageBasic>
  </ThumbImages>
  <fileBase64>sample string 1</fileBase64>
</Base64ImageUploadDto>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'Base64ImageUploadDto'.

Response Information

Resource Description

base64上传图片

Object

None.

Response Formats

application/json

Sample:

An exception has occurred while using the formatter 'JsonpMediaTypeFormatter' to generate sample for media type 'application/json'. Exception message: 无法访问已关闭的流。

text/json

Sample:

An exception has occurred while using the formatter 'JsonpMediaTypeFormatter' to generate sample for media type 'text/json'. Exception message: 无法访问已关闭的流。

application/xml, text/xml

Sample:
<z:anyType xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/" />