Use this API to retrieve the events that track changes to issues, merge requests, and epics:

  • Label events record who added or removed a label, and when.
  • Iteration events record iteration changes for issues.
  • Milestone events record milestone changes for issues and merge requests.
  • State events record state changes for issues, merge requests, and epics.
  • Weight events record weight changes for issues.

State events do not track the initial state (created or opened) of a resource. For a resource that was never closed or reopened, an empty list is returned.

List all project issue label events

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_label_events

Lists all label events for a specified issue.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
Integer or stringThe IID of the issue
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceLabelEvent
400Bad Request—
404Not Found—

Retrieve an issue label event

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_label_events/{event_id}

Retrieves a label event for a specified project issue.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
event_id
Path, required
StringID of the resource label event
eventable_id
Path, required
Integer or stringThe IID of the issue

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceLabelEvent
400Bad Request—
404Not Found—

List all project issue milestone events

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_milestone_events

Lists all milestone events for a specified issue.

Parameters

NameTypeDescription
id
Path, required
String or integerID or URL-encoded path of the project
eventable_id
Path, required
Integer or stringInternal ID of the issue or merge request
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceMilestoneEvent
400Bad Request—
404Not Found—

Retrieve an issue milestone event

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_milestone_events/{event_id}

Retrieves a specified milestone event for a project issue.

Parameters

NameTypeDescription
id
Path, required
String or integerID or URL-encoded path of the project
event_id
Path, required
StringID of the resource milestone event
eventable_id
Path, required
Integer or stringInternal ID of the issue or merge request

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceMilestoneEvent
400Bad Request—
404Not found—

List all project issue state events

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_state_events

Lists all state events for a specified issue.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
IntegerThe IID of the issue
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceStateEvent
400Bad Request—
404Not Found—

Retrieve an issue state event

GET /api/v4/projects/{id}/issues/{eventable_id}/resource_state_events/{event_id}

Retrieves a state event for a specified project issue.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
IntegerThe IID of the issue
event_id
Path, required
IntegerID of the resource state event

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceStateEvent
400Bad Request—
404Not Found—

List all project merge request label events

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_label_events

Lists all label events for a specified merge request.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
Integer or stringThe IID of the merge request
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceLabelEvent
400Bad Request—
404Not Found—

Retrieve a merge request label event

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_label_events/{event_id}

Retrieves a label event for a specified project merge request.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
event_id
Path, required
StringID of the resource label event
eventable_id
Path, required
Integer or stringThe IID of the merge request

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceLabelEvent
400Bad Request—
404Not Found—

List all project merge request milestone events

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_milestone_events

Lists all milestone events for a specified merge request.

Parameters

NameTypeDescription
id
Path, required
String or integerID or URL-encoded path of the project
eventable_id
Path, required
Integer or stringInternal ID of the issue or merge request
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceMilestoneEvent
400Bad Request—
404Not Found—

Retrieve a merge request milestone event

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_milestone_events/{event_id}

Retrieves a specified milestone event for a project merge request.

Parameters

NameTypeDescription
id
Path, required
String or integerID or URL-encoded path of the project
event_id
Path, required
StringID of the resource milestone event
eventable_id
Path, required
Integer or stringInternal ID of the issue or merge request

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceMilestoneEvent
400Bad Request—
404Not found—

List all project merge request state events

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_state_events

Lists all state events for a specified merge request.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
IntegerThe IID of the merge request
page
Query
IntegerPage number of results to retrieve
Default: 1
Example: 1
per_page
Query
IntegerNumber of items to list per page
Default: 20
Example: 20

Responses

CodeDescriptionSchema
200OKArray of APIEntitiesResourceStateEvent
400Bad Request—
404Not Found—

Retrieve a merge request state event

GET /api/v4/projects/{id}/merge_requests/{eventable_id}/resource_state_events/{event_id}

Retrieves a state event for a specified project merge request.

Parameters

NameTypeDescription
id
Path, required
StringID or URL-encoded path of the project
eventable_id
Path, required
IntegerThe IID of the merge request
event_id
Path, required
IntegerID of the resource state event

Responses

CodeDescriptionSchema
200OKAPIEntitiesResourceStateEvent
400Bad Request—
404Not Found—

Schemas

Objects returned by the operations above and objects nested in their request bodies.

APIEntitiesCustomAttribute

PropertyTypeDescription
keyStringExample: foo
valueStringExample: bar

APIEntitiesLabelBasic

PropertyTypeDescription
archivedBooleanExample: false
colorStringExample: #FF0000
descriptionStringExample: Bug reported by user
description_htmlStringExample: <p>Bug reported by user</p>
idInteger (int64)Example: 1
nameStringExample: bug
text_colorStringExample: #FFFFFF

APIEntitiesMilestone

PropertyTypeDescription
created_atString—
descriptionString—
due_dateString—
expiredBoolean—
group_idString—
idInteger (int64)—
iidInteger (int64)—
project_idInteger (int64)—
start_dateString—
stateString—
titleString—
updated_atString—
web_urlString—

APIEntitiesResourceLabelEvent

PropertyTypeDescription
actionStringExample: add
created_atString (date-time)Example: 2018-08-20T13:38:20.077Z
idInteger (int64)Example: 142
labelAPIEntitiesLabelBasic—
resource_idInteger (int64)Example: 253
resource_typeStringExample: Issue
userAPIEntitiesUserBasic—

APIEntitiesResourceMilestoneEvent

PropertyTypeDescription
actionStringExample: add
created_atString (date-time)Example: 2018-08-20T13:38:20.077Z
idInteger (int64)Example: 142
milestoneAPIEntitiesMilestone—
resource_idInteger (int64)Example: 253
resource_typeStringExample: Issue
stateStringExample: active
userAPIEntitiesUserBasic—

APIEntitiesResourceStateEvent

PropertyTypeDescription
created_atString (date-time)Example: 2018-08-20T13:38:20.077Z
idInteger (int64)Example: 142
resource_idInteger (int64)Example: 253
resource_typeStringExample: Issue
source_commitStringExample: 7b09ce7e6f80347baf0316c8c94cdba9a0a7e91d
source_merge_request_idInteger (int64)Example: 45
stateStringExample: opened
userAPIEntitiesUserBasic—

APIEntitiesUserBasic

PropertyTypeDescription
avatar_pathStringExample: /user/avatar/28/The-Big-Lebowski-400-400.png
avatar_urlStringURL of the user’s avatar
Example: https://gravatar.com/avatar/1
custom_attributesArray of APIEntitiesCustomAttribute—
idInteger (int64)ID of the user
Example: 1
lockedBooleanIf true, the user account is locked, and the user cannot sign in until the lock expires or an administrator unlocks the account
nameStringName of the user. For a bot user, **** if the current user cannot read the bot’s project or group
Example: Administrator
public_emailStringPublic email address of the user
Example: john@example.com
stateStringState of the user account. Possible values: active, blocked, ldap_blocked, blocked_pending_approval, banned, or deactivated
Example: active
usernameStringUsername of the user
Example: admin
web_urlStringURL of the user’s profile
Example: https://gitlab.example.com/root