Verify unit ownership
GET/units/verify
URL | Description |
---|---|
https://ceems-demo.myaddr.tools:7443/api/v1 | Demo |
This endpoint will check if the current user is the owner of the
queried UUIDs. The current user is always identified by the header X-Grafana-User
in
the request.
A response of 200 means that the current user is the owner of the queried UUIDs. Any other response code should be treated as the current user not being the owner of the queried units.
The ownership check passes if any of the following conditions are true
:
- If the current user is the direct owner of the compute unit.
- If the current user belongs to the same account/project/namespace as the compute unit. This means the users belonging to the same project can access each others compute units.
- If the current user has admin role
The above checks must pass for all the queried units. If the check does not pass for at least one queried unit, a response 403 will be returned.
Any 500 response codes should be treated as failed check as well.
Request
Responses
- 200
- 401
- 403
- 500
OK
Unauthorized
Forbidden
Internal Server Error