Skip to content
Download OpenAPI description
Languages
Servers
https://api.taskbase.com/
Operations
Operations
Operations
Operations

Computes feedback for an existing task.

Request

Security
bearerAuth
Path
taskIdstringrequired

The ID of the task.

Bodyapplication/jsonrequired
metaDataobject(FeedbackRequestMetaData)

The object containing metadata related to the learner interaction.

answerFreeformTextAnswer (object) or InTextFillInBlanksAnswer (object) or InTextChoicesAnswer (object) or MultipleChoiceAnswer (object) or MultipleResponsesAnswer (object) or SimulationAnswer (object)required

Base class for task answers. The concrete type depends on the task type.

Example: {"content":"The Battle of Waterloo was in 1815."}
One of:

Answer for freeform text tasks.

answer.​contentstring
Example: "The Battle of Waterloo was in 1815."
taskTypestringrequired

Defines the type of the task. Can be used by deserialization tools to instantiate the correct sub-type.

Enum"FREEFORM_TEXT""IN_TEXT_FILL_IN_BLANKS""IN_TEXT_CHOICES""MULTIPLE_CHOICE""MULTIPLE_RESPONSES""SIMULATION"
Example: "FREEFORM_TEXT"
Discriminator
tenantIdstring

Tenant identifier.

userIdstringrequired

User identifier.

Example: "student123"
curl -i -X POST \
  'https://api.taskbase.com/tasks/{taskId}/feedback/compute' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "userId": "student123",
    "taskType": "FREEFORM_TEXT",
    "answer": {
      "content": "The Battle of Waterloo was in 1815."
    }
  }'

Responses

Successful operation

Bodyapplication/json
resultobject
metaDataobject(FeedbackMetaData)

The object containing metadata about the performed operation, along with helpful debugging information. Designed to simplify the integration process and does not include any production-related details that should be visible to the end user.

taskIdstring
taskTypestring

Defines the type of the task. Can be used by deserialization tools to instantiate the correct sub-type.

Enum"FREEFORM_TEXT""IN_TEXT_FILL_IN_BLANKS""IN_TEXT_CHOICES""MULTIPLE_CHOICE""MULTIPLE_RESPONSES""SIMULATION"
Discriminator
userIdstring
Response
application/json
{ "result": { "allAspects": [], "answer": {}, "points": {}, "feedback": [], "sampleSolutions": [], "sampleSolution": {} }, "metaData": { "taskAction": "CREATED", "tenantId": "string", "taskLink": "string" }, "taskId": "string", "taskType": "FreeformTextFeedback", "userId": "string" }

Request

Creates a new task if the task.id has not been seen before, or updates an existing task if the task.id already exists. The task.id should be the identifier from your system.

This endpoint is designed for workflows where tasks are created separately from answer submission. If you need to submit an answer and get feedback, use the /tasks/{taskId}/feedback/compute endpoint instead.

Security
bearerAuth
Path
tenantIdstringrequired

The tenant identifier

Bodyapplication/jsonrequired
idstringrequired

The task ID. This field should contain the task identifier used in the client's system.

typestringrequired

Defines the type of the task. Can be used by deserialization tools to instantiate the correct sub-type.

Enum"FREEFORM_TEXT""IN_TEXT_FILL_IN_BLANKS""IN_TEXT_CHOICES""MULTIPLE_CHOICE""MULTIPLE_RESPONSES""SIMULATION"
Discriminator
languagestring

The task language.

Default "en-US"
Enum"de-CH""de-DE""en-US""en-UK""fr-FR""it-IT""es-ES"
titlestring

The task title. If left blank, the taskDefinition.id will be used as the title during implicit task creation or update.

Example: "my_task_title"
problemStatementstringrequired

The problem statement of the task.

Example: "When was the Battle of Waterloo?"
sampleSolutionstring
sampleSolutionsArray of objects(FreeformTextSampleSolution)
contextstring
resourceobject(FreeformTextResource)

The object containing information about the media file.

curl -i -X POST \
  'https://api.taskbase.com/tenants/{tenantId}/tasks' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "id": "string",
    "type": "FreeformTextTask",
    "problemStatement": "When was the Battle of Waterloo?"
  }'

Responses

Successful operation

Bodyapplication/json
taskIdstring
Example: "task_waterloo"
tenantIdstring
Example: "tenant_123"
actionstring
Enum"CREATED""UPDATED"
Example: "CREATED"
taskLinkstring
Example: "https://app.taskbase.com/tasks/task_waterloo"
Response
application/json
{ "taskId": "task_waterloo", "tenantId": "tenant_123", "action": "CREATED", "taskLink": "https://app.taskbase.com/tasks/task_waterloo" }

Request

Security
bearerAuth
Path
tenantIdstringrequired

The tenant identifier

taskIdstringrequired

The ID of the task to delete

curl -i -X DELETE \
  'https://api.taskbase.com/tenants/{tenantId}/tasks/{taskId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Successful operation

Bodyapplication/json
messagestring
Example: "Task deleted successfully"
taskIdstring
Example: "task_waterloo"
tenantIdstring
Example: "tenant_123"
Response
application/json
{ "message": "Task deleted successfully", "taskId": "task_waterloo", "tenantId": "tenant_123" }
Operations
Operations