* wip * wip * wip * Update index.ts * Update gen-openapi-spec.ts * Update api.ja-JP.md * Fix * Improve doc * Update gen-openapi-spec.ts * Update redoc.html * Improve doc * Update gen-openapi-spec.ts * Improve doc * Update CHANGELOG.md
23 lines
480 B
TypeScript
23 lines
480 B
TypeScript
import UserList, { pack } from '../../../../../models/user-list';
|
|
import define from '../../../define';
|
|
|
|
export const meta = {
|
|
desc: {
|
|
'ja-JP': '自分の作成したユーザーリスト一覧を取得します。'
|
|
},
|
|
|
|
tags: ['lists', 'account'],
|
|
|
|
requireCredential: true,
|
|
|
|
kind: 'account-read'
|
|
};
|
|
|
|
export default define(meta, async (ps, me) => {
|
|
const userLists = await UserList.find({
|
|
userId: me._id,
|
|
});
|
|
|
|
return await Promise.all(userLists.map(x => pack(x)));
|
|
});
|