mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-21 09:52:06 +03:00
8fd4b3f09f
no issue - Added read and browse admin API for members
36 lines
729 B
JavaScript
36 lines
729 B
JavaScript
const memberUserObject = require('../../services/members').api.memberUserObject;
|
|
|
|
const members = {
|
|
docName: 'members',
|
|
browse: {
|
|
options: [
|
|
'limit',
|
|
'fields',
|
|
'filter',
|
|
'order',
|
|
'debug',
|
|
'page'
|
|
],
|
|
permissions: true,
|
|
validation: {},
|
|
query(frame) {
|
|
return memberUserObject.list(frame.options);
|
|
}
|
|
},
|
|
|
|
read: {
|
|
headers: {},
|
|
data: [
|
|
'id',
|
|
'email'
|
|
],
|
|
validation: {},
|
|
permissions: true,
|
|
query(frame) {
|
|
return memberUserObject.get(frame.data, frame.options);
|
|
}
|
|
}
|
|
};
|
|
|
|
module.exports = members;
|