Enhance Activity Spec 17/37717/3
authorshrikantawachar <shrikant.awachar@amdocs.com>
Thu, 22 Mar 2018 09:31:28 +0000 (15:01 +0530)
committerOren Kleks <orenkle@amdocs.com>
Thu, 22 Mar 2018 15:02:46 +0000 (15:02 +0000)
Enhance Activity Spec to include additional fields type and content.

Change-Id: Ic39aa21ef265bf07a5522a2f46f84d378316c7aa
Issue-ID: SDC-1048
Signed-off-by: shrikantawachar <shrikant.awachar@amdocs.com>
12 files changed:
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/api/rest/mapping/MapActivitySpecRequestDtoToActivitySpecEntity.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/api/rest/mapping/MapActivitySpecToActivitySpecGetResponse.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/api/rest/types/ActivitySpecGetResponse.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/api/rest/types/ActivitySpecRequestDto.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/be/dao/impl/ActivitySpecDaoZusammenImpl.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/be/dao/types/ActivitySpecEntity.java
services/activity-spec/activity-spec-web/activity-spec-service/src/main/java/org/openecomp/activityspec/be/datatypes/ActivitySpecData.java
services/activity-spec/activity-spec-web/activity-spec-service/src/test/java/org/openecomp/activityspec/be/dao/impl/ActivitySpecZusammenDaoImplTest.java
services/activity-spec/activity-spec-web/activity-spec-service/src/test/java/org/openecomp/activityspec/be/impl/ActivitySpecManagerImplTest.java
services/activity-spec/activity-spec-web/activity-spec-service/src/test/java/org/openecomp/activityspec/mocks/ItemManagerMock.java
services/activity-spec/swagger-ui/api-docs/api.html [deleted file]
services/activity-spec/swagger-ui/api-docs/api.json [deleted file]

index 2062fe2..2364d59 100644 (file)
@@ -35,17 +35,19 @@ public class MapActivitySpecRequestDtoToActivitySpecEntity
     target.setDescription(source.getDescription());
     target.setCategoryList(source.getCategoryList() == null ? new ArrayList<String>()
         : source.getCategoryList());
