It would be convenient to be able to do GET /identifiers/{prefix} instead of GET /identifiers/{name}. One use case is when you are reading a notification or exchange message. In that case, you only have the prefix of the intended recipient AID. So currently you have to first need an API call to get all identifiers, then pick the identifier you need to work with.
exchange = { ... a: { i: "prefix-1" } }
identifiers = listIdentifiers() // API Request to list all identifiers
identifier = identifiers.find(id => id.prefix === exchange.a.i) // Pick the identifier you needed
If we had a way to get identifier by prefix, we could do
Currently, you can only get an identifier by their name through the API. This is convenient for manually constructing URLs or when using the kli. When code is constructing the URL, I think using the prefix is more useful.
It would be convenient to be able to do
GET /identifiers/{prefix}
instead ofGET /identifiers/{name}
. One use case is when you are reading a notification or exchange message. In that case, you only have the prefix of the intended recipient AID. So currently you have to first need an API call to get all identifiers, then pick the identifier you need to work with.If we had a way to get identifier by prefix, we could do
Notes
Currently, you can only get an identifier by their name through the API. This is convenient for manually constructing URLs or when using the
kli
. When code is constructing the URL, I think using the prefix is more useful.