-
Notifications
You must be signed in to change notification settings - Fork 0
/
cold_ds_readwrite.yaml
48 lines (46 loc) · 1.49 KB
/
cold_ds_readwrite.yaml
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# COLD Private READ/WRITE API is a read only JSON API provided by datasetd >= 2.2.13
host: localhost:8486
# COLD manages a dataset collection for each object collection. One for people, one
# for groups and eventually one for funders.
collections:
- dataset: people.ds
# These are the queries required to support the read-only implementation of cold
# People Queries need to be remapped by the Newt router.
query:
# clpid should be mapped to /cold/admin/people by Newt Router
clpid: |
select src->>'cl_people_id' as clpid
from people
order by src->>'cl_people_id' ASC
# people returns a people object for a given clpid
# it is mapped to /cold/admin/people/{clpid} by Newt Router
people: |
select src
from people
where src->>'cl_people_id' like ?
# Permissions for people.ds
keys: true
create: true
read: true
update: true
delete: true
list: true
- dataset: groups.ds
# clgid should be mapped to /cold/admin/groups by Newt Router
clgid: |
select src->>'cl_group_id' as clgid
from people
order by src->>'cl_group_id' ASC
# group returns a group object for a given clgid
# it is mapped to /cold/admin/group/{clgid} by Newt Router
group: |
select src
from people
where src->>'cl_group_id' like ?
# Permissions for groups.ds
keys: true
create: true
read: true
update: true
delete: true
list: true