diff --git a/SOL005/VNFSnapshotPackageManagement-API/AccessConfigurationForExternalArtifacts.robot b/SOL005/VNFSnapshotPackageManagement-API/AccessConfigurationForExternalArtifacts.robot index cad4a06c60af7cbb0f9b51ab6d75b8f555260bce..47e42406648990999e14d22f6deab147ffe83a2d 100644 --- a/SOL005/VNFSnapshotPackageManagement-API/AccessConfigurationForExternalArtifacts.robot +++ b/SOL005/VNFSnapshotPackageManagement-API/AccessConfigurationForExternalArtifacts.robot @@ -25,7 +25,7 @@ GET Access Configuration for External Artifacts ... Post-Conditions: none GET Access Configuration for External Artifacts Check HTTP Response Status Code Is 200 - Check HTTP Response Body Json Schema Is VnfSnapshotPkgExtArtifactsAccessInfo + Check HTTP Response Body Json Schema Is VnfSnapshotPkgExtArtifactsAccessConfig PUT Access Configuration for External Artifacts [Documentation] Test ID: 5.3.7.9.3 @@ -38,7 +38,7 @@ PUT Access Configuration for External Artifacts ... Post-Conditions: none PUT Access Configuration for External Artifacts Check HTTP Response Status Code Is 200 - Check HTTP Response Body Json Schema Is VnfSnapshotPkgExtArtifactsAccessInfo + Check HTTP Response Body Json Schema Is VnfSnapshotPkgExtArtifactsAccessConfig PUT Access Configuration for External Artifacts - Conflict [Documentation] Test ID: 5.3.7.9.4 diff --git a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index fd2074090bb0f703c9ab45565e6cf0a744737641..165ffc5bba09b260e18d55da11fc4fbafd049b7e 100644 --- a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -774,7 +774,8 @@ PUT Access Configuration for External Artifacts Set Headers {"Accept":"${ACCEPT_JSON}"} Set Headers {"Content-Type":"${CONTENT_TYPE_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - ${body}= Get File jsons/VnfSnapshotPkgExtArtifactsAccessInfo.json + ${template}= Get File jsons/VnfSnapshotPkgExtArtifactsAccessConfig.json + ${body}= Format String ${template} artifactUri=${ext_artifactPath} Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/ext_artifacts_access ${body} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -785,7 +786,8 @@ PUT Access Configuration for External Artifacts - Conflict Set Headers {"Accept":"${ACCEPT_JSON}"} Set Headers {"Content-Type":"${CONTENT_TYPE_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - ${body}= Get File jsons/VnfSnapshotPkgExtArtifactsAccessInfo.json + ${template}= Get File jsons/VnfSnapshotPkgExtArtifactsAccessConfig.json + ${body}= Format String ${template} artifactUri=${ext_artifactPath} Put ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/ext_artifacts_access ${body} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} diff --git a/SOL005/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgExtArtifactsAccessConfig.schema.json b/SOL005/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgExtArtifactsAccessConfig.schema.json new file mode 100644 index 0000000000000000000000000000000000000000..f6252a50874252521e3d793e45ea3b0f991a77eb --- /dev/null +++ b/SOL005/VNFSnapshotPackageManagement-API/schemas/VnfSnapshotPkgExtArtifactsAccessConfig.schema.json @@ -0,0 +1,68 @@ +{ + "description": "This type represents the access configuration information for downloading external VNF snapshot package artifacts. The NFVO can obtain the external VNF snapshot package artifact file through the information provided in this structure, together with information provided in the manifest. The data structure shall comply with the provisions defined in Table 11.5.2.9-1. If the data structure is part of a response body, security-sensitive attributes shall be excluded as specified in Table 11.5.2.9-1.\n", + "type": "object", + "properties": { + "artifact": { + "description": "Access configuration information for an external artifact.\n", + "type": "array", + "items": { + "type": "object", + "required": [ + "artifactUri" + ], + "properties": { + "artifactUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string", + "format": "uri" + }, + "overrideUri": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string", + "format": "uri" + }, + "authType": { + "description": "Defines the type of authentication / authorization for downloading the VNF package.\nPermitted values: - BASIC: Only the \"username\" and \"password\" attributes shall be present. - OAUTH2_CLIENT_CREDENTIALS: Only the \"paramsOauth2ClientCredentials\" attribute shall be present.\nThis attribute shall not be present if no credentials are provided for the artifact.\n", + "type": "string", + "enum": [ + "BASIC", + "OAUTH2_CLIENT_CREDENTIALS" + ] + }, + "username": { + "description": "Username to be used for authentication.\n", + "type": "string" + }, + "password": { + "description": "Password to be used for authentication. Shall not be present in response bodies.\n", + "type": "string" + }, + "paramsOauth2ClientCredentials": { + "description": "Parameters for authentication/authorization using OAUTH2_CLIENT_CREDENTIALS.\n", + "type": "object", + "required": [ + "clientId", + "clientPassword", + "tokenEndpoint" + ], + "properties": { + "clientId": { + "description": "Client identifier to be used in the access token request of the OAuth 2.0 client credentials grant type.\n", + "type": "string" + }, + "clientPassword": { + "description": "Client password to be used in the access token request of the OAuth 2.0 client credentials grant type. Shall not be present in response bodies.\n", + "type": "string" + }, + "tokenEndpoint": { + "description": "String formatted according to IETF RFC 3986.\n", + "type": "string", + "format": "uri" + } + } + } + } + } + } + } +} \ No newline at end of file