wekan / wekan-snap

Newest Wekan Snap docs wiki. Repo has old Snap code, newest Snap code at https://github.com/wekan/wekan , where is also more of newest WeKan docs at wiki.
https://github.com/wekan/wekan-snap/wiki
MIT License
71 stars 11 forks source link

REST API cannot create new checklist items #142

Open frantzstaboeeg opened 3 years ago

frantzstaboeeg commented 3 years ago

I managed to use the REST API for a lot of different queries now, but there are some objects i cannot create. How can i create new checklist items using the REST API? It seems like I can only edit delete and get such items.

I tried with

POST /api/boards/{board}/cards/{card}/checklists/{checklist}/items with title in the data field but the response from the server can not be decoded to json and new items are not created, see below. I guess it has not yet been implemented?

xet7 commented 3 years ago

@frantzstaboeeg

It seems you are correct.

You can create checklists: https://github.com/wekan/wekan/blob/master/models/checklists.js#L275

But not checklist items, because there is no code to it: https://github.com/wekan/wekan/blob/master/models/checklistItems.js#L254

Please send pull request for adding checklist items. Info about creating pull request is here: https://github.com/wekan/wekan/wiki/Emoji#how-you-could-add-another-plugin

Thanks!