Skip to main content
Use the Activities API to send Windmill the events your other systems record, such as a scored sales call, a resolved escalation, or a completed certification. Each event is an activity: something that happened at a point in time, about zero, one, or many employees. Windy can find activities and cite them as evidence, for example in Deep Research and in drafts for performance reviews. Windy only uses an activity for people who can see it.

How activities are organized

  • An activity type names a kind of event, such as call-score. Its description tells Windy what the event is and how to read its properties, so write it for a reader who has never seen your system. For example: “A scored sales call. properties.score is 0 to 100.”
  • An activity is one event of a type. It has a title, an occurredAt time, optional body text, a url back to your system, properties, tags, and the employees it’s about.
You identify both with your own keys. A type’s key is its externalId. An activity’s key is its type plus its own externalId, so call-8842 only needs to be unique within call-score.

Before you start

Creating activities and writing activity types requires the Manage activities permission (activities.manage). Admins and HR Admins have it by default, and you can add it to a custom role. Use a Read/write API key created by a member with that permission. Reading activities only needs a key that can see them. See Control who can see an activity.

Send your first activity

One Create or replace activities request can define a type and send its activities. This example uses the environment variables from the API overview:
The response returns Windmill’s id for each activity, in request order:
You only need activityTypes the first time you send a type, or when you change its name or description. You can also manage types on their own with Create or update an activity type.

Resend activities safely

Each write replaces the whole activity

Sending the same type and externalId again replaces the activity. It doesn’t merge with what’s stored. An omitted field goes back to its default, so:
  • A resend without tags clears the tags.
  • A resend without access resets access to EMPLOYEE_AND_MANAGERS.
Always send the complete activity. Because a resend writes the same result, repeating a request is safe, so you can retry after a timeout or rerun a sync.

A request succeeds or fails as a whole

Send 1 to 1,000 activities per request. If any item fails, nothing is written. error.details lists every failing item with its path in the request and a message. For example, when the second activity names an email that no employee has, error.details is:
  • 400: validation errors, unknown types, employees, groups, or integrations, and emails that match more than one employee.
  • 403: a write your key isn’t allowed to make. When both kinds occur, the status is 400 and details lists both.
  • 409: your own employee record changed while the request was written, for example in an employee merge. Nothing was written. Send the request again.
See Errors for the full envelope.

Describe an activity

Employees

Name each employee by employeeId or by email, not both. An email can be any of the employee’s addresses. It matches the one active employee who has it, or if no active employee does, the one archived employee who has it. You can name archived employees. An activity can also have no employees at all, when it’s context rather than something about a person.

Properties

properties is a flat object of structured details that you can filter on later. Each value is a string, number, boolean, or null, or an array of those. Nested objects and arrays inside arrays aren’t allowed. To group related details, put a . in the key, such as account.name. The whole key is one name.

Tags

Tags are labels such as q4-push. They match exactly and case-sensitively, so Q4 and q4 are different tags.

Limits

  • An externalId, a type, and a tag can each be up to 512 characters.
  • occurredAt must be an RFC 3339 date-time with Z or a ±HH:MM offset.
  • A field the request doesn’t define fails validation, except the keys you choose inside properties.

Control who can see an activity

Each activity’s access sets who can read it. Use a preset for the common cases: Access follows the org chart as it changes. A new manager can read an activity right away, and a former manager loses access, without any resend.

Keep an activity from its employees

By default, the employees on an activity can always read it, whatever access says. Set shareWithEmployees to false to remove that grant. For example, "access": "MANAGERS" with "shareWithEmployees": false shares a call score with an employee’s managers but not with the employee.

Grant access to specific people or groups

Instead of a preset, access can be an object that grants read or write access to employees, groups, reporting subtrees, reporting relationships, and member permissions. Write access lets its holder replace and archive that activity without the Manage activities permission. See the request schema in Create or replace activities for each field.

Who can always read and edit

Members with Manage activities and the employee who created an activity can always read and edit it. Archived activities never appear in any read.

Read activities

Search activities returns one page of matches, newest occurredAt first. Filter by type, employee, tag, time range, and property conditions:
Pages start at 1, pageSize defaults to 20 and goes up to 100, and you continue while pagination.hasMore is true. See Pagination. A few filter rules are worth knowing:
  • Every filter you supply must match, and all property conditions must match. A filter takes at most 49 property conditions.
  • Property values are never converted: the text "82" doesn’t equal the number 82.
  • eq, in, and the list operators match text exactly and case-sensitively. contains and startsWith ignore case.
  • notIn and notOverlaps also match activities where the property is missing.
For totals, use Count activities with the same filter. Set groupBy to type or month to break the count down, for example to chart activity volume by month.

Archive and restore

  • Archive an activity removes it from every read, search, and count. To restore it, send it again.
  • Archive an activity type archives the type and every one of its activities. Any later write of the type restores the type, but its activities stay archived until you send each one again.

FAQs

No. Each write replaces the whole activity, and omitted fields take their defaults. Keep the full activity in your system and send all of it every time.
A key acts with its creator’s current permissions. Creating an activity, and any activity type write, needs Manage activities. Replacing or archiving an existing activity needs Manage activities or write access to that activity. Also check that the key is Read/write. See Authentication.
Archive it with Archive an activity. Archived activities never appear in reads, and Windy doesn’t use them.
Activity requests share the standard API budget. See Rate limits. To send many activities, batch up to 1,000 per request.