Trigger build use REST API got error when branch name has a slash

i have tried many times. trigger by REST API and pass branch params must encode twice so it can trigger success, but the clone step went error. such as i got a branch name “feature/test” i encode twice got ‘feature%252Ftest’ this will trigger build successfully , but the clone step will got error because the branch name isn’t right which liket this:

Initialized empty Git repository in /drone/src/.git/ 0s

2+ git fetch origin ‘+refs/heads/feature%2Ftest:’ 0s

3fatal: couldn’t find remote ref refs/heads/feature%2Ftest