All Products
Search
Document Center

Blockchain as a Service:CreateAntChainContractProject

Last Updated:Aug 18, 2023

You can call this operation to create a contract project in a consortium in Ant Blockchain.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

ParameterTypeRequiredExampleDescription
ConsortiumIdStringYesDV80nJXq

The ID of the consortium in which you want to create the contract project.

ProjectNameStringYesprojectname

The name of the contract project to create. It can only be a free combination of English uppercase and lowercase, numbers, commonly used Chinese characters and dashes (-), no special characters such as decimal points and spaces, and is limited to 1 to 30 characters.

ProjectVersionStringYesv1.0.0

The version of the contract project to create.

ActionStringNoCreateAntChainContractProject

The operation that you want to perform. Set the value to CreateAntChainContractProject.

ProjectDescriptionStringNoproject description

The description of the contract project to create.

RegionIdStringNocn-hangzhou

The ID of the region where Ant Blockchain is used.

Response parameters

ParameterTypeExampleDescription
RequestIdString4261A4C3-B8B5-4555-AEBC-944C3EAB23DB

The ID of the request.

Result

The result of the operation.

ConsortiumIdStringDV80nJXq

The ID of the consortium in which the contract project was created.

CreateTimeLong1563951889044

The time when the contract project was created.

ProjectDescriptionStringproject description

The description of the created contract project.

ProjectIdStringR38DAbop

The ID of the created contract project.

ProjectNameStringprojectname

The name of the created contract project.

ProjectVersionStringv1.0.0

The version of the created contract project.

UpdateTimeLong1563951889140

The time when the created contract project was updated.

Examples

Sample requests


http(s)://[Endpoint]/?Action=CreateAntChainContractProject
&<Common request parameters>

Sample success responses

JSON format

{
	"successResponse":true,
	"requestId":"4261A4C3-B8B5-4555-AEBC-944C3EAB23DB",
	"data":{
		"Result":{
			"ProjectDescription":"project description",
			"ProjectName":"projectname",
			"ConsortiumId":"DV80nJXq",
			"ProjectVersion":"v1.0.0",
			"CreateTime":1563951889044,
			"UpdateTime":1563951889140,
			"ProjectId":"R38DAbop"
		},
		"RequestId":"4261A4C3-B8B5-4555-AEBC-944C3EAB23DB"
	},
	"code":"200"
}

Error codes

For a list of error codes, visit the API Error Center.