Registry Repositories
Functionality is available in Enterprise and Atlas versions.
A description of how the registry repositories functionality works is available here.
Description of the JSON object structure describing a registry repository
Field | Type | Description |
---|---|---|
title |
String | Name of the registry repository |
repositoryType |
String | Type of the registry repository. Possible values: LOCAL , PROXY , LOCAL_CACHE , VIRTUAL , TRASH_CAN |
repositoryUuid |
String | UUID of the registry repository |
packageType |
String | Type of packages in the registry repository. Possible values: generic , maven , npm , pypi , nuget , composer , opm , debian , container , helm , cran , rpm |
description |
String | Description of the registry repository |
Method for getting all registry repositories
Project: GET /registry/project/{ownerAlias}/{projectAlias}/repositories
Company: GET /registry/company/{companyAlias}/repositories
Whole service: GET /registry/instance/{projectAlias}/repositories
The request returns a list of registry repositories of the specified owner. It is possible to configure the number of objects displayed per page.
Path variable | Type | Description |
---|---|---|
ownerAlias |
String | Alias of the project owner |
projectAlias |
String | Alias of the project |
companyAlias |
String | Alias of the company |
Responses
STATUS 200
- List of registry repositories successfully returned:
Response example
{
"_embedded": {
"shortRegistryRepositoryDtoList": [
{
"title": "generic-local",
"repositoryType": "LOCAL",
"repositoryUuid": "b24769db-aaaa-aaaa-aaaa-a3006f0271f6",
"packageType": "generic",
"description": "Local generic registry repository",
},
{
"title": "maven-proxy",
"repositoryType": "PROXY",
"repositoryUuid": "ddc72f64-aaaa-aaaa-aaaa-e212e088bffc",
"packageType": "maven",
"description": "Proxy Maven registry repository",
},
{
"title": "maven-proxy-cache",
"repositoryType": "LOCAL_CACHE",
"repositoryUuid": "fa6d59b5-aaaa-aaaa-aaaa-cf1806aa929c",
"packageType": "maven",
"description": null,
}
{
"title": "maven-virtual",
"repositoryType": "VIRTUAL",
"repositoryUuid": "3cd7ccd1-aaaa-aaaa-aaaa-a1bfd03f9801",
"packageType": "maven",
"description": "Virtual Maven registry repository",
},
{
"title": "trashCan",
"repositoryType": "TRASH_CAN",
"repositoryUuid": "e510b751-aaaa-aaaa-aaaa-737daa2e7210",
"packageType": "generic",
"description": null,
},
]
},
"page": {
"size": 10,
"totalElements": 5,
"totalPages": 1,
"number": 0
}
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Method for getting a registry repository by UUID
Project: GET /registry/project/{ownerAlias}/{projectAlias}/repositories/{registryRepositoryUuid}
Company: GET /registry/company/{companyAlias}/repositories/{registryRepositoryUuid}
Whole service: GET /registry/instance/{projectAlias}/repositories/{registryRepositoryUuid}
The request returns a registry repository of the specified owner by the specified UUID.
Path variable | Type | Description |
---|---|---|
ownerAlias |
String | Alias of the project owner |
projectAlias |
String | Alias of the project |
companyAlias |
String | Alias of the company |
registryRepositoryUuid |
String | UUID of the registry repository |
Responses
STATUS 200
- Registry repository successfully returned:
Response example
{
"title": "generic-local",
"repositoryType": "LOCAL",
"repositoryUuid": "b24769db-aaaa-aaaa-aaaa-a3006f0271f6",
"packageType": "generic",
"description": "Local generic registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Method for creating a registry repository
Project: POST /registry/project/{ownerAlias}/{projectAlias}/repositories
Company: POST /registry/company/{companyAlias}/repositories
Whole service: POST /registry/instance/{projectAlias}/repositories
The request creates a registry repository owned by the specified entity and returns its UUID.
Path variable | Type | Description |
---|---|---|
ownerAlias |
String | Alias of the project owner |
projectAlias |
String | Alias of the project |
companyAlias |
String | Alias of the company |
Request
Supported JSON format
Depending on the set of fields passed in the request body, it is possible to create a local, proxy, or virtual repository.
Fields for creating a local repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To create a local repository, specify the value LOCAL |
repositoryName |
String | Name of the registry repository |
description |
String | Optional. Description of the registry repository |
packageType |
String | Type of packages in the registry repository. Possible values: generic , maven , npm , pypi , nuget , composer , opm , debian , container , helm , cran , rpm |
settings |
Object | Object with fields describing the settings of the local repository |
Set of fields describing the settings of a local repository:
Parameter | Type | Description |
---|---|---|
hasAnonymousAccess |
Boolean | Optional. Anonymous access allowed true or denied false (default) |
isDeletePackageAllowed |
Boolean | Optional. Package deletion allowed true or denied false (default) |
packageReuploadType |
String | Optional. Type of package overwriting. Possible values: NONE - prohibit overwriting or OVERRIDE - overwrite files (default) |
JSON object example
{
"type" : "LOCAL",
"repositoryName": "generic-local",
"description": "Local generic registry repository",
"packageType": "generic",
"settings": {
"hasAnonymousAccess": true,
"isDeletePackageAllowed": true,
"packageReuploadType": "OVERRIDE"
}
}
Responses
STATUS 201
- Local registry repository successfully created:
Response example
{
"title": "generic-local",
"repositoryType": "LOCAL",
"repositoryUuid": "b24769db-aaaa-aaaa-aaaa-a3006f0271f6",
"packageType": "generic",
"description": "Local generic registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Fields for creating a proxy repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To create a proxy repository, specify the value PROXY |
repositoryName |
String | Name of the registry repository |
description |
String | Optional. Description of the registry repository |
packageType |
String | Type of packages in the registry repository. Possible values: maven , npm , pypi , nuget , container |
proxySettings |
Object | Object with fields describing the settings of the proxy repository |
Set of fields describing the settings of a proxy repository:
Parameter | Type | Description |
---|---|---|
url |
String | Link to the external registry where requests will be proxied |
username |
String | Optional. Username for authorization in the external registry |
token |
String | Optional. Token or password for authorization in the external registry |
isCaching |
Boolean | Optional. The repository will save cached artifacts locally true or not false (default) |
isOffline |
Boolean | Optional. Artifacts can be obtained only from the local cache true or not false (default) |
expireHours |
Integer | Optional. Lifetime of unused artifacts (in hours). A value of 0 (default) indicates no limit. |
metadataRetrievalIntervalSeconds |
Integer | Optional. Period for caching artifact metadata (in seconds). A value of 0 indicates no caching. Default is 7200. |
JSON object example
{
"type" : "PROXY",
"repositoryName": "maven-proxy",
"description": "Proxy Maven registry repository",
"packageType": "maven",
"proxySettings": {
"url": "https://repo.maven.apache.org/maven2/",
"username": "username",
"isCaching": true,
"token": "qwerty123",
"isOffline": false,
"expireHours": 24,
"metadataRetrievalIntervalSeconds": 7200
}
}
Responses
STATUS 201
- Proxy registry repository successfully created:
Response example
{
"title": "maven-proxy",
"repositoryType": "PROXY",
"repositoryUuid": "ddc72f64-aaaa-aaaa-aaaa-e212e088bffc",
"packageType": "maven",
"description": "Proxy Maven registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Fields for creating a virtual repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To create a virtual repository, specify the value VIRTUAL |
repositoryName |
String | Name of the registry repository |
description |
String | Optional. Description of the registry repository |
packageType |
String | Type of packages in the registry repository. Possible values: generic , maven , npm , pypi , nuget , composer , opm , debian , container , helm , cran , rpm |
virtualSettings |
Object | Object with fields describing the settings of the virtual repository |
Settings of a virtual repository:
Parameter | Type | Description |
---|---|---|
includedRepositoryUuids |
Array | Array containing UUIDs of registry repositories to be included in the created virtual repository |
allowRemoteProxying |
Boolean | Optional. Requests to proxy repositories can fetch proxied packages true or cannot false (default) |
deploymentRepositoryUuid |
String | Optional. UUID of the local registry repository selected as the default deployment repository |
JSON object example
{
"type" : "VIRTUAL",
"repositoryName": "maven-virtual",
"description": "Virtual Maven registry repository",
"packageType": "maven",
"virtualSettings": {
"includedRepositoryUuids": [
"ddc72f64-aaaa-aaaa-aaaa-e212e088bffc",
"fa6d59b5-aaaa-aaaa-aaaa-cf1806aa929c"
],
"allowRemoteProxying": true,
"deploymentRepositoryUuid": "fa6d59b5-aaaa-aaaa-aaaa-cf1806aa929c"
}
}
Responses
STATUS 201
- Virtual registry repository successfully created:
Response example
{
"title": "maven-virtual",
"repositoryType": "VIRTUAL",
"repositoryUuid": "3cd7ccd1-aaaa-aaaa-aaaa-a1bfd03f9801",
"packageType": "maven",
"description": "Virtual Maven registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Method for modifying a registry repository
Project: PUT /registry/project/{ownerAlias}/{projectAlias}/repositories/{registryRepositoryUuid}
Company: PUT /registry/company/{companyAlias}/repositories/{registryRepositoryUuid}
Whole service: PUT /registry/instance/repositories/{registryRepositoryUuid}
The request modifies the specified registry repository of the specified owner and returns its UUID.
Path variable | Type | Description |
---|---|---|
ownerAlias |
String | Alias of the project owner |
projectAlias |
String | Alias of the project |
companyAlias |
String | Alias of the company |
registryRepositoryUuid |
String | UUID of the registry repository |
Request
Supported JSON format
Depending on the set of fields passed in the request body, it is possible to modify a local, proxy, or virtual repository.
Fields for modifying a local repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To modify a local repository, specify the value LOCAL |
description |
String | Optional. Description of the registry repository |
settings |
Object | Object with fields describing the settings of the local repository |
Set of fields describing the settings of a local repository:
Parameter | Type | Description |
---|---|---|
hasAnonymousAccess |
Boolean | Optional. Anonymous access allowed true or denied false (default) |
isDeletePackageAllowed |
Boolean | Optional. Package deletion allowed true or denied false (default) |
packageReuploadType |
String | Optional. Type of package overwriting. Possible values: NONE - prohibit overwriting or OVERRIDE - overwrite files |
JSON object example
{
"type" : "LOCAL",
"description": "Local generic registry repository",
"settings": {
"hasAnonymousAccess": true,
"isDeletePackageAllowed": true,
"packageReuploadType": "OVERRIDE"
}
}
Responses
STATUS 200
- Local registry repository successfully modified:
Response example
{
"title": "generic-local",
"repositoryType": "LOCAL",
"repositoryUuid": "b24769db-aaaa-aaaa-aaaa-a3006f0271f6",
"packageType": "generic",
"description": "Local generic registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Fields for modifying a proxy repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To modify a proxy repository, specify the value PROXY |
description |
String | Optional. Description of the registry repository |
proxySettings |
Object | Object with fields describing the settings of the proxy repository |
Set of fields describing the settings of a proxy repository:
Parameter | Type | Description |
---|---|---|
url |
String | Optional. Link to the external registry where requests will be proxied |
username |
String | Optional. Username for authorization in the external registry |
token |
String | Optional. Token or password for authorization in the external registry |
isCaching |
Boolean | Optional. The repository will save cached artifacts locally true or not false |
isOffline |
Boolean | Optional. Artifacts can be obtained only from the local cache true or not false (default) |
expireHours |
Integer | Optional. Lifetime of unused artifacts (in hours) |
metadataRetrievalIntervalSeconds |
Integer | Optional. Period for caching artifact metadata (in seconds) |
JSON object example
{
"type" : "PROXY",
"description": "Proxy Maven registry repository",
"proxySettings": {
"url": "https://repo.maven.apache.org/maven2/",
"username": "username",
"isCaching": true,
"token": "qwerty123",
"isOffline": false,
"expireHours": 24,
"metadataRetrievalIntervalSeconds": 7200
}
}
Responses
STATUS 200
- Proxy registry repository successfully modified:
Response example
{
"title": "maven-proxy",
"repositoryType": "PROXY",
"repositoryUuid": "ddc72f64-aaaa-aaaa-aaaa-e212e088bffc",
"packageType": "maven",
"description": "Proxy Maven registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Fields for modifying a virtual repository
Parameter | Type | Description |
---|---|---|
type |
String | Type of the registry repository. To modify a virtual repository, specify the value VIRTUAL |
description |
String | Optional. Description of the registry repository |
virtualSettings |
Object | Object with fields describing the settings of the virtual repository |
Settings of a virtual repository:
Parameter | Type | Description |
---|---|---|
includedRepositoryUuids |
Array | Optional. Array containing UUIDs of registry repositories to be included in the modified virtual repository |
allowRemoteProxying |
Boolean | Optional. Requests to proxy repositories can fetch proxied packages true or cannot false (default) |
deploymentRepositoryUuid |
String | Optional. UUID of the local registry repository selected as the default deployment repository |
When modifying one of the fields
deploymentRepositoryUuid
orincludedRepositoryUuids
, both must be passed.
JSON object example
{
"type" : "VIRTUAL",
"description": "Virtual Maven registry repository",
"virtualSettings": {
"includedRepositoryUuids": [
"ddc72f64-aaaa-aaaa-aaaa-e212e088bffc",
"fa6d59b5-aaaa-aaaa-aaaa-cf1806aa929c"
],
"allowRemoteProxying": true,
"deploymentRepositoryUuid": "fa6d59b5-aaaa-aaaa-aaaa-cf1806aa929c"
}
}
Responses
STATUS 200
- Virtual registry repository successfully modified:
Response example
{
"title": "maven-virtual",
"repositoryType": "VIRTUAL",
"repositoryUuid": "3cd7ccd1-aaaa-aaaa-aaaa-a1bfd03f9801",
"packageType": "maven",
"description": "Virtual Maven registry repository",
}
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.
Method for deleting a registry repository
Project: DELETE /registry/project/{ownerAlias}/{projectAlias}/repositories/{registryRepositoryUuid}
Company: DELETE /registry/company/{companyAlias}/repositories/{registryRepositoryUuid}
Whole service: DELETE /registry/instance/repositories/{registryRepositoryUuid}
The request deletes the specified registry repository of the project.
Path variable | Type | Description |
---|---|---|
ownerAlias |
String | Alias of the project owner |
projectAlias |
String | Alias of the project |
companyAlias |
String | Alias of the company |
registryRepositoryUuid |
String | UUID of the registry repository |
Responses
STATUS 204
- Registry repository successfully deleted.
STATUS 403
- No access rights.
STATUS 404
- Data not found for the request.