Appearance
Create Order From Simulation By Order No
API Information
- Request Path:
/market/order/programming/createFromSimulationByOrderNo - Request Method:
POST - Content-Type:
application/json
Request Headers
| Parameter | Type | Required | Description |
|---|---|---|---|
| Authorization | String | Yes | User authentication token |
| Content-Type | String | Yes | Must be set to application/json |
Request Body Structure
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
| resultId | Long | Yes | Simulation result record id | From simulation results API content[].id |
| orderNo | String | Yes | Existing order number to update | Must be an order waiting for simulation selection |
| outputFolderId | Long | No | Output folder id | data_file.id; null means no folder binding |
| ossOutputId | Long | No | Existing OSS output configuration id | If provided together with ossOutput, ossOutputId takes precedence |
| ossOutput | Object | No | New OSS output configuration payload | Used when ossOutputId is not provided |
ossOutput Object
| Field | Type | Required | Description |
|---|---|---|---|
| name | String | No | Configuration name |
| storageType | String | No | Storage type |
| endPoint | String | No | Object storage endpoint |
| ak | String | No | Access key |
| sk | String | No | Secret key |
| accessPath | String | No | Base access path |
| accessRelativePath | String | No | Relative path appended to accessPath |
Request Body Example
json
{
"resultId": 1001,
"orderNo": "4e16b0f8-f4de-4b6f-8b67-f4b2d2d1f5c9",
"outputFolderId": 20,
"ossOutputId": 5
}Response Body Structure
CommonResponse Object
| Field | Type | Description |
|---|---|---|
| code | Integer | Response status code |
| message | String | Response message |
| data | OrderCreateResp | Response data |
OrderCreateResp Object
| Field | Type | Description |
|---|---|---|
| orderNo | String | Updated order number |
Response Examples
Success Response
json
{
"code": 200,
"message": "success",
"data": {
"orderNo": "ORDER_202604090001"
}
}Failure Response
json
{
"code": 400,
"message": "Invalid parameters",
"data": null
}Error Code Description
| Error Code | Description |
|---|---|
| 200 | Success |
| 400 | Request parameter error |
| 401 | Unauthorized |
| 500 | Server internal error |
Usage Instructions
- This API is used to update an existing order using a simulation result.
- User authentication is required.
- Provide
resultIdand targetorderNo. - The order must be in simulation selection status before update.
Notes
- This API updates an existing order and does not create a new order number.