{
  "algorithm": {
    "parameters": [
      {
        "name": "planId",
        "type": "string"
      },
      {
        "name": "goal",
        "type": "MainGoalCreation"
      }
    ],
    "statements": [],
    "typeReturn": "MainGoal",
    "variables": []
  },
  "routing": {
    "method": "POST",
    "parameters": [
      {
        "bind": "planId",
        "in": "Path",
        "name": "planId",
        "remarks": "planId"
      },
      {
        "bind": "goal",
        "in": "Body",
        "name": "goal",
        "remarks": "goal"
      }
    ],
    "path": "/designer/plans/{planId}/main-goals",
    "remarks": "Creates a goal of the plan",
    "responses": [
      {
        "httpStatus": "200",
        "remarks": "Ok"
      },
      {
        "errorName": "Unauthorized",
        "httpStatus": "401",
        "remarks": "Unauthorized"
      },
      {
        "errorName": "Forbidden",
        "httpStatus": "403",
        "remarks": "Forbidden"
      },
      {
        "errorName": "NotFound",
        "httpStatus": "404",
        "remarks": "Not found"
      },
      {
        "errorName": "NotAcceptable",
        "httpStatus": "406",
        "remarks": "Not Acceptable"
      },
      {
        "errorName": "InternalServerError",
        "httpStatus": "500",
        "remarks": "500 message"
      }
    ]
  }
}