Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Table of Contents

Get a List of Favourites

DescriptionGet the logged in user's list of favourites

URL

/api/favourites

HTTP MethodGET
Response Formatsjson | xml

Security

Authentication required

Examples

Use CaseExample Request
Get the logged in user's list of favourites

GET http://localhost:9000/api/favourites

Parameters

Parameter

Description

Required

Default ValueExample Value
formatResponse formats.
Possible values: xml | json
NoNonejson

Create a Favourite

 

DescriptionCreate a favourite

URL

/api/favourites

HTTP MethodPOST

Security

Authentication required

Examples

Use CaseExample Request
Create a favourite on project Sonar (key = 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 =  org.codehaus.sonar:sonar) for the user admin/admin

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

Parameters

Parameter

Description

Required

Default Value

Example Value

key

id or key of the resource

Yes

None

org.codehaus.sonar:sonar

  • No labels