Sei sulla pagina 1di 3

SonarQube­4.

3 /  Documentation /  Web Service API

Web Service /api/projects
Creado por Ben Walding el jul 13, 2014

Table of Contents
Delete a Project
Provision a Project

Delete a Project
Description Delete a project

URL /api/projects/<project_id>

HTTP Method DELETE

Security Requires Administer permission on project

Examples

Use Case Example Request

Delete project "myProject" with user
"admin/admin" curl ­u admin:admin ­X DELETE
'http://localhost:9000/api/projects/myProject'

Parameters

Parameter Description Required Default Value Example Value

project_id id or key of the project Yes None org.codehaus.sonar:sonar


Provision a Project
Description Provision a project

URL /api/projects/create

HTTP Method POST

Security Requires Provision Projects permission

Available since Version 4.0

Examples

Use Case Example Request

Provision project whose key is "myKey" and name is
"myProject" with user "admin/admin" curl ­u admin:admin ­X POST
'http://localhost:9000/api/projects/create?
key=myKey&name=myProject' 

Response Format

JSON

{
    "id":"12",
    "k":"myKey",
    "nm":"myProject",
    "sc":"PRJ",
    "qu":"TRK"
}
Parameters

Parameter Description Required Default Value Example Value

key Key of the project Yes None org.codehaus.sonar:sonar

name Name of the project Yes None My%20Project

Potrebbero piacerti anche