OpenHands

App · AI Agents · 18 actions

Hand coding work to OpenHands, the open-source AI software engineer. Describe a task in plain words and pick a repository: the agent clones it, runs commands and edits files in a sandbox of its own, then replies with what it did. Send follow-up instructions, read the files it wrote, and collect the diff of its changes for review.

Actions

ActionWhat it does
Check credit balanceHow many OpenHands Cloud credits your account has left, in US dollars.
Check on a taskSee where a task has got to: starting, running, finished, stopped with an error, or waiting on you.
Delete a taskDelete a task from your OpenHands account and shut down its sandbox, along with any files in it.
Get a task's code changesThe files the agent added, changed or deleted, each with a diff, ready to post for review.
Get a task's messagesThe conversation between you and the agent, oldest first: every instruction it was given and every reply.
List a task's filesThe files in a task's workspace, relative to its repository.
List branchesThe branches of a repository OpenHands can work on.
List repositoriesThe repositories OpenHands can work on, from the GitHub, GitLab or Bitbucket account connected to OpenHands.
List tasksSee the tasks on your OpenHands account, newest first.
List what a task didThe steps the agent took, oldest first: each command it ran with its output and exit code, each file it looked at or edited, and any errors.
Pause a taskStop the agent where it is by pausing the task's sandbox.
Read a file from a taskThe contents of a file in a task's workspace, such as a report the agent wrote.
Rename a taskGive a task a new title in OpenHands.
Resume a taskWake a paused task's sandbox (usually within a minute, occasionally two) and report where the agent had got to.
Send a follow-up messageGive a task more instructions, and wait for the agent's reply.
Share a taskTurn a task's public link on or off.
Start a taskGive OpenHands a coding task in plain words.
Wait for a task to finishHold the workflow until a task finishes, then hand on the agent's answer.

Check credit balance

How many OpenHands Cloud credits your account has left, in US dollars. Tasks on the free models don't use any; the others are paid for from this balance.

Inputs

None.

Outputs

creditsnumber
Example output
{
  "credits": 10.0
}

Check on a task

See where a task has got to: starting, running, finished, stopped with an error, or waiting on you. Once it has finished, this includes the agent's answer.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.

Outputs

answertext
branchtext
conversation_idtext
created_attext
donetrue/false
errortext
linktext
modeltext
repositorytext
sandbox_statustext
sharedtrue/false
startup_stagetext
statustext
titletext
updated_attext
Example output
{
  "answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "branch": "main",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "created_at": "2026-09-22T18:45:16.612776Z",
  "done": true,
  "error": "",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "model": "openhands/deepseek-v4.1-flash",
  "repository": "octocat/hello-world",
  "sandbox_status": "running",
  "shared": false,
  "startup_stage": "",
  "status": "finished",
  "title": "Fix empty email on signup",
  "updated_at": "2026-09-22T18:49:04.813393Z"
}

Delete a task

Delete a task from your OpenHands account and shut down its sandbox, along with any files in it. OpenHands still keeps the task's message history on its side.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.

Outputs

conversation_idtext
deletedtrue/false
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "deleted": true
}

Get a task's code changes

The files the agent added, changed or deleted, each with a diff, ready to post for review. Uncommitted changes are included. A paused task is woken first.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
Include the diffsinclude_diffstrue/false
Turn off to list just which files changed, which is quicker for a large change.Default: true.

Outputs

changeslist
conversation_idtext
countnumber
difftext
repositorytext
Example output
{
  "changes": [
    {
      "diff": "--- a/signup.py\n+++ b/signup.py\n@@ -1 +1 @@\n-if email is None:\n+if not email:\n",
      "path": "signup.py",
      "status": "updated"
    }
  ],
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "count": 1,
  "diff": "--- a/signup.py\n+++ b/signup.py\n@@ -1 +1 @@\n-if email is None:\n+if not email:\n",
  "repository": "octocat/hello-world"
}

Get a task's messages

The conversation between you and the agent, oldest first: every instruction it was given and every reply.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
How manylimitnumber
The most recent messages to return, up to 200.From 1 to 200. Default: 50.

Outputs

conversation_idtext
countnumber
latest_answertext
messageslist
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "count": 2,
  "latest_answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "messages": [
    {
      "role": "user",
      "sent_at": "2026-09-22T18:48:31.073476",
      "text": "The signup form accepts an empty email. Fix it."
    },
    {
      "role": "agent",
      "sent_at": "2026-09-22T18:49:04.297736",
      "text": "Fixed the empty-email check in signup.py and added a test for it."
    }
  ]
}

List a task's files

The files in a task's workspace, relative to its repository. A paused task is woken first, which usually takes under a minute.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
Matchingmatchingtext
Only files matching this: a pattern with * such as *.md, or words in the path such as src/. Leave blank for every file.

Outputs

conversation_idtext
countnumber
fileslist
totalnumber
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "count": 3,
  "files": [
    "README.md",
    "signup.py",
    "tests/test_signup.py"
  ],
  "total": 3
}

List branches

The branches of a repository OpenHands can work on.

Inputs

RepositoryrepositorytextRequired
The repository, as owner/repository.
Searchsearchtext
Only branches whose name contains these words.
How manylimitnumber
The most to return.From 1 to 100. Default: 50.

Outputs

brancheslist
countnumber
has_moretrue/false
repositorytext
Example output
{
  "branches": [
    {
      "commit_sha": "3f786850e387550fdab836ed7e6dc881de23001b",
      "last_pushed_at": "2026-09-22T17:35:18Z",
      "name": "main"
    }
  ],
  "count": 1,
  "has_more": false,
  "repository": "octocat/hello-world"
}

List repositories

The repositories OpenHands can work on, from the GitHub, GitLab or Bitbucket account connected to OpenHands.

Inputs

Searchsearchtext
Only repositories whose name contains these words.
How manylimitnumber
The most to return.From 1 to 100. Default: 30.

Outputs

countnumber
has_moretrue/false
providertext
repositorieslist
Example output
{
  "count": 1,
  "has_more": false,
  "provider": "github",
  "repositories": [
    {
      "default_branch": "main",
      "full_name": "octocat/hello-world",
      "is_public": true,
      "owner_type": "user",
      "provider": "github"
    }
  ]
}

List tasks

See the tasks on your OpenHands account, newest first. A task whose sandbox OpenHands has paused shows as paused here; 'Check on a task' says whether it had finished.

Inputs

Title containstitle_containstext
Only tasks whose title contains this text, with the same capital letters.
Started aftercreated_afterdate and time
Only tasks started on or after this moment.
How manylimitnumber
The most to return.From 1 to 100. Default: 20.

Outputs

countnumber
has_moretrue/false
taskslist
Example output
{
  "count": 1,
  "has_more": false,
  "tasks": [
    {
      "branch": "main",
      "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
      "created_at": "2026-09-22T18:45:16.612776Z",
      "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
      "model": "openhands/deepseek-v4.1-flash",
      "repository": "octocat/hello-world",
      "sandbox_status": "running",
      "shared": false,
      "status": "finished",
      "title": "Fix empty email on signup",
      "updated_at": "2026-09-22T18:49:04.813393Z"
    }
  ]
}

List what a task did

The steps the agent took, oldest first: each command it ran with its output and exit code, each file it looked at or edited, and any errors. Useful as an audit trail.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
Showshowtext
Which steps to include.One of: everything (Everything the agent did), commands (Terminal commands only), errors (Errors only). Default: everything.
How manylimitnumber
The most recent steps to return, up to 200.From 1 to 200. Default: 50.

Outputs

conversation_idtext
countnumber
stepslist
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "count": 1,
  "steps": [
    {
      "at": "2026-09-22T18:48:43.834925",
      "command": "pytest tests/test_signup.py",
      "exit_code": 0,
      "failed": false,
      "output": "4 passed in 0.12s",
      "path": "",
      "summary": "Run the signup tests",
      "tool": "terminal"
    }
  ]
}

Pause a task

Stop the agent where it is by pausing the task's sandbox. That also makes room for another task, since OpenHands limits how many run at once. Nothing is lost: send it a follow-up message to carry on.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.

Outputs

conversation_idtext
linktext
pausedtrue/false
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "paused": true
}

Read a file from a task

The contents of a file in a task's workspace, such as a report the agent wrote. When there is no such file, 'found' comes back false rather than the step handing on an empty file. A paused task is woken first.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
FilepathtextRequired
The file's path relative to the repository, as 'List a task's files' shows it.

Outputs

contenttext
conversation_idtext
foundtrue/false
pathtext
sizenumber
truncatedtrue/false
Example output
{
  "content": "# Report\n\nAll four signup tests pass.\n",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "found": true,
  "path": "docs/report.md",
  "size": 38,
  "truncated": false
}

Rename a task

Give a task a new title in OpenHands.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
New titletitletextRequired
What to call the task.

Outputs

conversation_idtext
linktext
titletext
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "title": "Fix empty email on signup"
}

Resume a task

Wake a paused task's sandbox (usually within a minute, occasionally two) and report where the agent had got to. The agent doesn't pick up its work by itself; send it a follow-up message for that.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.

Outputs

answertext
branchtext
conversation_idtext
created_attext
donetrue/false
errortext
linktext
modeltext
repositorytext
sandbox_statustext
sharedtrue/false
startup_stagetext
statustext
titletext
updated_attext
Example output
{
  "answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "branch": "main",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "created_at": "2026-09-22T18:45:16.612776Z",
  "done": true,
  "error": "",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "model": "openhands/deepseek-v4.1-flash",
  "repository": "octocat/hello-world",
  "sandbox_status": "running",
  "shared": false,
  "startup_stage": "",
  "status": "finished",
  "title": "Fix empty email on signup",
  "updated_at": "2026-09-22T18:49:04.813393Z"
}

Send a follow-up message

