Update the priorities of branch protections for a repository.
POST
/repos/{owner}/{repo}/branch_protections/priority
const url = 'https://gitea.com/api/v1/repos/example/example/branch_protections/priority';const options = { method: 'POST', headers: {Authorization: 'Basic <credentials>', 'Content-Type': 'application/json'}, body: '{"ids":[1]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://gitea.com/api/v1/repos/example/example/branch_protections/priority \ --header 'Authorization: Basic <credentials>' \ --header 'Content-Type: application/json' \ --data '{ "ids": [ 1 ] }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”owner
required
string
Owner of the repo
repo
required
string
Name of the repo
Request Body
Section titled “Request Body”Media typeapplication/json
UpdateBranchProtectionPriories
A list to update the branch protection rule priorities
object
ids
Array<integer>
Example generated
{ "ids": [ 1 ]}Responses
Section titled “Responses”APIEmpty is an empty response
default
Section titled “default”APIError is error format response
Headers
Section titled “Headers”message
string
url
string