Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-7970

Create /api/settings/set WS

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.1
    • Component/s: Settings, Web API
    • Labels:

      Description

      This WS is updating the value (or values) of a property key.
      It will be internal in 6.1, to be sure it's answering to all needs.

      Definition

      • key : mandatory property key
      • value/values/fieldValues : mandatory value (cannot be empty). For property set, it should be a JSON (see example below).
      • componentId/componentKey: component uuid or key

      Example

      • Updating a value
        POST /api/settings/set?key=sonar.autogenerated&value=abc
        
      • Updating many values
        POST /api/settings/set?key=sonar.autogenerated&values=val1&values=val2
        
      • Updating a property set (every lines must be set)
        POST /api/settings/set?key=sonar.demo&fieldValues=[{"text":"bla","boolean":"true","license":"abcd","metric":"ncloc"},{"text":"blo","boolean":"false","license":"efgh","metric":"debt"}]
        

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              teryk.bellahsene Teryk Bellahsene
              Reporter:
              julien.lancelot Julien Lancelot
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: