Skip to content

Client portals

Client portals operations in the Hlix API.

See the OpenAPI document for schemas and operation IDs.

  • Protected operations require an API key in x-api-key or a browser session cookie; some actions require a verified user session
  • Tenant-scoped operations use X-Organization-Id; browser sessions can use their active workspace. Discovery and personal-workspace bootstrap do not require an active workspace
  • The base URL for your deployment, https://server.hlix.ai by default
Method Path Operation
GET /v1/api/client-portal/invitations List agency client invitations
POST /v1/api/client-portal/invitations Invite an email directly to the agency client portal
DELETE /v1/api/client-portal/invitations/{invitationId} Revoke an unaccepted client invitation
POST /v1/api/client-portal/invitations/{invitationId}/resend Send a pending client invitation again
GET /v1/api/client-portal/members List the agency’s portal clients
DELETE /v1/api/client-portal/members/{userId} Remove a client’s agency portal access
PATCH /v1/api/client-portal/members/{userId} Set a client’s New project ideas permission
DELETE /v1/api/client-portal/members/{userId}/accounts/{clientAccountId} Take one customer away from a client
PUT /v1/api/client-portal/members/{userId}/accounts/{clientAccountId} Give a client back one customer’s access
GET /v1/api/client-portal/members/{userId}/projects List a client’s current agency portal project access
DELETE /v1/api/client-portal/members/{userId}/projects/{projectId} Remove one explicit portal project grant
PUT /v1/api/client-portal/members/{userId}/projects/{projectId} Grant one project, with messaging and project insights
GET /v1/api/client-portal/settings Read default client permissions
PATCH /v1/api/client-portal/settings Update default client permissions
GET /v1/api/me/portals Discover your available agency client portals
POST /v1/api/me/workspace Initialize your personal Hlix workspace
POST /v1/api/portal-invitations/{token}/accept Accept an email-bound client portal invitation
POST /v1/api/portal/projects Create a planning project
GET /v1/api/portals/{agencySlug}/identity Read the published agency identity
POST /v1/api/portals/{agencySlug}/session Enter the agency portal using the signed-in verified email
GET /v1/api/portals/assets/{organizationId}/{file} Download an agency’s uploaded logo or icon

GET /v1/api/client-portal/invitations · operation ID listWorkspacePortalInvitations

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 WorkspacePortalInvitation[] Owner/admin only. No token hash; clientAccountId is set only for an invitation that also opens a customer’s invoices.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.

Invite an email directly to the agency client portal

Section titled “Invite an email directly to the agency client portal”

POST /v1/api/client-portal/invitations · operation ID inviteWorkspacePortalClient

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Request body — application/json, InviteWorkspacePortal (required)

Property Type Required Notes
canCreateProjects boolean | null no
clientAccountId string | null no
email string (email) yes max length 320
projectGrants object[] no

Responses

Status Body Description
201 WorkspacePortalInvitationCreated One pending invitation per address (per customer when clientAccountId is set): inviting again adds the projects to it. clientAccountId also seats the client on that customer, which opens its issued invoices; project grants never do. Omitted or null New project ideas takes the workspace default as it is now; a later change of the default never changes it. The returned link stays usable if email fails.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.
409 ApiError Publish the portal identity first, or a named project cannot be shared (the sample).

DELETE /v1/api/client-portal/invitations/{invitationId} · operation ID revokeWorkspacePortalInvitation

Parameters

Name In Required Type Description
invitationId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 MessageAck Revoked.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

POST /v1/api/client-portal/invitations/{invitationId}/resend · operation ID resendWorkspacePortalInvitation

Parameters

Name In Required Type Description
invitationId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 WorkspacePortalInvitationResent The email goes out again and the invitation is open for 7 more days from now. emailSent is false when delivery is unavailable; the portal link still works.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.
409 ApiError Publish the portal identity first.

GET /v1/api/client-portal/members · operation ID listWorkspacePortalClients

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 WorkspacePortalClient[] One row per client: creation permission (effective and override), the customers whose invoices they read, and every project they open with its messaging and project insights switches.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.

DELETE /v1/api/client-portal/members/{userId} · operation ID removeWorkspacePortalClient

Parameters

Name In Required Type Description
userId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 MessageAck Membership, every project grant and every billing seat removed; pending invitations revoked.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

Set a client’s New project ideas permission

Section titled “Set a client’s New project ideas permission”

PATCH /v1/api/client-portal/members/{userId} · operation ID updateWorkspacePortalClient

Parameters

Name In Required Type Description
userId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Request body — application/json, WorkspacePortalMember (required)

Property Type Required Notes
canCreateProjects boolean | null yes

Responses

Status Body Description
200 WorkspacePortalClientPermissions Null takes the workspace default as it is now; a later change of the default never changes it.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

DELETE /v1/api/client-portal/members/{userId}/accounts/{clientAccountId} · operation ID removeWorkspacePortalCustomerAccess

Parameters

Name In Required Type Description
userId path yes string
clientAccountId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 CustomerAccessRemoved The client’s billing seat on this customer and their grants on its projects are removed; other customers and projects stay. The body is what was removed, for undo.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

Give a client back one customer’s access

Section titled “Give a client back one customer’s access”

PUT /v1/api/client-portal/members/{userId}/accounts/{clientAccountId} · operation ID restoreWorkspacePortalCustomerAccess

Parameters

Name In Required Type Description
userId path yes string
clientAccountId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Request body — application/json, RestoreCustomerAccess (required)

Property Type Required Notes
grants object[] no
seat boolean yes

Responses

Status Body Description
200 CustomerAccessRestored Restores the billing seat and the grants, limited to this customer’s projects.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

List a client’s current agency portal project access

Section titled “List a client’s current agency portal project access”

GET /v1/api/client-portal/members/{userId}/projects · operation ID listWorkspacePortalProjectAccess

Parameters

Name In Required Type Description
userId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 PortalProjectGrant[] The client’s live project grants.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

DELETE /v1/api/client-portal/members/{userId}/projects/{projectId} · operation ID removeWorkspacePortalProjectAccess

Parameters

Name In Required Type Description
userId path yes string
projectId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 MessageAck The client no longer opens this project.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

Grant one project, with messaging and project insights

Section titled “Grant one project, with messaging and project insights”

PUT /v1/api/client-portal/members/{userId}/projects/{projectId} · operation ID setWorkspacePortalProjectAccess

Parameters

Name In Required Type Description
userId path yes string
projectId path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Request body — application/json, PortalProjectPermissions (required)

Property Type Required Notes
canAccessCanvas boolean no
canMessage boolean yes
showProjectInsights boolean no

Responses

Status Body Description
200 PortalProjectGrant Creates or replaces the grant; it is bound to the project’s current customer.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.
409 ApiError The project cannot be shared with a client: it is the sample.

GET /v1/api/client-portal/settings · operation ID getWorkspacePortalSettings

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 WorkspacePortalSettings Owner/admin only. The default pre-selects New project ideas for the next invitation; clients and invitations already out keep their own value.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.

PATCH /v1/api/client-portal/settings · operation ID updateWorkspacePortalSettings

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Request body — application/json, WorkspacePortalSettings (required)

Property Type Required Notes
defaultCanCreateProjects boolean yes

Responses

Status Body Description
200 WorkspacePortalSettings Updated. Clients and pending invitations keep the value they had: a new default applies only to invitations sent from now on.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.

Discover your available agency client portals

Section titled “Discover your available agency client portals”

GET /v1/api/me/portals · operation ID listMyClientPortals

Authentication — A signed-in user session is required. API keys cannot authenticate this operation. Browsers send the session cookie automatically; server clients preserve the complete issued Cookie header.

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.
X-Client-Portal header no string The agency Workspace ID for a signed-in client’s portal requests. A verified user session and portal membership are required; API keys cannot authenticate portal access. This header does not grant agency administration access.

Responses

Status Body Description
200 WorkspacePortal[] One dashboard per agency. Includes live published invitations bound to a verified email; GET does not accept invitations or change staff/personal workspace membership.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError Authenticated, but not a member of the named organization — or a client collaborator without the required access on this project.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.

POST /v1/api/me/workspace · operation ID initializePersonalWorkspace

Authentication — A signed-in user session is required. API keys cannot authenticate this operation. Browsers send the session cookie automatically; server clients preserve the complete issued Cookie header.

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 PersonalWorkspace Idempotent workspace creation; requires a browser user session.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError Authenticated, but not a member of the named organization — or a client collaborator without the required access on this project.
404 ApiError Entity is not available in this portal/workspace.

Accept an email-bound client portal invitation

Section titled “Accept an email-bound client portal invitation”

