API Reference
List ControlNet Models

List ControlNet Models and Pre-processors

Action ListControlNets

Introduction

This interface is used to query the models and pre-processors of ControlNets. The common combinations and effects of the models are:


ControlNet NameControlNet ModelCodePreProcessor NamePreProcessor ModelCodeEffect
Consistent Faceip-adapter-faceid-plusv2_sd15Keeping the face unchanged when generating images.
Contents Migrate (Normal)ip-adapter_sd15Keeping the same style when generating images.
Depthcontrol_v11f1p_sd15_depthDepth (LeRes)depth_leresGenerating images according to the depth information of the reference image.
Depthcontrol_v11f1p_sd15_depthDepth (MiDas)depthSame as above.
Depthcontrol_v11f1p_sd15_depthDepth (ZoE)depth_zoeSame as above.
Hard Edgecontrol_v11p_sd15_cannyHard EdgecannyGenerating images according to the lines information of the reference image.
Inpaintcontrol_v11p_sd15_inpaintGenerating contents in the marked area of the raw image.
Insruct Pix2Pixcontrol_v11e_sd15_ip2pEditing the raw image by prompts.
Lineartcontrol_v11p_sd15_lineartLineartlineartSimilar to the "Hard Edge" model, but more curvy and diverse.
Lineartcontrol_v11p_sd15_lineartLineart (Standard)lineart_standardSame as above.
Lineart Animiecontrol_v11p_sd15s2_lineart_animeLineart (Anime + Denoise)lineart_anime_denoiseSimilar to the "Hard Edge" model, but more curvy and diverse (optimize for anime style).
Lineart Animiecontrol_v11p_sd15s2_lineart_animeLineart (Anime)lineart_animeSame as above.
Normal Mapcontrol_v11p_sd15_normalbaeNormal Map (Bae)normal_baeSimilar to the "Depth" models, but base on a normal map.
Posecontrol_v11p_sd15_openposePose (Full)openpose_fullGenerating images according to the human's poses in the reference image.
Recolorioclab_sd15_recolorRecolor (Intensity)recolor_intensityRecoloring images according to the intensity or luminance information of the reference image.
Recolorioclab_sd15_recolorRecolor (Luminance)recolor_luminanceSame as above.
Scribblecontrol_v11p_sd15_scribbleScribble (Edge)scribble_xdogSimilar to the "Hard Edge" models, but more rough and diverse.
Scribblecontrol_v11p_sd15_scribbleScribble (HED)scribble_hedSame as above.
Shufflecontrol_v11e_sd15_shuffleShuffleshuffleGenerating new images by shuffling the colors and contents of the raw image.
Soft Edgecontrol_v11p_sd15_softedgeSoft Edge (HED)softedge_hedSimilar to the "Hard Edge" model, but more rough and diverse.
Soft Edgecontrol_v11p_sd15_softedgeSoft Edge (PiDiNet)softedge_pidinetSame as above.
Straight Linecontrol_v11p_sd15_mlsdStraight LinemlsdGenerating images only according to straight lines in the reference image.
Tilecontrol_v11f1e_sd15_tileTiletileGenerating images by tiling the reference image to add more details or upscale it.

Request

Parameter NameTypeDescriptionRequired
ActionStringThe corresponding API instruction name
PublicKeyStringUser's public key, which can be obtained from the PICPIK User Center (opens in a new tab)
SignatureStringUser's signature generated based on the public key and API instruction, see Signature for details
request_uuidStringRequest UUID, randomly generated by using the UUID generation method. This parameter can be utilized to manage the requests of your business and clients.

Request Example

{
    "Action":    "ListControlNets",
    "PublicKey": "ALLak9M4cNdHXKOJAJJ4k8Hh1hZS2EgJF1D0FlPwfl",
    "request_uuid":"b91fcfbe-bb35-47ce-a168-bd6252c75270",
    "Signature": "0131f4e4296f3ca8e1220b47247e83a4315ea8e1"
}

Response

Field NameTypeDescriptionRequired
RetCodeIntReturn status code: 0 indicates a successful return, while non-zero indicates a failure
ActionStringInstruction name
MessageStringThe error message is returned when RetCode is non-zero, providing a detailed description
request_uuidStringReturns the UUID that was included in the request
Field NameTypeDescriptionRequired
PreProcessorsMap[String]PreProcessorPre-processors list of ControlNets
ControlModelsMap[String]ControlModelModels list of ControlNets

Intro to Complex Data Types

PreProcessor

Parameter NameTypeDescriptionRequired
ModelCodeStringThe model code of a ControlNet pre-processor.
InferenceParamsInferenceParamsInference parameters of a pre-processor

ControlModel

Parameter NameTypeDescriptionRequired
ModelCodeStringControlNet model code
InferenceParamsInferenceParamsInference parameters of a ControlNet model

InferenceParams

Note: Specific parameters are only valid for a particular model data type (parent) and are not generic.

Parameter NameTypeValid Parent TypeDescriptionDefaultRangeStepRequired
LoraWeightFloatModelThe influence weight when inferencing. Only available with the LoRA model.1-1~20.01
ResolutionIntPreProcessorThe resolution of images generated by the pre-processor.51264~204864
ControlWeightFloatControlModelThe influence weight of a ControlNet model when inferencing.10~20.01
StartingStepFloatControlModelTiming (ratio) of a ControlNet model to start intervening in the inference process.00~10.01
EndingStepFloatControlModelTiming (ratio) of a ControlNet model to stop intervening in the inference process.10~10.01

Response Example

{
	"Action": "ListControlNets",
	"RetCode": 0,
	"Message": "",
	"request_uuid": "06e47e54-253e-40d7-9002-a3f7d9d4cbdd",
	"PreProcessors": {
		"canny": {
			"Name": "canny",
			"ModelCode": "canny",
			"InferenceParams": {
				"Resolution": 512
			}
		}
		// more...
	},
	"ControlModels": {
		"control_v11e_sd15_ip2p": {
			"Name": "control_v11e_sd15_ip2p",
			"ModelCode": "control_v11e_sd15_ip2p",
			"InferenceParams": {
				"ControlWeight": 1,
				"StartingStep": 0,
				"EndingStep": 1
			}
		}
		// more ...
	}
}