camicroscope / Caracal

Conslidated Backend, Auth, and Security Services for caMicroscope
GNU General Public License v3.0
15 stars 94 forks source link

add access specifier to routes, update validator #118

Closed YashKumarVerma closed 3 years ago

YashKumarVerma commented 3 years ago

Summary

Flow

https://i.imgur.com/OHwjDDE.png

Note : the following json document of resource:operation mapping is for debugging and summary purposes and is generated via /service/routes/entityAndOperations.js

{
  "middleware": [
    "loader.login",
    "loader.slide.delete",
    "loader.proxyHandler",
    "googleAuth",
    "img.iip.raw",
    "data"
  ],
  "slide": ["read", "create", "delete", "update"],
  "request": ["read", "create", "delete"],
  "mark": [
    "read",
    "create",
    "delete",
    "update",
    "types",
    "multi",
    "spatial",
    "findMarkTypes"
  ],
  "presetLabel": ["create", "update", "delete"],
  "template": ["read", "create", "delete", "update"],
  "heatmap": ["read", "types", "create", "delete", "update"],
  "heatmapEdit": ["read", "create", "delete", "update"],
  "log": ["read", "create", "delete", "update"],
  "freeform": ["read", "create", "delete", "update"],
  "configuration": ["read", "create", "delete", "update"],
  "collection": ["read", "create", "update", "delete"],
  "user": ["read", "create", "delete", "update", "wcido"],
  "workbench": [
    "uploadDataset",
    "trainModel",
    "deleteUserData",
    "modelDownload"
  ]
}

This Pull Request

YashKumarVerma commented 3 years ago

@birm