---
title: "POST /v1/{+parent}/pullRequests"
method: POST
path: "/v1/{+parent}/pullRequests"
tags: ["projects"]
---

# POST /v1/{+parent}/pullRequests

`POST /v1/{+parent}/pullRequests`

Creates a pull request.

## Path parameters

- `parent` string, required

## Request body

- PullRequest — Metadata of a PullRequest. PullRequest is the request from a user to merge a branch (head) into another branch (base).
  - `updateTime` string, google-datetime — Output only. Last updated timestamp.
  - `title` string — Required. The pull request title.
  - `name` string — Output only. Identifier. A unique identifier for a PullRequest. The number appended at the end is generated by the server. Format: `projects/{project}/locations/{location}/repositories/{repository}/pullRequests/{pull_request_id}`
  - `head` Branch — Branch represents a branch involved in a pull request.
    - `sha` string — Output only. The commit at the tip of the branch.
    - `ref` string — Required. Name of the branch.
  - `base` Branch — Branch represents a branch involved in a pull request.
    - `sha` string — Output only. The commit at the tip of the branch.
    - `ref` string — Required. Name of the branch.
  - `body` string — Optional. The pull request body. Provides a detailed description of the changes.
  - `createTime` string, google-datetime — Output only. Creation timestamp.
  - `closeTime` string, google-datetime — Output only. Close timestamp (if closed or merged). Cleared when pull request is re-opened.
  - `state` 'STATE_UNSPECIFIED' | 'OPEN' | 'CLOSED' | 'MERGED' — Output only. State of the pull request (open, closed or merged).

## Response `200`

Successful response

---

[API](https://skmtc.net/google/apis/securesourcemanager.md) · [All operations](https://skmtc.net/google/apis/securesourcemanager/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/google/securesourcemanager/versions/4c9890b46a17/schema)