POST /v1/api/portal-invitations/{token}/accept · operation ID acceptClientPortalInvitation

Authentication — A signed-in user session is required. API keys cannot authenticate this operation. Browsers send the session cookie automatically; server clients preserve the complete issued Cookie header.

Parameters

Name In Required Type Description
token path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.

Responses

Status Body Description
200 PortalAccepted Portal membership plus the invitation’s project grants (and billing seat, for a customer invitation). No agency organization membership is created.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError The agency has not granted this action.
404 ApiError The resource does not exist, or the caller is a task-scoped credential and this endpoint is outside its allowlist.
409 ApiError Invitation revoked, account archived, or selected project reassigned.

POST /v1/api/portal/projects · operation ID createClientPortalIdea

Authentication — A signed-in user session is required. API keys cannot authenticate this operation. Browsers send the session cookie automatically; server clients preserve the complete issued Cookie header.

Parameters

Name In Required Type Description
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.
X-Client-Portal header no string The agency Workspace ID for a signed-in client’s portal requests. A verified user session and portal membership are required; API keys cannot authenticate portal access. This header does not grant agency administration access.

Request body — application/json, CreatePortalProject (required)

Property Type Required Notes
brief string no max length 20000
name string yes min length 1, max length 200

Responses

Status Body Description
201 ProjectRow Draft project under the client’s own customer, granted to them with messaging. No coding dispatch.
400 ValidationError | ApiError The JSON body failed schema validation (ValidationError), or the request named no active organization (ApiError).
401 ApiError No valid session or API key.
402 ApiError Agency project limit reached.
403 ApiError The agency has not granted this action.
404 ApiError Entity is not available in this portal/workspace.

GET /v1/api/portals/{agencySlug}/identity · operation ID getClientPortalIdentity

Authentication — Public; no API key or session required.

Parameters

Name In Required Type Description
agencySlug path yes string

Responses

Status Body Description
200 PortalIdentity Public identity only; no customer names, emails or membership.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError Authenticated, but not a member of the named organization — or a client collaborator without the required access on this project.
404 ApiError No workspace has this slug, or it never published its portal.

Enter the agency portal using the signed-in verified email

Section titled “Enter the agency portal using the signed-in verified email”

POST /v1/api/portals/{agencySlug}/session · operation ID enterWorkspaceClientPortal

Authentication — A signed-in user session is required. API keys cannot authenticate this operation. Browsers send the session cookie automatically; server clients preserve the complete issued Cookie header.

Parameters

Name In Required Type Description
agencySlug path yes string
X-Organization-Id header no string The workspace (organization) to act in. Omitted, the session’s active organization is used.
X-Client-Portal header no string The agency Workspace ID for a signed-in client’s portal requests. A verified user session and portal membership are required; API keys cannot authenticate portal access. This header does not grant agency administration access.

Responses

Status Body Description
200 WorkspacePortal Every live invitation sent to the verified email is accepted on entry; its project grants are added to the ones the client already has. No token or account choice required.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError Email must be verified (EMAIL_VERIFICATION_REQUIRED); scoped automation credentials denied.
404 ApiError Entity is not available in this portal/workspace.

Download an agency’s uploaded logo or icon

Section titled “Download an agency’s uploaded logo or icon”

GET /v1/api/portals/assets/{organizationId}/{file} · operation ID getClientPortalBrandAsset

Authentication — Public; no API key or session required.

Parameters

Name In Required Type Description
organizationId path yes string
file path yes string

Responses

Status Body Description
200 string (binary) The stored PNG (image/png) or JPEG (image/jpeg), typed by its name, with X-Content-Type-Options: nosniff and immutable caching.
400 ApiError The request named no active organization.
401 ApiError No valid session or API key.
403 ApiError Authenticated, but not a member of the named organization — or a client collaborator without the required access on this project.
404 ApiError No such upload.

The response table for each operation lists its documented errors. Common status codes include:

  • 400 — the body failed schema validation, or the request named no active organization. A ValidationError body carries the failing fields; an ApiError body carries only error.
  • 401 — no valid session or API key.
  • 403 — authenticated, but not a member of the named organization, or a client collaborator without the required access.
  • 404 — check the resource ID and your access to the selected Workspace.
  • 409 — the expected revision or state is stale, or another operation currently owns the transition.
  • 500 — the operation failed server-side. Retry only where an idempotency key makes that safe.