---
title: "Upsert an external actor"
method: PUT
path: "/orgs/{orgID}/projects/{projectID}/actors"
tags: ["Actors"]
---

# Upsert an external actor

`PUT /orgs/{orgID}/projects/{projectID}/actors`

## Request

- Base URL: `https://api.omnara.com/v1`
- URL: `https://api.omnara.com/v1/orgs/{orgID}/projects/{projectID}/actors`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `__Host-omnara_session` and API key in header `X-Omnara-Csrf`

Upserts by (provider_tenant_id, provider_user_id). Omitted attributes keep their stored values; provided attributes are overwritten, including empty values. An unchanged actor is not rewritten. Actors written through this endpoint always have the external provider.

## Path parameters

- `orgID` string, required
- `projectID` string, required

## Request body

- ExternalActorParams: Identity and attributes of an external actor. Actors are upserted by (provider_tenant_id, provider_user_id) with the external provider. Omitted attributes keep their stored values; provided attributes are overwritten, including empty values. omnara actors are implicit and hosted integrations own their own actor identities.
  - `provider_tenant_id` string: Your tenant or namespace for the user. With provider_user_id, identifies the actor.
  - `provider_user_id` string, required: The user's ID in your system. With provider_tenant_id, identifies the actor.
  - `display_name` string: Display name for the actor.
  - `metadata` Metadata: Key-value attributes for the actor. Replaces stored metadata when sent.

## Response `200`

The upserted actor.

- Actor
  - `id` string, required
  - `org_id` string, required
  - `project_id` string, required: Project ID (proj_...).
  - `provider` 'omnara' | 'integration' | 'external', required: omnara for Omnara identities, integration for hosted integration senders, or external for API-managed actors.
  - `provider_tenant_id` string: Project-scoped identity namespace. Integration actors use a stable platform namespace (slack:<workspace ID>, discord, or github:github.com), shared across configured bots and integration kinds on that platform. Retained for attribution after integration deletion; not an authorization principal.
  - `provider_user_id` string, required: Stable sender identifier within the actor identity namespace.
  - `display_name` string
  - `metadata` Metadata, required: Saved actor attributes. Hosted integration actors store source_label (such as Slack) for display without a live integration lookup.
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required

## Other responses

- `400`: The request was invalid.
- `401`: Authentication is required or invalid.
- `403`: The authenticated principal is not authorized.
- `404`: The requested resource was not found or is not visible.
- `500`: An unexpected internal server error occurred.
- `503`: The service dependency required to satisfy the request is unavailable.
- `4XX`: Any other client error. The body carries the shared Error envelope restricted to client error codes; statuses with a dedicated response above are documented precisely.
- `5XX`: Any other server error. The body carries the shared Error envelope restricted to server error codes.

## Changes

- **2026-10-07** `680248a0ba72`: 1 warning, 1 info
  - added the new `integration` enum value to the `provider` response property for the response status `200`
  - removed the `slack` enum value from the `provider` response property for the response status `200`
- **2026-10-05** `3d9e2cf46e07`: 159 info
  - added the optional property `current_digest` to the response with the `400` status
  - added the optional property `current_digest` to the response with the `401` status
  - added the optional property `current_digest` to the response with the `403` status
  - added the optional property `current_digest` to the response with the `404` status
  - …155 more
  - …this revision’s changelog is incomplete
- **2026-09-28** `acddeb8fc6a5`: 7 warning, 7 info
  - added the new `upstream_unavailable` enum value to the `code` response property for the response status `400`
  - added the new `upstream_unavailable` enum value to the `code` response property for the response status `401`
  - added the new `upstream_unavailable` enum value to the `code` response property for the response status `403`
  - added the new `upstream_unavailable` enum value to the `code` response property for the response status `404`
  - …10 more
- **2026-09-01** `e4978b047d7a`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/omnara/apis/omnara-api-2/changes/orgs/:orgID/projects/:projectID/actors/put.md)

---

[API](https://skmtc.dev/omnara/apis/omnara-api-2.md) - [All operations](https://skmtc.dev/omnara/apis/omnara-api-2/llms.txt) - [OpenAPI document](https://skmtc.dev/omnara/apis/omnara-api-2/revisions/343aebb1dff1?raw)
