organizations

Ensure My Organization

Ensure user has an organization. Creates one if none exists.

This endpoint is called by the frontend after login for self-serve users. If the user already has an organization, returns it. If Authentik stamped AWS Marketplace attributes on the user at enrollment, creates the Marketplace tenant. Otherwise, creates a new credit organization with the user as OWNER.

Requires authentication.

post/organizations/me/ensure

Request

  • Base URL: https://backend.pruna.ai (the document declares no server; this is the origin it was published from)
  • URL: https://backend.pruna.ai/organizations/me/ensure
  • Auth: HTTP bearer

Response

Successful Response

organizationIdstring required

Organization ID

namestring required

Organization name

status'ACTIVE' | 'AWS_PENDING_ACTIVATION' | 'SUSPENDED' | 'DELETED' required

Status of a tenant account.

billingType'usage' | 'credit' | 'aws_marketplace_usage' required

Billing mode for a tenant.

createdAtstring date-time required

Organization creation timestamp

memberCountinteger nullable

Number of members in the organization

currentUserRolestring nullable

Role of the requesting user within the organization

termsOfUseAcceptedboolean

Whether the user has accepted the terms of use

dpaAcceptedboolean

Whether the user has accepted the Data Processing Agreement

isNewSelfServeboolean

True when org was just auto-created for self-serve user (show welcome modal)

Changes

No recorded changes to this operation across all 1 revision of this API.