Rebase a merge request API skip_ci does not work

I am trying out the new API in 12.7 to skip a CI when doing a rebase. The syntax, from what I can guess is something like:$PROJECT/merge_requests/$ISSUE/rebase?skip_ci=true

This doesn’t work for me though. The rebase works correctly, but the CI is NOT skipped. Am I doing something wrong here?

Hello @fedordoc - Thank you for your question. Per the documentation for Rebase a merge request a :merge_request_iid is expected; can you confirm in your example if $ISSUE is referencing the merge request id and not an issue id?

I’m using the number that’s displayed in the merge request page at the top, e.g. ‘project > Merge Requests > !xxx’

Using that number gets me the correct information with other API requests

Here’s the actual commands I use, for reference:

> curl --request GET --header PRIVATE-TOKEN: XXXXXX https://git.hostcom/api/v4/version
> curl --request PUT --header PRIVATE-TOKEN: XXXXXXX

I am also getting issue with skip_ci flag in rebase api. But for me skip_ci flag doesn’t skip pipeline all the time which is blocker for me in my gitlab repo.
My use case is:
Pipeline must succeed feature is enabled from repo settings. Means pipeline can only merge when all pipeline will finish for the merge request.
I wrote a script which does rebase and merge MR automatically (both using gitlab api).
Now because skip_ci sometime creates new pipeline (not all the time), my merge api fails with error {“message”:“405 Method Not Allowed”} and I think this issue is because rebase api created new pipeline and Pipeline must succeed is enable.
Note: My script waits to finish rebase process before do merge MR api.

Can you please help me, how to fix skip_ci flag in rebase api?

Gitlab runner version: tried with 12.2 and 12.9
Gitlab version: 12.9.2

More precise error about above pipeline issue is: it does’t skips deteched pipeline in rebase api with skip_ci flag.