Skip to main content
PATCH
https://api.bunship.com
/
api
/
v1
/
organizations
/
{orgId}
Update Organization
curl --request PATCH \
  --url https://api.bunship.com/api/v1/organizations/{orgId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": {},
  "logoUrl": {},
  "settings": {
    "settings.branding": {},
    "settings.features": {},
    "settings.billing": {}
  }
}
'
{
  "id": "org_cld2abc123def456",
  "name": "Acme Corporation",
  "slug": "acme-corp",
  "description": "Building the future of widgets since 2024",
  "logoUrl": "https://cdn.bunship.com/logos/acme-v2.png",
  "settings": {
    "branding": {
      "primaryColor": "#4338CA",
      "accentColor": "#818CF8"
    },
    "features": {
      "webhooks": true,
      "apiAccess": true
    }
  },
  "createdBy": "usr_cld2abc123def456",
  "createdAt": "2024-01-15T10:00:00Z",
  "updatedAt": "2024-01-21T09:00:00Z"
}
Updates an organization’s details. Only included fields are modified. Settings are merged with existing values. Requires the org:update permission (available to owners and admins).

Auth

Requires a valid Bearer token with org:update permission.

Path Parameters

orgId
string
required
Organization identifier.

Request Body

All fields are optional. Include only the fields you want to change.
name
string
Updated organization name. Between 1 and 100 characters.
description
string | null
Updated description. Maximum 500 characters. Set to null to remove.
logoUrl
string | null
Updated logo URL. Must be a valid URI. Set to null to remove.
settings
object
Partial settings object. Merged with existing settings.

Response

Returns the full updated organization object. See Get Organization for the complete response schema.
{
  "id": "org_cld2abc123def456",
  "name": "Acme Corporation",
  "slug": "acme-corp",
  "description": "Building the future of widgets since 2024",
  "logoUrl": "https://cdn.bunship.com/logos/acme-v2.png",
  "settings": {
    "branding": {
      "primaryColor": "#4338CA",
      "accentColor": "#818CF8"
    },
    "features": {
      "webhooks": true,
      "apiAccess": true
    }
  },
  "createdBy": "usr_cld2abc123def456",
  "createdAt": "2024-01-15T10:00:00Z",
  "updatedAt": "2024-01-21T09:00:00Z"
}

Errors

StatusCodeDescription
400VALIDATION_ERRORInvalid field value
401AUTHENTICATION_ERRORMissing or invalid Bearer token
403AUTHORIZATION_ERRORInsufficient permissions (org:update required)
404NOT_FOUNDOrganization not found

Example

curl -X PATCH https://api.bunship.com/api/v1/organizations/org_cld2abc123def456 \
  -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIs..." \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Acme Corporation",
    "settings": {
      "branding": {
        "primaryColor": "#4338CA"
      }
    }
  }'