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 4 Next »

DescriptionGet a list of lines of source code

URL

/api/sources

MethodGET

Security

Requires User role on the project

Examples

  1. Get source code of 'org.codehaus.sonar:sonar-plugin-api:org.sonar.api.measures.CoreMetrics' from line 10 to 20:

Parameters

Parameter

Description

Required

Default Value

resource

id or key of the resource

Yes

None

from

First line to display

No

None

to

Last line to display (inclusive)

No

None

color

Highlights code syntax if true.
Possible values: true | false 

No

false
formatResponse formats: xml or json or txtNoxml
  • No labels