Update Specific Sub Organization

Update Specific Sub Organization

This endpoint updates the details of a specific sub-organization within an enterprise. You can modify the sub-organization's name, address, contact details, branding photo, and type. The sub-organization ID is required to identify which entity to update.


HTTP Method and URL

Method: PUT
URL: {{host}}/api/v2/organizations/sub/:uuid?user_type=ENTERPRISE_API


Authentication Requirements

This endpoint requires authentication via a bearer token. The token should be provided in the Authorization header.

HeaderValueDescription
AuthorizationBearerRequired. API access token.

Path and Query Parameters

Path Parameter:

  • uuid (string, required): The unique identifier of the sub-organization to update.

Query Parameter:

  • user_type (string, required): Must be set to ENTERPRISE_API.

Request Body

The request body must be sent as multipart/form-data and can include the following fields:

FieldTypeRequiredDescription
namestringYesThe new name of the sub-organization.
emailstringYesThe email address for the sub-organization.
addressstringYesThe address or contact details of the sub-organization.
photofileNoBranding image (shown on emails and signing page).
sub_organization_type_namestringYesThe type of sub-organization (e.g., Client).

Example Request

PUT {{host}}/api/v2/organizations/sub/79b7c96e-28cd-4b7e-83fb-ebaf06bf241f?user_type=ENTERPRISE_API
Headers:
  Authorization: Bearer <user-token>
Body (form-data):
  name: test2
  email: [email protected]
  address: address2
  photo: (file) doclogo.png
  sub_organization_type_name: Client

Example Successful Response

{
  "success": true,
  "message": "Sub-organization updated successfully.",
  "data": {
    "uuid": "79b7c96e-28cd-4b7e-83fb-ebaf06bf241f",
    "name": "test2",
    "email": "[email protected]",
    "address": "address2",
    "photo_url": "https://.../doclogo.png",
    "sub_organization_type_name": "Client"
  }
}

Error Responses

  • 400 Bad Request: Invalid input or missing required fields.

  • 401 Unauthorized: Missing or invalid authentication token.

  • 404 Not Found: Sub-organization with the specified UUID does not exist.

  • 500 Internal Server Error: Unexpected server error.


Usage Notes

  • Ensure the user_type query parameter is always set to ENTERPRISE_API.

  • The photo field is optional; omit it if you do not wish to update the branding image.

  • Only users with appropriate permissions can update sub-organization details.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required
Query Params
string
Body Params
string
string
string
file
string
Response

Language
Credentials
Bearer
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here!