-    if (Objects.nonNull(source.getInputParameters())) {
-      target.setInputParameters(source.getInputParameters().stream()
+    if (Objects.nonNull(source.getInputs())) {
+      target.setInputs(source.getInputs().stream()
           .map(activitySpecParameterDto -> new MapDtoToActivityParameter()
               .applyMapping(activitySpecParameterDto, ActivitySpecParameter.class))
                 .collect(Collectors.toList()));
     }
-    if (Objects.nonNull(source.getOutputParameters())) {
-      target.setOutputParameters(source.getOutputParameters().stream()
+    if (Objects.nonNull(source.getOutputs())) {
+      target.setOutputs(source.getOutputs().stream()
           .map(activitySpecParameterDto -> new MapDtoToActivityParameter()
               .applyMapping(activitySpecParameterDto, ActivitySpecParameter.class))
           .collect(Collectors.toList()));
     }
+    target.setType(source.getType());
+    target.setContent(source.getContent());
   }
 }
index 25e0f6e..697e1bd 100644 (file)
@@ -32,18 +32,20 @@ public class MapActivitySpecToActivitySpecGetResponse extends MappingBase<Activi
     target.setName(source.getName());
     target.setDescription(source.getDescription());
     target.setCategoryList(source.getCategoryList());
-    if (Objects.nonNull(source.getInputParameters())) {
-      target.setInputParameters(source.getInputParameters().stream().map(
+    if (Objects.nonNull(source.getInputs())) {
+      target.setInputs(source.getInputs().stream().map(
           activitySpecParameter -> new MapActivityParameterToDto()
               .applyMapping(activitySpecParameter, ActivitySpecParameterDto
                   .class)).collect(Collectors.toList()));
     }
-    if (Objects.nonNull(source.getOutputParameters())) {
-      target.setOutputParameters(source.getOutputParameters().stream().map(
+    if (Objects.nonNull(source.getOutputs())) {
+      target.setOutputs(source.getOutputs().stream().map(
           activitySpecParameter -> new MapActivityParameterToDto()
               .applyMapping(activitySpecParameter, ActivitySpecParameterDto
                   .class)).collect(Collectors.toList()));
     }
     target.setStatus(source.getStatus());
+    target.setType(source.getType());
+    target.setContent(source.getContent());
   }
 }
index cf3fa96..9453935 100644 (file)
@@ -23,7 +23,9 @@ public class ActivitySpecGetResponse  {
   private String name;
   private String description;
   private List<String> categoryList;
-  private List<ActivitySpecParameterDto> inputParameters;
-  private List<ActivitySpecParameterDto> outputParameters;
+  private List<ActivitySpecParameterDto> inputs;
+  private List<ActivitySpecParameterDto> outputs;
   private String status;
+  private String type;
+  private String content;
 }
index 77ea393..67455f9 100644 (file)
@@ -32,6 +32,8 @@ public class ActivitySpecRequestDto {
   private String description;
 
   private List<String> categoryList;
-  private List<ActivitySpecParameterDto> inputParameters;
-  private List<ActivitySpecParameterDto> outputParameters;
+  private List<ActivitySpecParameterDto> inputs;
+  private List<ActivitySpecParameterDto> outputs;
+  private String type;
+  private String content;
 }
index d9d495a..0dabcca 100644 (file)
@@ -112,8 +112,10 @@ public class ActivitySpecDaoZusammenImpl implements ActivitySpecDao {
   private void enrichEntityFromElementData(ActivitySpecEntity entity, InputStream data) {
     ActivitySpecData activitySpecData = JsonUtil.json2Object(data, ActivitySpecData.class);
     if (Objects.nonNull(activitySpecData)) {
-      entity.setInputParameters(activitySpecData.getInputParameters());
-      entity.setOutputParameters(activitySpecData.getOutputParameters());
+      entity.setInputs(activitySpecData.getInputs());
+      entity.setOutputs(activitySpecData.getOutputs());
+      entity.setType(activitySpecData.getType());
+      entity.setContent(activitySpecData.getContent());
     }
   }
 
@@ -127,8 +129,10 @@ public class ActivitySpecDaoZusammenImpl implements ActivitySpecDao {
 
   private void enrichElementDataFromEntity(ZusammenElement element, ActivitySpecEntity entity) {
     ActivitySpecData activitySpecData = new ActivitySpecData();
-    activitySpecData.setInputParameters(entity.getInputParameters());
-    activitySpecData.setOutputParameters(entity.getOutputParameters());
+    activitySpecData.setInputs(entity.getInputs());
+    activitySpecData.setOutputs(entity.getOutputs());
+    activitySpecData.setType(entity.getType());
+    activitySpecData.setContent(entity.getContent());
     element.setData(new ByteArrayInputStream(JsonUtil.object2Json(activitySpecData).getBytes()));
   }
 
index b21e424..2f261f8 100644 (file)
@@ -29,8 +29,10 @@ public class ActivitySpecEntity {
   private String description;
 
   private List<String> categoryList;
-  private List<ActivitySpecParameter> inputParameters;
-  private List<ActivitySpecParameter> outputParameters;
+  private List<ActivitySpecParameter> inputs;
+  private List<ActivitySpecParameter> outputs;
+  private String type;
+  private String content;
 
   //Not to be maintained in activityspec element
   private String status;
index e884bfc..ad70376 100644 (file)
@@ -21,7 +21,9 @@ import java.util.List;
 
 @lombok.Data
 public class ActivitySpecData {
-  private List<ActivitySpecParameter> inputParameters = Collections.emptyList();
-  private List<ActivitySpecParameter> outputParameters = Collections.emptyList();
+  private List<ActivitySpecParameter> inputs = Collections.emptyList();
+  private List<ActivitySpecParameter> outputs = Collections.emptyList();
+  private String type;
+  private String content;
 }
 
index e6b8123..b03f454 100644 (file)
@@ -94,7 +94,7 @@ public class ActivitySpecZusammenDaoImplTest {
     inputParams.setValue("localhost");
     List<ActivitySpecParameter> inputs = new ArrayList<>();
     inputs.add(inputParams);
-    entity.setInputParameters(inputs);
+    entity.setInputs(inputs);
   }
 
   @AfterMethod
@@ -130,8 +130,8 @@ public class ActivitySpecZusammenDaoImplTest {
         .getElement(context, elementContext, zusammenAdaptor.elementId);
     final InputStream data = testElement.get().getData();
     final ActivitySpecData activitySpecData = JsonUtil.json2Object(data, ActivitySpecData.class);
-    Assert.assertEquals(activitySpecData.getInputParameters().get(0).getName(),
-        entity.getInputParameters().get(0).getName());
+    Assert.assertEquals(activitySpecData.getInputs().get(0).getName(),
+        entity.getInputs().get(0).getName());
   }
 
   @Test
index ce0f288..3576ae8 100644 (file)
@@ -47,7 +47,7 @@ import java.util.List;
 public class ActivitySpecManagerImplTest {
 
   private static final String STRING_TYPE = "String";
-  ActivitySpecEntity activitySpec;
+  private ActivitySpecEntity activitySpec;
   private ActivitySpecEntity retrieved;
   private ActivitySpecEntity input;
   private ActivitySpecEntity activitySpecToCreate;
@@ -106,13 +106,13 @@ public class ActivitySpecManagerImplTest {
     List<ActivitySpecParameter> inputs = new ArrayList<>();
     inputs.add(inputParams);
     inputs.add(inputParams1);
-    activitySpecToCreate.setInputParameters(inputs);
+    activitySpecToCreate.setInputs(inputs);
 
     ActivitySpecParameter outputParams = new ActivitySpecParameter("status", STRING_TYPE);
     outputParams.setValue("started");
     List<ActivitySpecParameter> outputs = new ArrayList<>();
     outputs.add(outputParams);
-    activitySpecToCreate.setOutputParameters(outputs);
+    activitySpecToCreate.setOutputs(outputs);
 
     activitySpec = activitySpecManager.createActivitySpec
         (activitySpecToCreate);
@@ -239,7 +239,7 @@ public class ActivitySpecManagerImplTest {
     Assert.assertEquals(actual.getName(), expected.getName());
     Assert.assertEquals(actual.getDescription(), expected.getDescription());
     Assert.assertEquals(actual.getCategoryList(), expected.getCategoryList());
-    Assert.assertEquals(actual.getInputParameters(), expected.getInputParameters());
-    Assert.assertEquals(actual.getOutputParameters(), expected.getOutputParameters());
+    Assert.assertEquals(actual.getInputs(), expected.getInputs());
+    Assert.assertEquals(actual.getOutputs(), expected.getOutputs());
   }
 }
index 667a97b..2a0586c 100644 (file)
@@ -18,9 +18,7 @@ package org.openecomp.activityspec.mocks;
 
 
 import java.util.ArrayList;
-import java.util.Collections;
 import java.util.List;
-import java.util.stream.Collectors;
 import org.openecomp.sdc.versioning.dao.types.VersionStatus;
 import org.openecomp.sdc.versioning.types.Item;
 import org.openecomp.sdc.versioning.ItemManager;
@@ -30,15 +28,14 @@ import java.util.function.Predicate;
 
 public class ItemManagerMock implements ItemManager {
 
-  public String id;
-  public Item item;
+  private String id;
+  private Item item;
 
 
   @Override
   public Collection<Item> list(Predicate<Item> predicate) {
     List<Item> items = new ArrayList<>();
     items.add(item);
-    Collection<Item> collection = items;
     return items;
   }
 
@@ -61,6 +58,15 @@ public class ItemManagerMock implements ItemManager {
 
   }
 
+  @Override
+  public void archive(Item item) {
+
+  }
+
+  @Override
+  public void restore(Item item) {
+
+  }
 
 
   @Override
diff --git a/services/activity-spec/swagger-ui/api-docs/api.html b/services/activity-spec/swagger-ui/api-docs/api.html
deleted file mode 100644 (file)
index 8ec70b3..0000000
+++ /dev/null
@@ -1,683 +0,0 @@
-<!DOCTYPE html>
-<html>
-<title>API Document</title>
-
-<!--xmp theme="united" style="display:none;"-->
-<xmp theme="united" style="display:none;">
-#Rest API
-
-
-## HTTP:///activityspec-api
-
-
-Rest API Documentation
-
-
-
-**Version** v1.0, build #${buildNumber}
-
-
-
-
-
-
-
-
-
-
-
-
-# APIs
-
-
-## /v1.0/activity-spec
-
-
-### GET
-
-<a id="list">Get list of activity specs </a>
-
-
-
-
-
-
-
-
-
-#### Request
-
-
-**Content-Type: ** application/json
-
-##### Parameters
-
-<table border="1">
-    <tr>
-        <th>Name</th>
-        <th>Located in</th>
-        <th>Required</th>
-        <th>Description</th>
-        <th>Default</th>
-        <th>Schema</th>
-    </tr>
-
-
-
-<tr>
-    <th>status</th>
-    <td>query</td>
-    <td>no</td>
-    <td>Currently supported values: &#x27;Certified&#x27; - only activity specs with Certified status</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>USER_ID</th>
-    <td>header</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-
-</table>
-
-
-
-#### Response
-
-**Content-Type: ** application/json
-
-
-| Status Code | Reason      | Response Model |
-|-------------|-------------|----------------|
-| default    | successful operation |  - |
-
-
-
-
-
-
-### POST
-
-
-<a id="createActivitySpec">Create Activity Spec</a>
-
-
-
-
-
-
-
-
-
-#### Request
-
-
-**Content-Type: ** application/json
-
-##### Parameters
-
-<table border="1">
-    <tr>
-        <th>Name</th>
-        <th>Located in</th>
-        <th>Required</th>
-        <th>Description</th>
-        <th>Default</th>
-        <th>Schema</th>
-    </tr>
-
-
-
-<tr>
-    <th>body</th>
-    <td>body</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    <td>
-    
-    <a href="#/definitions/ActivitySpecRequest">ActivitySpecRequest</a> 
-    </td>
-
-</tr>
-
-<tr>
-    <th>USER_ID</th>
-    <td>header</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-
-</table>
-
-
-
-#### Response
-
-**Content-Type: ** application/json
-
-
-| Status Code | Reason      | Response Model |
-|-------------|-------------|----------------|
-| default    | successful operation |  - |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-## /v1.0/activity-spec/{id}/versions/{versionId}
-
-
-### GET
-
-<a id="getActivitySpec">Get Activity Spec</a>
-
-
-
-
-
-
-
-
-
-#### Request
-
-
-**Content-Type: ** application/json
-
-##### Parameters
-
-<table border="1">
-    <tr>
-        <th>Name</th>
-        <th>Located in</th>
-        <th>Required</th>
-        <th>Description</th>
-        <th>Default</th>
-        <th>Schema</th>
-    </tr>
-
-
-
-<tr>
-    <th>id</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Activity Spec Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>versionId</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Version Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>USER_ID</th>
-    <td>header</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-
-</table>
-
-
-
-#### Response
-
-**Content-Type: ** application/json
-
-
-| Status Code | Reason      | Response Model |
-|-------------|-------------|----------------|
-| default    | successful operation |  - |
-
-
-
-
-### PUT
-
-<a id="updateActivitySpec">Update Activity Spec</a>
-
-
-
-
-
-
-
-
-
-#### Request
-
-
-**Content-Type: ** application/json
-
-##### Parameters
-
-<table border="1">
-    <tr>
-        <th>Name</th>
-        <th>Located in</th>
-        <th>Required</th>
-        <th>Description</th>
-        <th>Default</th>
-        <th>Schema</th>
-    </tr>
-
-
-
-<tr>
-    <th>body</th>
-    <td>body</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    <td>
-    
-    <a href="#/definitions/ActivitySpecRequest">ActivitySpecRequest</a> 
-    </td>
-
-</tr>
-
-<tr>
-    <th>id</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Activity Spec Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>versionId</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Version Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>USER_ID</th>
-    <td>header</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-
-</table>
-
-
-
-#### Response
-
-**Content-Type: ** application/json
-
-
-| Status Code | Reason      | Response Model |
-|-------------|-------------|----------------|
-| default    | successful operation |  - |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-## /v1.0/activity-spec/{id}/versions/{versionId}/actions
-
-
-
-
-### PUT
-
-<a id="actOnActivitySpec">Actions on a activity spec</a>
-
-Performs one of the following actions on a activity spec: |Submit: Finalize its active version.|Deprecate: Deprecate activity spec.|
-
-
-
-
-
-
-
-#### Request
-
-
-**Content-Type: ** application/json
-
-##### Parameters
-
-<table border="1">
-    <tr>
-        <th>Name</th>
-        <th>Located in</th>
-        <th>Required</th>
-        <th>Description</th>
-        <th>Default</th>
-        <th>Schema</th>
-    </tr>
-
-
-
-<tr>
-    <th>body</th>
-    <td>body</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    <td>
-    
-    <a href="#/definitions/ActivitySpecActionRequestDto">ActivitySpecActionRequestDto</a> 
-    </td>
-
-</tr>
-
-<tr>
-    <th>id</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Activity Spec Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>versionId</th>
-    <td>path</td>
-    <td>yes</td>
-    <td>Version Id</td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-<tr>
-    <th>USER_ID</th>
-    <td>header</td>
-    <td>no</td>
-    <td></td>
-    <td> - </td>
-
-    
-            <td>string </td>
-    
-
-</tr>
-
-
-</table>
-
-
-
-#### Response
-
-**Content-Type: ** application/json
-
-
-| Status Code | Reason      | Response Model |
-|-------------|-------------|----------------|
-| default    | successful operation |  - |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Definitions
-
-## <a name="/definitions/ActivitySpecActionRequestDto">ActivitySpecActionRequestDto</a>
-
-<table border="1">
-    <tr>
-        <th>name</th>
-        <th>type</th>
-        <th>required</th>
-        <th>description</th>
-        <th>example</th>
-    </tr>
-    
-        <tr>
-            <td>action</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-</table>
-
-## <a name="/definitions/ActivitySpecParameterDto">ActivitySpecParameterDto</a>
-
-<table border="1">
-    <tr>
-        <th>name</th>
-        <th>type</th>
-        <th>required</th>
-        <th>description</th>
-        <th>example</th>
-    </tr>
-    
-        <tr>
-            <td>name</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>type</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>value</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-</table>
-
-## <a name="/definitions/ActivitySpecRequest">ActivitySpecRequest</a>
-
-<table border="1">
-    <tr>
-        <th>name</th>
-        <th>type</th>
-        <th>required</th>
-        <th>description</th>
-        <th>example</th>
-    </tr>
-    
-        <tr>
-            <td>name</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>description</td>
-            <td>
-                
-                    
-                    string
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>categoryList</td>
-            <td>
-                
-                
-                array[string]
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>inputParameters</td>
-            <td>
-                
-                
-                    array[<a href="#/definitions/ActivitySpecParameterDto">ActivitySpecParameterDto</a>]
-                
-                
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-        <tr>
-            <td>outputParameters</td>
-            <td>
-                
-                
-                    array[<a href="#/definitions/ActivitySpecParameterDto">ActivitySpecParameterDto</a>]
-                
-                
-                
-            </td>
-            <td>optional</td>
-            <td>-</td>
-            <td></td>
-        </tr>
-    
-</table>
-
-</xmp>
-
-<script src="http://strapdownjs.com/v/0.2/strapdown.js"></script>
-</html>
\ No newline at end of file
diff --git a/services/activity-spec/swagger-ui/api-docs/api.json b/services/activity-spec/swagger-ui/api-docs/api.json
deleted file mode 100644 (file)
index 7f99775..0000000
+++ /dev/null
@@ -1,239 +0,0 @@
-{
-  "swagger" : "2.0",
-  "info" : {
-    "description" : "Rest API Documentation",
-    "version" : "v1.0, build #${buildNumber}",
-    "title" : "Rest API",
-    "termsOfService" : "http://www.github.com/kongchen/swagger-maven-plugin"
-  },
-  "basePath" : "/activityspec-api",
-  "tags" : [ {
-    "name" : "Activity Specs"
-  } ],
-  "schemes" : [ "http" ],
-  "paths" : {
-    "/v1.0/activity-spec" : {
-      "get" : {
-        "tags" : [ "Activity Specs" ],
-        "summary" : "Get list of activity specs ",
-        "description" : "",
-        "operationId" : "list",
-        "consumes" : [ "application/json" ],
-        "produces" : [ "application/json" ],
-        "parameters" : [ {
-          "name" : "status",
-          "in" : "query",
-          "description" : "Currently supported values: 'Certified' - only activity specs with Certified status",
-          "required" : false,
-          "type" : "string"
-        }, {
-          "name" : "USER_ID",
-          "in" : "header",
-          "required" : false,
-          "type" : "string",
-          "default" : ""
-        } ],
-        "responses" : {
-          "default" : {
-            "description" : "successful operation"
-          }
-        }
-      },
-      "post" : {
-        "tags" : [ "Activity Specs" ],
-        "summary" : "Create Activity Spec",
-        "description" : "",
-        "operationId" : "createActivitySpec",
-        "consumes" : [ "application/json" ],
-        "produces" : [ "application/json" ],
-        "parameters" : [ {
-          "in" : "body",
-          "name" : "body",
-          "required" : false,
-          "schema" : {
-            "$ref" : "#/definitions/ActivitySpecRequest"
-          }
-        }, {
-          "name" : "USER_ID",
-          "in" : "header",
-          "required" : false,
-          "type" : "string",
-          "default" : ""
-        } ],
-        "responses" : {
-          "default" : {
-            "description" : "successful operation"
-          }
-        }
-      }
-    },
-    "/v1.0/activity-spec/{id}/versions/{versionId}" : {
-      "get" : {
-        "tags" : [ "Activity Specs" ],
-        "summary" : "Get Activity Spec",
-        "description" : "",
-        "operationId" : "getActivitySpec",
-        "consumes" : [ "application/json" ],
-        "produces" : [ "application/json" ],
-        "parameters" : [ {
-          "name" : "id",
-          "in" : "path",
-          "description" : "Activity Spec Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "versionId",
-          "in" : "path",
-          "description" : "Version Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "USER_ID",
-          "in" : "header",
-          "required" : false,
-          "type" : "string",
-          "default" : ""
-        } ],
-        "responses" : {
-          "default" : {
-            "description" : "successful operation"
-          }
-        }
-      },
-      "put" : {
-        "tags" : [ "Activity Specs" ],
-        "summary" : "Update Activity Spec",
-        "description" : "",
-        "operationId" : "updateActivitySpec",
-        "consumes" : [ "application/json" ],
-        "produces" : [ "application/json" ],
-        "parameters" : [ {
-          "in" : "body",
-          "name" : "body",
-          "required" : false,
-          "schema" : {
-            "$ref" : "#/definitions/ActivitySpecRequest"
-          }
-        }, {
-          "name" : "id",
-          "in" : "path",
-          "description" : "Activity Spec Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "versionId",
-          "in" : "path",
-          "description" : "Version Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "USER_ID",
-          "in" : "header",
-          "required" : false,
-          "type" : "string",
-          "default" : ""
-        } ],
-        "responses" : {
-          "default" : {
-            "description" : "successful operation"
-          }
-        }
-      }
-    },
-    "/v1.0/activity-spec/{id}/versions/{versionId}/actions" : {
-      "put" : {
-        "tags" : [ "Activity Specs" ],
-        "summary" : "Actions on a activity spec",
-        "description" : "Performs one of the following actions on a activity spec: |Submit: Finalize its active version.|Deprecate: Deprecate activity spec.|",
-        "operationId" : "actOnActivitySpec",
-        "consumes" : [ "application/json" ],
-        "produces" : [ "application/json" ],
-        "parameters" : [ {
-          "in" : "body",
-          "name" : "body",
-          "required" : false,
-          "schema" : {
-            "$ref" : "#/definitions/ActivitySpecActionRequestDto"
-          }
-        }, {
-          "name" : "id",
-          "in" : "path",
-          "description" : "Activity Spec Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "versionId",
-          "in" : "path",
-          "description" : "Version Id",
-          "required" : true,
-          "type" : "string"
-        }, {
-          "name" : "USER_ID",
-          "in" : "header",
-          "required" : false,
-          "type" : "string",
-          "default" : ""
-        } ],
-        "responses" : {
-          "default" : {
-            "description" : "successful operation"
-          }
-        }
-      }
-    }
-  },
-  "definitions" : {
-    "ActivitySpecActionRequestDto" : {
-      "type" : "object",
-      "properties" : {
-        "action" : {
-          "type" : "string",
-          "enum" : [ "Certify", "Deprecate", "Delete" ]
-        }
-      }
-    },
-    "ActivitySpecParameterDto" : {
-      "type" : "object",
-      "properties" : {
-        "name" : {
-          "type" : "string"
-        },
-        "type" : {
-          "type" : "string"
-        },
-        "value" : {
-          "type" : "string"
-        }
-      }
-    },
-    "ActivitySpecRequest" : {
-      "type" : "object",
-      "properties" : {
-        "name" : {
-          "type" : "string"
-        },
-        "description" : {
-          "type" : "string"
-        },
-        "categoryList" : {
-          "type" : "array",
-          "items" : {
-            "type" : "string"
-          }
-        },
-        "inputParameters" : {
-          "type" : "array",
-          "items" : {
-            "$ref" : "#/definitions/ActivitySpecParameterDto"
-          }
-        },
-        "outputParameters" : {
-          "type" : "array",
-          "items" : {
-            "$ref" : "#/definitions/ActivitySpecParameterDto"
-          }
-        }
-      }
-    }
-  }
-}
\ No newline at end of file