---
title: "Create or update the Jira integration"
method: PUT
path: "/api/v4/projects/{id}/integrations/jira"
tags: ["integrations"]
---

# Create or update the Jira integration

`PUT /api/v4/projects/{id}/integrations/jira`

## Request

- Base URL: `https://gitlab.com`
- URL: `https://gitlab.com/api/v4/projects/{id}/integrations/jira`
- Auth: none declared

Creates or updates the Jira integration.

## Path parameters

- `id` integer, required

## Request body

- PutApiV4ProjectsIdIntegrationsJira: Create or update the Jira integration
  - `url` string, required: The URL to the Jira project which is being linked to this GitLab project (for example, `https://jira.example.com`).
  - `api_url` string: The base URL to the Jira instance API. Web URL value is used if not set (for example, `https://jira-api.example.com`).
  - `jira_auth_type` integer: The authentication method to use with Jira. Use `0` for basic authentication, `1` for Jira personal access token, and `2` for Jira Cloud service accounts. Defaults to `0`.
  - `username` string: The email or username to use with Jira. Use an email for Jira Cloud, and a username for Jira Data Center and Jira Server. Required when using basic authentication (`jira_auth_type` is `0`).
  - `password` string, required: The Jira API token, password, or personal access token to use with Jira. When using Basic Authentication (`jira_auth_type` is `0`), use an API token for Jira Cloud, and a password for Jira Data Center or Jira Server. For a Jira personal access token (`jira_auth_type` is `1`), use the personal access token.
  - `jira_issue_regex` string: Regular expression to match Jira issue keys.
  - `jira_issue_prefix` string: Prefix to match Jira issue keys.
  - `jira_issue_transition_id` string: The ID of one or more transitions for [custom issue transitions](../integration/jira/issues.md#custom-issue-transitions).Ignored when `jira_issue_transition_automatic` is enabled. Defaults to a blank string,which disables custom transitions.
  - `issues_enabled` string: Enable viewing Jira issues in GitLab.
  - `project_keys` string[]: Keys of Jira projects to display. When `issues_enabled` is `true`, this setting filters which Jira projects are shown in GitLab. It does not restrict the API token's access.
  - `vulnerabilities_enabled` boolean: Turn on Jira issue creation for GitLab vulnerabilities.
  - `vulnerabilities_issuetype` string: Jira issue type to use when creating issues from vulnerabilities.
  - `project_key` string: Key of the project to use when creating issues from vulnerabilities.This parameter is required if using the integration to create Jira issues from vulnerabilities.
  - `customize_jira_issue_enabled` boolean: When set to `true`, opens a prefilled form on the Jira instancewhen creating a Jira issue from a vulnerability.
  - `jira_check_enabled` boolean: Verify Jira issues referenced in commit messages exist before allowing the push.
  - `jira_exists_check_enabled` boolean: Verify the Jira issues referenced in commit messages exist in Jira.
  - `jira_assignee_check_enabled` boolean: Verify the committer is the assignee of the Jira issues referenced in commit messages.
  - `jira_status_check_enabled` boolean: Verify the status of Jira issues referenced in commit messages.
  - `jira_allowed_statuses_as_string` string: Comma-separated list of allowed Jira issue statuses.
  - `comment_on_event_enabled` boolean: Enable comments inside Jira issues on each GitLab event (commit / merge request)
  - `commit_events` boolean: Trigger event when a commit is created or updated.
  - `merge_requests_events` boolean: Trigger event when a merge request is created, updated, or merged.
  - `use_inherited_settings` boolean: Indicates whether to inherit the default settings. Defaults to `false`.

## Response `200`

Create or update the Jira integration

- APIEntitiesIntegrationBasic: API_Entities_IntegrationBasic model
  - `id` integer, required
  - `title` string, required
  - `slug` string, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `active` boolean, required
  - `commit_events` boolean, required
  - `push_events` boolean, required
  - `issues_events` boolean, required
  - `incident_events` boolean, required
  - `alert_events` boolean, required
  - `confidential_issues_events` boolean, required
  - `merge_requests_events` boolean, required
  - `tag_push_events` boolean, required
  - `deployment_events` boolean, required
  - `note_events` boolean, required
  - `confidential_note_events` boolean, required
  - `pipeline_events` boolean, required
  - `wiki_page_events` boolean, required
  - `job_events` boolean, required
  - `comment_on_event_enabled` boolean, required
  - `inherited` boolean, required
  - `vulnerability_events` boolean, required

## Other responses

- `400`: Bad request
- `401`: Unauthorized
- `404`: Not found
- `422`: Unprocessable entity

---

[API](https://skmtc.dev/gitlab/apis/gitlab-api.md) - [All operations](https://skmtc.dev/gitlab/apis/gitlab-api/llms.txt) - [OpenAPI document](https://skmtc.dev/gitlab/apis/gitlab-api/revisions/b234947ef3f2?raw)
