webapicookbook / registry-docs

open-disco registry standard documentation
MIT License
2 stars 0 forks source link

Purpose of the bind function #2

Open zdne opened 5 years ago

zdne commented 5 years ago

Reading about the bind token I suspect the main purpose is some sort of authorization of the requestor to make the calls for the API, is that correct? Does the registry need to keep the track of the binds or is it stateless from this perspective?

mamund commented 5 years ago

the BIND is there to allow for an additional action by the CLIENT to commit an action like "i intende to use this API".

this BIND action is also an oppty for the registry to reply with a starter document that points to a live service, returns an API-KEY or some other token value, engage in additional exchange (like bidding for price, etc.)

this BIND moment also offers the oppty for establish a trust relationship for dealing with repeating healthchecks (e.g. the CLIENT can subscribe to health info from the target service, etc.)

i wanted to make there there was at least one more action available to allow for future growth. it might not be the best name, tho.

zdne commented 5 years ago

All clear, just that one or two last questions on the bind() topic:

  1. Is the registry expected to keep the track of who has bound to what?
  2. Related, should there be "unbind" functionality to declare a client is done with a service?