Sonatype Nexus Procurement Plugin API

Data

  • Default Namespace
  • XML Schema File: ns0.xsd

The data in this namespace is divided into elements and types. Types define the structure of the data. Elements define specific instances of the types, and are therefore more relevant to REST endpoints, which generally consume and/or produce elements.

The following elements are members of this namespace:

The following types are members of this namespace:

Element procuredRepositoriesList

DTO holding a list of procurement repositories.

Example XML

<?xml version="1.0" encoding="UTF-8"?> <procuredRepositoriesList> <data> <procuredRepository> <!--content of type 'procuredRepository'--> <repositoryId> <!--content of type 'string'--> ... </repositoryId> <targetClassId> <!--content of type 'string'--> ... </targetClassId> <targetId> <!--content of type 'string'--> ... </targetId> </procuredRepository> <procuredRepository> <!--(another 'procuredRepository' type)--> </procuredRepository> <!--...more "procuredRepository" elements...--> </data> </procuredRepositoriesList>

Example JSON

{ "data" : [ { "repositoryId" : "...", "targetClassId" : "...", "targetId" : "..." }, ... ] }

Element procurementStart

Example XML

<?xml version="1.0" encoding="UTF-8"?> <procurementStart> <data> <!--content of type 'procuredRepository'--> <repositoryId> <!--content of type 'string'--> ... </repositoryId> <targetClassId> <!--content of type 'string'--> ... </targetClassId> <targetId> <!--content of type 'string'--> ... </targetId> </data> </procurementStart>

Example JSON

{ "data" : { "repositoryId" : "...", "targetClassId" : "...", "targetId" : "..." } }

Element resolutionListResponse

The list of procurement rules DTO.

Example XML

<?xml version="1.0" encoding="UTF-8"?> <resolutionListResponse> <data> <artifactResolution> <!--content of type 'artifactResolution'--> <id> <!--content of type 'string'--> ... </id> <artifactCoordinate> <!--content of type 'procurementArtifactCoordinateDTO'--> <groupId> <!--content of type 'string'--> ... </groupId> <artifactId> <!--content of type 'string'--> ... </artifactId> <version> <!--content of type 'string'--> ... </version> </artifactCoordinate> <ruleTypeId> <!--content of type 'string'--> ... </ruleTypeId> <properties> <property> <!--content of type 'procurmentPropertyDTO'--> <key> <!--content of type 'string'--> ... </key> <value> <!--content of type 'string'--> ... </value> </property> <property> <!--(another 'procurmentPropertyDTO' type)--> </property> <!--...more "property" elements...--> </properties> </artifactResolution> <artifactResolution> <!--(another 'artifactResolution' type)--> </artifactResolution> <!--...more "artifactResolution" elements...--> </data> </resolutionListResponse>

Example JSON

{ "data" : [ { "id" : "...", "artifactCoordinate" : { "groupId" : "...", "artifactId" : "...", "version" : "..." }, "ruleTypeId" : "...", "properties" : [ { "key" : "...", "value" : "..." }, ... ] }, ... ] }

Element resolutionRequest

Example XML

<?xml version="1.0" encoding="UTF-8"?> <resolutionRequest> <data> <!--content of type 'artifactResolution'--> <id> <!--content of type 'string'--> ... </id> <artifactCoordinate> <!--content of type 'procurementArtifactCoordinateDTO'--> <groupId> <!--content of type 'string'--> ... </groupId> <artifactId> <!--content of type 'string'--> ... </artifactId> <version> <!--content of type 'string'--> ... </version> </artifactCoordinate> <ruleTypeId> <!--content of type 'string'--> ... </ruleTypeId> <properties> <property> <!--content of type 'procurmentPropertyDTO'--> <key> <!--content of type 'string'--> ... </key> <value> <!--content of type 'string'--> ... </value> </property> <property> <!--(another 'procurmentPropertyDTO' type)--> </property> <!--...more "property" elements...--> </properties> </data> </resolutionRequest>

Example JSON

{ "data" : { "id" : "...", "artifactCoordinate" : { "groupId" : "...", "artifactId" : "...", "version" : "..." }, "ruleTypeId" : "...", "properties" : [ { "key" : "...", "value" : "..." }, ... ] } }

Element resolutionResponse

Example XML

<?xml version="1.0" encoding="UTF-8"?> <resolutionResponse> <data> <!--content of type 'artifactResolution'--> <id> <!--content of type 'string'--> ... </id> <artifactCoordinate> <!--content of type 'procurementArtifactCoordinateDTO'--> <groupId> <!--content of type 'string'--> ... </groupId> <artifactId> <!--content of type 'string'--> ... </artifactId> <version> <!--content of type 'string'--> ... </version> </artifactCoordinate> <ruleTypeId> <!--content of type 'string'--> ... </ruleTypeId> <properties> <property> <!--content of type 'procurmentPropertyDTO'--> <key> <!--content of type 'string'--> ... </key> <value> <!--content of type 'string'--> ... </value> </property> <property> <!--(another 'procurmentPropertyDTO' type)--> </property> <!--...more "property" elements...--> </properties> </data> </resolutionResponse>

Example JSON

{ "data" : { "id" : "...", "artifactCoordinate" : { "groupId" : "...", "artifactId" : "...", "version" : "..." }, "ruleTypeId" : "...", "properties" : [ { "key" : "...", "value" : "..." }, ... ] } }

Type artifactResolution

A DTO holding the needed rule information.

Child Elements

name (type) min/max
occurs
description
id (string) 0/1 The ID of the rule.
artifactCoordinate (procurementArtifactCoordinateDTO) 0/1 The artifact coordinates that is used to match.
ruleTypeId (string) 0/1 The type of the rule.
property (procurmentPropertyDTO) 0/unbounded Rule properties.

Type procuredRepository

DTO holding the procurement repository informations: the procured repository ID, and the target identifiers.

Child Elements

name (type) min/max
occurs
description
repositoryId (string) 0/1 The repository ID of the procurement repository.
targetClassId (string) 0/1 The classId ("repository" or "group") of the target, that is being procured.
targetId (string) 0/1 The (repository or group) ID of the target, that is being procured.

Type procurementArtifactCoordinateDTO

The Maven coordinates (GAV) of the procured artifact.

Child Elements

name (type) min/max
occurs
description
groupId (string) 0/1 The coordinate's groupId part.
artifactId (string) 0/1 The coordinate's artifactId part.
version (string) 0/1 The coordintate's version part/

Type procurementRepositoryListResponseDTO

DTO holding a list of procurement repositories.

Child Elements

name (type) min/max
occurs
description
procuredRepository (procuredRepository) 0/unbounded The list of procured repositories.

Type procurementRuleListResponseDTO

The list of procurement rules DTO.

Child Elements

name (type) min/max
occurs
description
artifactResolution (artifactResolution) 0/unbounded The list of procurement rules.

Type procurementRuleRequestDTO

Child Elements

name (type) min/max
occurs
description
data (artifactResolution) 0/1 The procurement rule.

Type procurementRuleResponseDTO

Child Elements

name (type) min/max
occurs
description
data (artifactResolution) 0/1 The procurement rule.

Type procurementStartRequestDTO

Child Elements

name (type) min/max
occurs
description
data (procuredRepository) 0/1 The procurement request.

Type procurmentPropertyDTO

Child Elements

name (type) min/max
occurs
description
key (string) 0/1 Property key.
value (string) 0/1 Property value.