> ## Documentation Index
> Fetch the complete documentation index at: https://docs.blinkops.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Pull Request

Mutates the specified pull request.

This can be used to change the pull request's branches or description.

Only open pull requests can be mutated.

<Note>
  External Documentation

  To learn more, visit the [Bitbucket documentation](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-pullrequests/#api-repositories-workspace-repo-slug-pullrequests-pull-request-id-put).
</Note>

## Parameters

<div className="integrations-table">
  | Parameter          | Description                                                                                                                              |
  | ------------------ | ---------------------------------------------------------------------------------------------------------------------------------------- |
  | Destination Branch | The name of the destination branch.                                                                                                      |
  | Pull Request ID    | The id of the pull request.                                                                                                              |
  | Repo Slug          | This can either be the repository slug or the UUID of the repository,<br />surrounded by curly-braces, for example: `{repository UUID}`. |
  | Source Branch      | The name of the source branch.                                                                                                           |
  | Title              | Title of the pull request.                                                                                                               |
  | Workspace Slug     | This can either be the workspace ID (slug) or the workspace UUID<br />surrounded by curly-braces, for example: `{workspace UUID}`.       |
</div>

## Example Output

```json theme={"dark"}
{
	"author": {
		"account_id": "123456:daffbc08-1a80-4bd0-98bf-7997de0a3d10",
		"display_name": "Example Username",
		"links": {
			"avatar": {
				"href": "https://bitbucket.org/account/example-username/avatar/"
			},
			"html": {
				"href": "https://bitbucket.org/example-username/"
			},
			"self": {
				"href": "https://api.bitbucket.org/2.0/users/example-username"
			}
		},
		"nickname": "example-username",
		"type": "user",
		"username": "example-username",
		"uuid": "{58021780-82b6-4517-b153-0ae73ce3e4b4}"
	},
	"close_source_branch": true,
	"comment_count": 0,
	"created_on": "2018-06-20T23:17:33.616Z",
	"description": "Everything is awesome!",
	"destination": {
		"branch": {
			"name": "master"
		},
		"commit": {
			"hash": "230269fdfabd",
			"links": {
				"html": {
					"href": "https://bitbucket.org/example-username/bits_and_bobs/commits/230269fdfabd"
				},
				"self": {
					"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/commit/230269fdfabd"
				}
			},
			"type": "commit"
		},
		"repository": {
			"full_name": "example-username/bits_and_bobs",
			"links": {
				"avatar": {
					"href": "https://bytebucket.org/ravatar/%7B7708d810-964c-403f-aa6d-4e949280d614%7D?ts=python"
				},
				"html": {
					"href": "https://bitbucket.org/example-username/bits_and_bobs"
				},
				"self": {
					"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs"
				}
			},
			"name": "bits_and_bobs",
			"type": "repository",
			"uuid": "{7708d810-964c-403f-aa6d-4e949280d614}"
		}
	},
	"id": 1,
	"links": {
		"activity": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/activity"
		},
		"approve": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/approve"
		},
		"comments": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/comments"
		},
		"commits": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/commits"
		},
		"decline": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/decline"
		},
		"diff": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/diff"
		},
		"html": {
			"href": "https://bitbucket.org/example-username/bits_and_bobs/pull-requests/1"
		},
		"merge": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/merge"
		},
		"self": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1"
		},
		"statuses": {
			"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/pullrequests/1/statuses"
		}
	},
	"participants": [],
	"reason": "",
	"reviewers": [],
	"source": {
		"branch": {
			"name": "branch_magnificent_internet"
		},
		"commit": {
			"hash": "c184aab5708b",
			"links": {
				"html": {
					"href": "https://bitbucket.org/example-username/bits_and_bobs/commits/c184aab5708b"
				},
				"self": {
					"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs/commit/c184aab5708b"
				}
			},
			"type": "commit"
		},
		"repository": {
			"full_name": "example-username/bits_and_bobs",
			"links": {
				"avatar": {
					"href": "https://bytebucket.org/ravatar/%7B7708d810-964c-403f-aa6d-4e949280d614%7D?ts=python"
				},
				"html": {
					"href": "https://bitbucket.org/example-username/bits_and_bobs"
				},
				"self": {
					"href": "https://api.bitbucket.org/2.0/repositories/example-username/bits_and_bobs"
				}
			},
			"name": "bits_and_bobs",
			"type": "repository",
			"uuid": "{7708d810-964c-403f-aa6d-4e949280d614}"
		}
	},
	"state": "OPEN",
	"summary": {
		"html": "\u003cp\u003eEverything is awesome!\u003c/p\u003e",
		"markup": "markdown",
		"raw": "Everything is awesome!",
		"type": "rendered"
	},
	"task_count": 0,
	"title": "Change a cooperative standard to a smiling disease",
	"type": "pullrequest",
	"updated_on": "2018-06-20T23:17:33.616Z"
}
```

## Workflow Library Example

[Update Pull Request with Bitbucket and Send Results Via Email](https://library.blinkops.com/workflows/update-pull-request-with-bitbucket-and-send-results-via-email)

<div className="iframe-wrapper">
  <div className="iframe-media">
    <img src="https://mintcdn.com/blinkops-2/ojHYuDeYX5FWuN8a/img/Icons/play-box.svg?fit=max&auto=format&n=ojHYuDeYX5FWuN8a&q=85&s=b8af968e71438a9499c3223c9bd29fb2" alt="Workflow Library" width="16" height="16" data-path="img/Icons/play-box.svg" />

    Preview this Workflow on desktop
  </div>

  <iframe className="iframe" src="https://library.blinkops.com/workflows/update-pull-request-with-bitbucket-and-send-results-via-email/canvas" />
</div>
