Skip to content

How to get remainingTime of task in v2 ? #456

Closed Answered by sauterl
klschoef asked this question in Q&A
Discussion options

You must be logged in to vote

Hi there, thanks for the question.

Indeed, the api/v2/client/evaluation/currentTask/{evaluationId} endpoint only provides information on the current task template as a feature.

In v2 this information is part of the state of the evaluation, hence the endpoint /api/v2/evaluation/state/list provides this information in the field timeLeft. Please note that the fields timeElapsed and timeLeft are seconds. Its sum might be not what the template suggests, as administrators can modify the time of a task on-the-fly.

Since you provided Java / Kotlin names, please use getApiV2EvaluationStateList, which returns an array of ApiEvaluationState objects.

Generally speaking, we provide for your convenienc…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@klschoef
Comment options

Answer selected by sauterl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants