Skip to content

API reference

Organizations

Multi-tenant organization management. Each organization is an isolated tenant with its own entities, templates, and configuration.

Key points

  • Organizations are the top-level tenant boundary — every record lives within exactly one
  • Subdomain and code are unique identifiers; once set they’re hard to change
  • Settings and feature_flags are loosely-typed JSON objects for org-specific behavior
  • Deactivate is soft (status flips to inactive); existing data is preserved

About organizations

Organizations are FlexiScheduler’s tenant boundary. Every entity, event, template, and configuration belongs to exactly one organization. The x-organization-id header on non-Organizations endpoints picks which one the request operates against — see Authentication.

The Organizations endpoints themselves are platform-level — they manage tenants. Most organizations are created during onboarding and rarely modified after. These endpoints exist for platform operators, internal tools, and self-service signup flows.

Field naming note

Organizations endpoints use snake_case

Most FlexiScheduler endpoints use camelCase (e.g. primaryEntityId, startTime). The Organizations endpoints are the exception — they use snake_case (e.g. subscription_tier, feature_flags, default_timezone). This is a historical inconsistency we plan to resolve in the next major version. For now, use the field names exactly as documented per endpoint.

Create organization

POST/api/v1/organizations

Provision a new organization. Subdomain and code must be globally unique.

Request body

Required: name, subdomain. Code, settings, feature flags, and contact information are all optional but typically populated during onboarding.

{
  "name": "SeniorLife PACE - Boston",
  "subdomain": "seniorlife-boston",
  "code": "PACE-BOS",
  "primary_email": "admin@seniorlife-boston.com",
  "primary_phone": "+1-617-555-0100",
  "address_street1": "100 Summer Street",
  "address_city": "Boston",
  "address_state": "MA",
  "address_zip": "02110",
  "address_country": "USA",
  "default_timezone": "America/New_York",
  "subscription_tier": "enterprise",
  "subscription_expires_at": "2027-12-31T23:59:59Z",
  "max_users": 500,
  "max_entities": 50000,
  "settings": {
    "allow_overtime": true,
    "max_daily_hours": 10
  },
  "feature_flags": {
    "route_optimization": true,
    "waitlist": true
  }
}

Responses

201Organization created
{
  "id": "org_a8f4c2d1-...",
  "name": "SeniorLife PACE - Boston",
  "subdomain": "seniorlife-boston",
  "code": "PACE-BOS",
  "status": "active",
  "subscription_tier": "enterprise",
  "default_timezone": "America/New_York",
  "settings": { ... },
  "feature_flags": { ... },
  "createdAt": "2026-04-26T15:30:00.000Z",
  "updatedAt": "2026-04-26T15:30:00.000Z"
}
400Validation error — missing or invalid fields
409Subdomain or code already in use

List organizations

GET/api/v1/organizations

Paginated list of organizations. Platform-operator scope; returns all organizations the caller can see.

Query parameters

  • statusenum

    Filter by status (active, inactive, suspended)

  • searchstring

    Free-text search across name and subdomain

  • subscription_tierstring

    Filter by tier

  • limitinteger

    Default 20, max 100

  • offsetinteger

    Default 0

  • orderBystring

    name, createdAt, or updatedAt

  • orderDirectionenum

    asc or desc

Responses

200Paginated organization list

Get organization

GET/api/v1/organizations/{organizationId}

Retrieve a single organization by ID.

Path parameters

  • organizationIdUUIDrequired

    Organization ID

Responses

200Organization details
{
  "id": "org_a8f4c2d1-...",
  "name": "SeniorLife PACE - Boston",
  "subdomain": "seniorlife-boston",
  "code": "PACE-BOS",
  "status": "active",
  "subscription_tier": "enterprise",
  "default_timezone": "America/New_York",
  "settings": { ... },
  "feature_flags": { ... },
  "createdAt": "2026-04-26T15:30:00.000Z",
  "updatedAt": "2026-04-26T15:30:00.000Z"
}
404Organization not found

Update organization

PUT/api/v1/organizations/{organizationId}

Update organization configuration. Only fields present in the body are changed.

Path parameters

  • organizationIdUUIDrequired

    Organization to update

Request body

Partial update. Subdomain changes are allowed but require uniqueness — collisions return 409.

{
  "name": "SeniorLife PACE - Greater Boston",
  "settings": {
    "allow_overtime": false,
    "max_daily_hours": 8
  },
  "max_users": 1000
}

Responses

200Updated organization
{
  "id": "org_a8f4c2d1-...",
  "name": "SeniorLife PACE - Boston",
  "subdomain": "seniorlife-boston",
  "code": "PACE-BOS",
  "status": "active",
  "subscription_tier": "enterprise",
  "default_timezone": "America/New_York",
  "settings": { ... },
  "feature_flags": { ... },
  "createdAt": "2026-04-26T15:30:00.000Z",
  "updatedAt": "2026-04-26T15:30:00.000Z"
}
400Validation error
404Organization not found
409Subdomain or code already in use by another organization

Deactivate organization

DELETE/api/v1/organizations/{organizationId}

Soft-delete the organization. Status moves to inactive; data is preserved.

Path parameters

  • organizationIdUUIDrequired

    Organization to deactivate

Responses

204Deactivated; no response body
404Organization not found

Deactivate stops new activity, doesn’t delete data

After deactivation, the organization can no longer be used for new bookings or data writes, but existing entities, events, and audit logs are preserved indefinitely. Hard deletion is a platform-operator action handled out of band — contact support if you need data purged for GDPR or similar reasons.