Actively end an Acting Travel. After a normal end it enters completed and starts processing artifacts; on a no-stream timeout end it enters failed and no replay artifacts are generated.
Scope
Actively end an Acting Travel. After a normal end the Travel enters completed and starts processing artifacts; on a no-stream timeout end it enters failed and no replay artifacts are generated. Before calling, confirm the following:
- Authentication: The primary API Key is not required; either the primary or a temporary API Key can call it. For how to obtain them, see Obtain authentication credentials.
- Prerequisites: The Travel must not yet have entered a terminal state and must be in a state the server can end. Confirm via Query Travel Status.
- Caller: Either your server or your client can call it.
HTTP request
- Singapore
- US (Virginia)
POST https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v2/apps/happyoyster-1.0-acting/openapi/v1/travels/endReplace {WorkspaceId} with your actual Workspace ID.Request parameters |
|
Content-Typestring(Required)Request content type. This parameter must be set to application/json. | |
Authorization string (Required)API Key authentication. The primary API Key is not required; either the primary or a temporary API Key can call it.
| |
Request Body | |
encryptedTravelId string (Required)The Acting encrypted Travel ID to end. Returned by Enter Travel. | |
failCode string (Optional)The failure end reason for a no-stream timeout. When omitted, it is treated as a normal end. Currently only supported:
400000. | |
userAgent string (Optional)SDK or client version identifier. A non-empty string; takes precedence over the HTTP User-Agent. |
Response parameters |
|
code integerReturn code. 0 means success; non-zero is an error code. | |
message stringError message. null on success. | |
data objectResponse data. null on failure.
Properties encryptedTravelId stringThe encrypted Travel ID that was ended.status stringEnd status:
stringFailure reason code; returned only on a failure end.errorMessage stringFailure description; returned only on a failure end.endedAt stringEnd time, in ISO 8601 format; may be null when not yet available.durationSec integerEffective video duration in seconds; null on a no-stream failure end or when the duration cannot yet be parsed. |
Prerequisite states and call notes
- The
encryptedTravelIdmust belong to the current primary account and the Acting model. - The Travel must not yet have entered a terminal state and must be in a state the server can end.
- When
failCodeis omitted, it is treated as a normal end; passing an unsupported value returns400000. - On a normal end,
durationSecpreferentially uses the actual duration of the available finished video; it may benullwhen the finished-video duration cannot yet be parsed. - Acting does not use
maxExperienceTimeSecand will not auto-end after that duration when the client passes it. - After a normal end reaches
completed, the composited artifacts may still be processing; query and poll them per Query Travel Artifacts.
Error codes
If the model call fails and returns an error, see HappyOyster Error Codes to resolve it.
Next steps
After the Travel enters completed:
- Query Travel Artifacts: poll to obtain the recorded original and composited variants.
- Query Travel List: view historical Travels.