pondersource / prejournal

An experimental bookkeeping tool that sits between source documents and journals
https://prejournal.org
MIT License
2 stars 2 forks source link

update-entry via API not working #165

Closed gsvarovsky closed 2 years ago

gsvarovsky commented 2 years ago
POST https://time.pondersource.com/v1/update-entry
[
  "2022-09-08T06:30:00.000Z",
  "Federated Timesheets Virtual Organisation:test/work3",
  12,
  "Preparing Milestone 2 demo",
  487
]

This responds 200 but does not update the movement.

Strangely, if you include the command at the head of the array it does work, i.e.

POST https://time.pondersource.com/v1/update-entry
[
  "update-entry",
  "2022-09-08T06:30:00.000Z",
  "Federated Timesheets Virtual Organisation:test/work3",
  12,
  "Preparing Milestone 2 demo",
  487
]
ishifoev commented 2 years ago

@gsvarovsky There are not optional. You can see here, that you will pass all arguments. On the first one you pass only 5 arguments.

https://github.com/m-ld/timeld/blob/main/doc/api.md

gsvarovsky commented 2 years ago

I am missing the worker. Thanks 👍

It would be good if the API provided a 4xx response to bad requests.