-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathroutes.py
More file actions
26 lines (24 loc) · 911 Bytes
/
routes.py
File metadata and controls
26 lines (24 loc) · 911 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
"""
Routes associated with the jupyterhub addon
"""
from framework.routing import Rule, json_renderer
from . import SHORT_NAME
from . import views
api_routes = {
'rules': [
Rule([
'/project/<pid>/{}/settings'.format(SHORT_NAME),
'/project/<pid>/node/<nid>/{}/settings'.format(SHORT_NAME),
], 'get', views.myskelton_get_config, json_renderer),
Rule([
'/project/<pid>/{}/settings'.format(SHORT_NAME),
'/project/<pid>/node/<nid>/{}/settings'.format(SHORT_NAME),
], 'put', views.myskelton_set_config, json_renderer),
# admin notes取得viewのルーティング設定
Rule([
'/project/<pid>/{}/adminnotes'.format(SHORT_NAME),
'/project/<pid>/node/<nid>/{}/adminnotes'.format(SHORT_NAME),
], 'get', views.myskelton_get_admin_notes, json_renderer),
],
'prefix': '/api/v1',
}