Skip to main content
PUT
Create or update an activity type

Authorizations

Authorization
string
header
required

Use an API key or OAuth access token. Enter only the token in the authorization dialog; requests send it as Authorization: Bearer <TOKEN>.

Create an API key in your workspace's Settings → API keys. Keys start with wm_api_ and only work in the workspace where they were created. Read-only keys can read data; creating, updating, or deleting data requires a read-write key.

OAuth access tokens are issued for connected Windmill applications.

Both token types use the authenticated user's workspace permissions. Each endpoint's permission requirements and the sharing settings of the requested items still apply.

Path Parameters

companyId
string
required

Company ID. A URL slug is also accepted. The caller must have access to this company.

Required string length: 1 - 128
Example:

"company-acme"

externalId
string
required
Maximum string length: 512
Pattern: \S

Body

application/json
name
string
required
Pattern: \S
description
string
required
Pattern: \S
createOnly
boolean

Set true to create the type only when no active type has this key; otherwise the request fails with 409 and changes nothing. An archived type with this key is still restored and updated.

Response

The created or updated activity type.

id
string
required

Windmill's identifier for the type.

Example:

"019a2f7c-1b2d-7e3f-9a4b-5c6d7e8f9a0b"

externalId
string
required

Your key for the type, unique in the company, at most 512 characters. Activities name their type by this key.

Example:

"call-score"

name
string
required

The name people see for the type.

Example:

"Call score"

description
string
required

What the event is and how to read its properties, for example the range of a score. Windy uses it to interpret the type's activities.

Example:

"A scored sales call. properties.score is 0 to 100."

createdAt
string<date-time>
required

When the type was created.

updatedAt
string<date-time>
required

When the type was last changed.