Skip to content

[12.1] Add missing award emoji methods to MergeRequests#860

Open
antonkomarev wants to merge 1 commit intoGitLabPHP:12.0from
antonkomarev:feature/note-award-emoji
Open

[12.1] Add missing award emoji methods to MergeRequests#860
antonkomarev wants to merge 1 commit intoGitLabPHP:12.0from
antonkomarev:feature/note-award-emoji

Conversation

@antonkomarev
Copy link
Copy Markdown

@antonkomarev antonkomarev commented Apr 16, 2026

Adds the missing award_emoji write/read endpoints to
Gitlab\Api\MergeRequests — both for the merge request itself
and for its notes:

Method Verb Path
addAwardEmoji() POST .../merge_requests/:iid/award_emoji
showNoteAwardEmoji() GET .../merge_requests/:iid/notes/:note_id/award_emoji
addNoteAwardEmoji() POST .../merge_requests/:iid/notes/:note_id/award_emoji
removeNoteAwardEmoji() DELETE .../merge_requests/:iid/notes/:note_id/award_emoji/:award_id

Existing awardEmoji() (GET list) and removeAwardEmoji() (DELETE)
already covered the read/remove side for the MR itself, but there
was no way to actually add an emoji — and nothing at all for notes.

Naming follows the existing conventions on this class:

  • show* for single-resource reads (showNote(), showDiscussion())
  • add* / remove* for writes (addNote(), removeNote())

GitLab uses a flat /notes/:note_id/award_emoji path, so the note
methods also cover reactions on discussion thread comments —
callers just pass the note_id of the discussion note.

Reference: https://docs.gitlab.com/api/emoji_reactions/

Resurrects #794 (closed as stale after a request for test coverage);
this PR adds the missing tests and removeNoteAwardEmoji() for
symmetry.

@antonkomarev antonkomarev changed the title Add note award emoji methods to MergeRequests [12.1] Add note award emoji methods to MergeRequests Apr 16, 2026
@antonkomarev antonkomarev changed the title [12.1] Add note award emoji methods to MergeRequests [12.1] Add missing award emoji methods to MergeRequests Apr 16, 2026
@antonkomarev antonkomarev force-pushed the feature/note-award-emoji branch from 08a05e4 to 4f6aebd Compare April 16, 2026 14:43
@antonkomarev antonkomarev force-pushed the feature/note-award-emoji branch from 4f6aebd to 413912a Compare April 16, 2026 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant