Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimum requirements for a TDD #266

Closed
egekorkan opened this issue Jan 25, 2022 · 2 comments · Fixed by #267
Closed

Minimum requirements for a TDD #266

egekorkan opened this issue Jan 25, 2022 · 2 comments · Fixed by #267

Comments

@egekorkan
Copy link

There are some issues about the minimum requirements on search but I could not find one about requirements in general for any TDD. If someone gives me the URL of a TDD, am I guaranteed to get an answer to an HTTP GET request to /things? How about the other operations/methods and endpoints etc.? I have mentioned a bit of this at #178.

It would be nice to have tm:required on mandatory affordances of the TDD TM if this is indeed the case. Also, from the text it seems that I do not have to implement retrieval but I have to implement update and registration. To be clear, here is what retrieval has as assertion:

A TD MUST be retrieved from the directory using an HTTP GET request at /things/{id} endpoint, where id is the unique TD identifier. A successful response MUST have 200 (OK) status, contain application/td+json Content-Type header, and the requested TD in body.

which does not mean that retrieval is mandatory but how it should be implemented is assertive. Whereas the creation says>

The API MUST allow registration of a TD object passed as request body.

which is also not very clear but I can understand it as creation being mandatory.

There is also the following assertion:

The Registration API MUST provide create, retrieve, update, delete, and listing (CRUDL) interfaces.

However, it is not watertight that these interfaces are for TDs (a bit of a weird interpretation but possible).

In any case, is it allowed to have a TDD that is only for retrieval and another one that is only for creation and updates. Currently, the only way to have such levels is having different security levels.

@benfrancis
Copy link
Member

benfrancis commented Jan 25, 2022

See also: #208

I suggest that only the listing and retrieval features should be mandatory, to allow for read-only directories.

farshidtz added a commit to farshidtz/w3c-wot-discovery that referenced this issue Jan 29, 2022
farshidtz added a commit to farshidtz/w3c-wot-discovery that referenced this issue Jan 29, 2022
@farshidtz
Copy link
Member

@egekorkan
Thanks for pointing out these issues.

It would be nice to have tm:required on mandatory affordances of the TDD TM if this is indeed the case.

This is work in progress; see #86. We have a note here to remind us that we need to specify required affordances in the TM.

I've created a PR to address your other concerns.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants