Model Configuration

Description

This API handles requests to query model configurations in the cloud. For details on the results, please refer to the documentation below.

Version

1.0

Request URL

Production environment: https://openapi.meitu.com/whee/business/config.json

Request Method

Get

Permissions

Apply for an APPKEY and SECRETID before use.

Response Descriptions

Successful Response Descriptions

FieldTypeDescription
dataObjectReturned content
messageStringError message
codeNumberError code

Field descriptions for an individual element in data

FieldTypeDescription
model_listObject[]Model list
lora_listObject[]LoRA models
pic_size_listObject[]Image dimensions
module_listObject[]Preprocessor list

Field descriptions in model_list

FieldTypeDescription
nameStringModel name
imagesString[]Model cover images. There may be multiple images; the first is used by default.
descStringModel description
modelStringModel name passed as a parameter for text-to-image/image-to-image generation

Field descriptions in lora_list

FieldTypeDescription
nameStringModel name
imagesString[]Model cover images. There may be multiple images; the first is used by default.
descStringModel description
modelStringModel name passed as a parameter for text-to-image/image-to-image generation

Field descriptions in pic_size_list

FieldTypeDescription
widthIntImage width
heightIntImage height
ratioStringImage aspect ratio value

Field descriptions in module_list

FieldTypeDescription
nameStringName
moduleStringPreprocessor
descStringDescription

Failed Response Descriptions

FieldTypeDescription
dataStringReturned content
messageStringError message
codeIntError code

Response Examples

Successful Request Response Example

Response Status: 200

content-type is application/json; charset=utf-8

{
	"code": 0,
	"message": "",
	"data": {
		"model_list": [{
			"name": "MiracleVision 4.0",
        	"desc": "A large AI vision model that understands aesthetics.",
        	"images": ["https://wheeai.meitudata.com/static/65794a59176836071xxYFcQJaD4448.jpeg"],
        	"model": "miracle-vision_v3.1-realistic1.zip"
		}],
		"lora_list": [{
			"name": "074594b2d60230282482d176d28c7c2e",
        	"desc": "Poetic Ink Wash",
        	"images": ["https://wheeai.meitudata.com/static/656451567858655475nfG97OhR4989.png"],
        	"model": "074594b2d60230282482d176d28c7c2e_1.0"
		}, {
			"name": "ad546a890981b719aaea4f6a43d4467c",
        	"desc": "Mineral Pigment Painting",
        	"images": ["http://xximg1.meitudata.com/cover_7130498151326183426.png"],
        	"model": "ad546a890981b719aaea4f6a43d4467c_1.0"
		}],
		"pic_size_list": [{
			"width": 1024,
			"height": 768,
			"ratio":"4:3"
		}, {
			"width": 720,
			"height": 1280,
			"ratio":"9:16"
		}],
		"module_list": [{
			"name": "Edge Detection",
			"module": "canny_mv",
			"desc":"Closely matches image edges and is suitable for preserving the composition of the original image"
		}, {
			"name": "Depth Estimation",
			"module": "depth_mv",
			"desc":"Generally used for outlines, such as those of people. It reproduces human features with high fidelity and also works well for reconstructing the layout of architectural spaces"
		}, {
			"name": "Pose Detection",
			"module": "openpose_mv",
			"desc":"Infers human poses through a skeletal model to reproduce movements"
		}]
	}
}

Failed Request Response Example

Response Status: 400

content-type is application/json; charset=utf-8

{
	"code": 20008, 
	"message": "UNSUITABLE_IMAGE", 
	"data": null
}

Common Error Codes and Messages

See API Error Codes

Example Request

curl -vX GET "https://openapi.meitu.com/whee/business/config.json"