SaveDataServiceApiTestResult
Saves the results of an API test.
Try it now
Test
RAM authorization
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ApiId |
integer |
Yes |
The ID of the API. You can obtain the ID by calling the ListDataServiceApis operation. |
417381955954827 |
| ProjectId |
integer |
Yes |
The ID of the DataWorks workspace. You can log on to the DataWorks console and go to the Workspace Configuration page to obtain the workspace ID. |
10001 |
| ResultSample |
string |
No |
The sample result of a successful API test. This parameter is optional. |
{ "data": { "totalNum": 0, "pageSize": 10, "rows": [], "pageNum": 1 }, "errCode": 0, "requestId": "0bc14a561678159140664515*****", "errMsg": "success", "apiLog": null} |
| FailResultSample |
string |
No |
The sample result of a failed API test. This parameter is optional. |
{"apiLog": null, "data": null, "errCode": 1108110622, "errMsg": "data Source query failed", "requestId": "0 bc14a **** 5902762031 ****"} |
| AutoGenerate |
boolean |
No |
Specifies whether to use the system to automatically generate results. If the resultSample and failResultSample parameters are not specified, the system generates default results. |
false |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| RequestId |
string |
The ID of the request. |
0000-ABCD-EF***** |
| Data |
boolean |
Indicates whether the test results are saved. |
true |
| Success |
boolean |
Indicates whether the call is successful. |
true |
| HttpStatusCode |
integer |
The HTTP status code. |
200 |
Examples
Success response
JSON format
{
"RequestId": "0000-ABCD-EF*****\t",
"Data": true,
"Success": true,
"HttpStatusCode": 200
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.