Not able to merge the MR request via API when the merge checks setting enabled in gitlab project.
Currently I am using the gitlab version: 12.3.6
I want to use gitlab restAPI to accept Merge request. Accept MR api: (PUT /projects/:id/merge_requests/:merge_request_iid/merge) -- Sucess
After enabling the merge checks I am getting the below error.
Error
{"message":"405 Method Not Allowed"} -- If merge request is unable to be accepted (ie: Work in Progress, Closed, Pipeline Pending Completion, or Failed while requiring Success) - you’ll get a 405 and the error message ‘Method Not Allowed’
Is there any option to force update the merge request ? or
Is there any API which can tell whether merge request can be accept when above checks (Merge checks) is set?