Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

 

DescriptionCreate a favourite

URL

/api/favourites

HTTP MethodPOST

Security

Authentication required

Examples

Use CaseExample Request
Create a favourite on project Sonar (key = project org.codehaus.sonar:sonar) for the user admin/admin

curl -u admin:admin -d "key=org.codehaus.sonar:sonar" http://localhost:9000/api/favourites

Parameters

Parameter

Description

Required

Default Value

Example Value

key

id or key of the resource

Yes

None

org.codehaus.sonar:sonar

Delete a Favourite

 

DescriptionDelete a favourite

URL

/api/favourites/:key

HTTP MethodDELETE

Security

Authentication required

Examples

Use CaseExample Request
Delete the favourite flag on project Sonar (key =  orgorg.codehaus.sonar:sonar) for the user admin/admin

curl -u admin:admin -X DELETE http://localhost:9000/api/favourites/org.codehaus.sonar:sonar

 

...

Parameter

Description

Required

Default Value

Example Value

key

id or key of the resource

Yes

Noneorg.codehaus.sonar:sonar