API The delete deploy key removes the key, even if it is used by other projects
Created by: opichon
The delete deploy key API is invoked on a specific project. One would naturally assume that it would follow the same behavior as in the UI: if the key is used by other projects, the key is disabled for the project specified in the API call; if the key i snot used by any other project, then the key is removed altogether.
However it appears that the API call removes the key completely, even if used by other projects.
Is this the intended behavior or is it a bug?
If it is, I'd like to suggest that the API syntax should not include a project id, and that there should be a specific call to remove a key from all projects (e.g. DELETE /keys/:key_id)