View .md

Subusers endpoints (Client API: VDS)

3 FeatherPanel Client API: VDS endpoints from user/vds/subusers.php: methods, paths, auth, permissions, rate limits, parameters and responses.

Last synced from FeatherPanel 15b94e9 on .

On this page

Defined in backend/app/routes/user/vds/subusers.php. Authentication used here: VDS access. Read Authentication for how to send credentials and Rate limits and errors for the response envelope.

Paths, methods, permissions and rate limits come from the route file. Summaries, parameters and response codes come from the OpenAPI annotations on the controllers; endpoints without annotations show only what the route file declares.

Endpoints

GET/api/user/vm-instances/{id}/subusers

Auth: VDS accessDefault rate limit: 30 / minuteRoute name: user-vm-instance-subusers-listController: VmUserSubuserController::listSubusersroute source

List subusers List subusers for this VM instance. Only the VM owner can manage subusers.

ParameterInTypeRequiredDescription
idpathintegeryes
Response data fieldTypeDescription
subusersobject[]
curl -X GET "$PANEL_URL/api/user/vm-instances/$ID/subusers" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json"

Responses: 200 Subusers listed · 401 Unauthorized · 403 Only the VM owner can manage subusers · 404 VM instance not found

POST/api/user/vm-instances/{id}/subusers

Auth: VDS accessDefault rate limit: 10 / minuteRoute name: user-vm-instance-subusers-createController: VmUserSubuserController::createSubuserroute source

Add subuser Add a subuser to this VM instance with given permissions. Only the VM owner can add subusers.

ParameterInTypeRequiredDescription
idpathintegeryes
Body fieldTypeRequiredDescription
emailstringyesTarget user email
permissionsstring[]yese.g. power, console
Response data fieldTypeDescription
subuserobject
curl -X POST "$PANEL_URL/api/user/vm-instances/$ID/subusers" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"email":"","permissions":[]}'

Plugin events: featherpanel:vds:subuser:create

Responses: 201 Subuser added · 400 email and permissions required · 401 Unauthorized · 403 Only the VM owner can add subusers · 404 VM instance not found · 500 Create failed

DELETE/api/user/vm-instances/{id}/subusers/{subuserId}

Auth: VDS accessDefault rate limit: 10 / minuteRoute name: user-vm-instance-subusers-deleteController: VmUserSubuserController::deleteSubuserroute source

Remove subuser Remove a subuser from this VM instance. Only the VM owner can remove subusers.

ParameterInTypeRequiredDescription
idpathintegeryes
subuserIdpathintegeryes
curl -X DELETE "$PANEL_URL/api/user/vm-instances/$ID/subusers/$SUBUSER_ID" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json"

Plugin events: featherpanel:vds:subuser:delete

Responses: 200 Subuser removed · 401 Unauthorized · 403 Only the VM owner can remove subusers · 404 VM instance or subuser not found