Give a task more instructions, and wait for the agent's reply. The agent keeps everything from earlier in the task, files included. A paused task is woken first, so this is also how to set a paused or stuck task going again.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
MessagemessagetextRequired
What to tell the agent.
Wait up to (minutes)wait_minutesnumber
How long this step waits for the agent to finish. If it is still working when the wait runs out, the step succeeds with 'done' set to false, and 'Wait for a task to finish' can pick it up later. Set 0 to carry on straight away.From 0 to 30. Default: 10.

Outputs

answertext
branchtext
conversation_idtext
created_attext
donetrue/false
errortext
linktext
modeltext
repositorytext
sandbox_statustext
sharedtrue/false
startup_stagetext
statustext
titletext
updated_attext
Example output
{
  "answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "branch": "main",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "created_at": "2026-09-22T18:45:16.612776Z",
  "done": true,
  "error": "",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "model": "openhands/deepseek-v4.1-flash",
  "repository": "octocat/hello-world",
  "sandbox_status": "running",
  "shared": false,
  "startup_stage": "",
  "status": "finished",
  "title": "Fix empty email on signup",
  "updated_at": "2026-09-22T18:49:04.813393Z"
}

Share a task

Turn a task's public link on or off. Anyone with the link can read the whole task without signing in, including your instructions, every command the agent ran, and the contents of files it read.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
Sharedsharedtrue/false
On to make the link work, off to stop it working.Default: true.

Outputs

conversation_idtext
linktext
share_linktext
sharedtrue/false
Example output
{
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "share_link": "https://app.all-hands.dev/shared/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "shared": true
}

Start a task

Give OpenHands a coding task in plain words. The agent clones the repository into a sandbox of its own, runs commands and edits files there, and replies when it is done. This step waits for that reply (starting alone takes about a minute), and hands back the task's ID for the steps after it.

Inputs

TasktasktextRequired
What the agent should do, as you'd tell a person.
Repositoryrepositorytext
The repository to work on, as owner/repository. Leave blank for a task that needs no existing code.
Branchbranchtext
The branch to start from. Leave blank for the repository's default branch.
Titletitletext
A name for the task in OpenHands. Leave blank and OpenHands writes one.
Modelmodeltext
The AI model the agent uses. Leave blank for the one in your OpenHands settings. The free ones cost no credits; the others need credits on your account.
Plan onlyplan_onlytrue/false
Have the agent study the code and write a plan instead of making the change. The plan is saved as .agents_tmp/PLAN.md, and summarized in its answer.Default: false.
Wait up to (minutes)wait_minutesnumber
How long this step waits for the agent to finish. If it is still working when the wait runs out, the step succeeds with 'done' set to false, and 'Wait for a task to finish' can pick it up later. Set 0 to carry on straight away.From 0 to 30. Default: 10.

Outputs

answertext
branchtext
conversation_idtext
created_attext
donetrue/false
errortext
linktext
modeltext
repositorytext
sandbox_statustext
sharedtrue/false
startup_stagetext
statustext
titletext
updated_attext
Example output
{
  "answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "branch": "main",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "created_at": "2026-09-22T18:45:16.612776Z",
  "done": true,
  "error": "",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "model": "openhands/deepseek-v4.1-flash",
  "repository": "octocat/hello-world",
  "sandbox_status": "running",
  "shared": false,
  "startup_stage": "",
  "status": "finished",
  "title": "Fix empty email on signup",
  "updated_at": "2026-09-22T18:49:04.813393Z"
}

Wait for a task to finish

Hold the workflow until a task finishes, then hand on the agent's answer. Use it after a 'Start a task' or 'Send a follow-up message' step that didn't wait, for example to start several tasks at once and collect their answers afterwards.

Inputs

Taskconversation_idtextRequired
The task's ID, from 'Start a task' or 'List tasks'. Its OpenHands link works too.
Wait up to (minutes)wait_minutesnumber
How long this step waits for the agent to finish. If it is still working when the wait runs out, the step succeeds with 'done' set to false, and 'Wait for a task to finish' can pick it up later. Set 0 to carry on straight away.From 0 to 30. Default: 10.

Outputs

answertext
branchtext
conversation_idtext
created_attext
donetrue/false
errortext
linktext
modeltext
repositorytext
sandbox_statustext
sharedtrue/false
startup_stagetext
statustext
titletext
updated_attext
Example output
{
  "answer": "Fixed the empty-email check in signup.py and added a test for it.",
  "branch": "main",
  "conversation_id": "5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "created_at": "2026-09-22T18:45:16.612776Z",
  "done": true,
  "error": "",
  "link": "https://app.all-hands.dev/conversations/5f3a9c2e7b1d4e8fa0c6b2d9e4f1a7c3",
  "model": "openhands/deepseek-v4.1-flash",
  "repository": "octocat/hello-world",
  "sandbox_status": "running",
  "shared": false,
  "startup_stage": "",
  "status": "finished",
  "title": "Fix empty email on signup",
  "updated_at": "2026-09-22T18:49:04.813393Z"
}

On this page