Description
When using the /new API endpoint to create a comment for a new thread (i.e., the first comment for a given uri, the title field is required in the request body. However, this requirement is not documented in the API docs. If the title is missing, the API returns a 404 error with the message <p>URI does not exist %s </p> , which is confusing and misleading.
Minimal reproducible steps:
- Start the isso server
- Run the following command (without the title field):
curl --location 'http://127.0.0.1:8080/new?uri=test' \
--header 'Content-Type: application/json' \
--data '{
"text": "hello isso"
}'
3.The response is a 404 with <p>URI does not exist %s</p>
Expected behavior:
- The documentation should clearly state that title is required when creating the first comment for a new thread, or
- The API should return a more helpful error message if title is missing
Actual behavior:
- Returns 404 with an unclear error message
Please consider improving the documentation and/or the API error handling. Thank you!