Skip to main content
Activities log changes to your project, including when you deploy your app, when you push code, and when a cron job is run. To automate your workflows, you can parse and react to the activity’s JSON object through activity scripts.

Activity schema

Every activity has a corresponding JSON object containing all information for that activity, including timestamps, configuration, and sometimes logs. In practice, you can ignore much of the JSON object’s content. The most commonly used values are documented in this reference. The response differs depending on the activity and doesn’t always include all fields.

Example response

The following is a shortened example of a response for an environment sync activity. You can also see complete examples of responses.

id

A unique id value to identify the activity itself.

*_at

created_at, started_at, updated_at, cancelled_at, completed_at, and expires_at are all timestamps in UTC. For when a given activity occurred, use completed_at. You can use these properties to calculate the duration of the activity. To calculate the timing for steps in the activity, see the timings property.

parameters

The parameters property includes detailed information about what triggered the activity, such as the user, the impacted environment, the git commits, or the cron commands. The response changes based on the activity.

project

The ID of the project in which the activity took place. Use this value to distinguish multiple projects sent the same URL. Different from project activities.

type

The type of the activity in one of the following categories:

project activity types

Activities that happened on a given project. The following table presents the possible activity types:
NameDescription
project.clear_build_cacheThe build cache is cleared.
project.createA new project is created.
project.metrics.enableA metric from the continuous profiling has been enabled.
project.metrics.updateA metric from the continuous profiling has been updated.
project.metrics.disableA metric from the continuous profiling has been disabled.
project.modify.titleThe project title has changed.
project.variable.createA new project variable has been created. The value is visible only if the variable is not set as sensitive.
project.variable.deleteA project variable has been deleted.
project.variable.updateA project variable has been modified.

environment activity types

Activities that happened on an environment. The following table presents the possible activity types:
NameDescription
environment.activateThe environment has been made active.
environment.backupA user triggered a backup.
environment.backup.deleteA user deleted a backup.
environment.branchA new branch has been created via the CLI, Console, or API. A branch created via Git shows up as environment.push.
environment.certificate.renewalAn environment’s SSL certificate has been renewed.
environment.cronA cron job has completed.
environment.deactivateAn environment has been made inactive.
environment.deleteAn environment’s code was deleted through Git.
environment.domain.createA new domain has been associated with the environment.
environment.domain.deleteA domain associated with the environment has been removed.
environment.domain.updateA domain associated with the environment has been updated, such as having its SSL certificate modified.
environment.initializeThe default branch of the project has just been initialized with its first commit.
environment.mergeAn environment was merged through the CLI, Console, or API. A basic Git merge doesn’t trigger this activity.
environment.merge-prA Pull Request/Merge Request was merged through the CLI, Console, or API. A basic Git merge doesn’t trigger this activity.
environment.operationA source operation has been triggered
environment.pauseAn environment has been paused.
environment.pushA user pushed code to a branch, either existing or new.
environment.redeployAn environment was redeployed.
environment.restoreA user restored a backup.
environment.resumeAn inactive environment was resumed
environment.resources.updateThe resources allocated to the environment have been updated.
environment.route.createA new route has been created through the API. Edits made using Git to the .upsun/config.yaml file don’t trigger this activity.
environment.route.deleteA route has been deleted through the API. Edits made using Git to the .upsun/config.yaml file don’t trigger this activity.
environment.route.updateA route has been modified through the API. Edits made using Git to the .upsun/config.yaml file don’t trigger this activity.
environment.source-operationA source operation has been triggered.
environment.synchronizeAn environment has had its data and/or code replaced with the data and/or code from its parent environment.
environment.update.http_accessHTTP access rules for an environment have been modified.
environment.update.restrict_robotsThe option to hide from search engines has been enabled or disabled for an environment.
environment.update.smtpEmail sending has been enabled or disabled for an environment.
environment.variable.createA new variable has been created. The value is visible only if the variable is not set as sensitive.
environment.variable.deleteA variable has been deleted.
environment.variable.updateA variable has been modified.
environment_type.access.createA new access has been added to the environment
environment_type.access.deleteAn existing access to the environment has been deleted
environment_type.access.updateAn existing access to the environment has been updated

integration activity types

Activities that relate to an integration. The following table presents the possible activity types:
NameDescription
integration.bitbucket.fetchA fetch has been triggered on your Bitbucket Cloud repository.
integration.bitbucket.register_hooksAn integration hook has been registered with Bitbucket Cloud.
integration.bitbucket_server.fetchA fetch has been triggered on your Bitbucket Server repository.
integration.bitbucket_server.register_hooksAn integration hook has been registered with Bitbucket Server.
integration.github.fetchA fetch has been triggered on your GitHub repository.
integration.gitlab.fetchA fetch has been triggered on your GitLab repository.
integration.health.emailA health notification was sent by email.
integration.health.pagerdutyA health notification was sent to PagerDuty.
integration.health.slackA health notification was sent to Slack.
integration.health.webhookA health notification was sent to a webhook.
integration.scriptAn activity script has been triggered.
integration.webhookA webhook was triggered.

maintenance activity types

Activities that relate to a maintenance. The following table presents the possible types:
NameDescription
maintenance.upgradeAn upgrade is triggered for API Server and Metrics Server

environments

An array listing the environments that were involved in the activity. It’s usually only a single value representing one environment.

state

The current state of the activity. Its value can be pending, in_progress, complete, cancelled, or scheduled.

completion_percent

What percentage of the activity is complete.

result

Whether or not the activity completed successfully. If it did, the value is success. Note that certain activities, such as deploy hooks, can be marked as successful activities even if some commands failed.

timings

The amount of time required by the activity. It can include the following properties:
NameDescription
waitThe delay if a command is set to wait before being executed.
buildThe execution time for the build hook.
deployThe execution time for the deploy hook.
executeThe execution time for your script or cron job.

log

A human-friendly record of what happened in the activity. The log shouldn’t be parsed for data as its structure isn’t guaranteed.

description

A short machine-readable description of the activity.

text

A short human-readable description of the activity.

payload

Contains settings and details related to the completed activity. Its content varies based on the activity type.
NameDescription
payload.userThe user that triggered the activity. For details on its properties, see the user payload.
payload.environmentThe environment affected by the activity. For details on its properties, see the environment payload.
payload.commitsA list of changes with their Git metadata.
payload.commits_countThe number of Git commits.
payload.deploymentInformation about the deployed environment. For details on its properties, see the deployment payload.
payload.projectInformation about the project. For details on its properties, see the project payload.

user payload

Contains information about the Upsun user that triggered the activity.
NameDescription
payload.user.created_atThe date the user was created.
payload.user.display_nameThe user’s name in a human-friendly format.
payload.user.idThe user’s ID.
payload.user.updated_atThe date the user was last updated.

environment payload

Contains information about the environment associated with the activity, including its settings, state, and deployment. The following table presents the most notable properties of the environment:
NameDescription
payload.environment.nameThe environment name.
payload.environment.typeThe environment type.
payload.environment.head_commitThe ID of the environment’s latest Git commit.
payload.environment.edge_hostnameThe URL you should target when setting up a custom domain.
Different from environment activities.

project payload

Contains information about the project associated with the activity, including plan details, timezone, and region. The following table presents the most notable properties of the project:
NameDescription
payload.project.timezoneYour project’s timezone.
payload.project.regionYour project’s region.
payload.project.titleYour project’s name.
payload.project.subscriptionAll of the details about your project’s plan.
Different from project activities.

deployment payload

Contains information about the deployed environment, if one is associated with the activity. The following table presents the most notable properties of the deployment:
NameDescription
payload.deployment.routesAll the URLs connected to the environment. The list includes redirects. To exclude redirects, find objects whose type is upstream.
payload.deployment.servicesAll the services on your environment.
payload.deployment.variablesAll the variables for the environment.
The payload.deployment property includes the configuration extracted from the following sources:

Maximum activities and parallelism

Project activities are distributed across separate queues, which enables two simultaneous activities to occur in parallel across your environments. For a given environment, only one activity can run at a time. Those queues include the following types of activities:
NameDescription
defaultThe most common activities on repositories (pushes, merges) and environments (syncs, redeployments).
integrationsSource and webhook integration activities.
backupBackup activities.
cronCron activities.
Production activities are prioritized across all queues. When an activity for the production environment is triggered, it’s placed at the top of the queue. This makes it unlikely that activities on preview environments block activities for the production environment for long, though there may be a temporary wait.

Examples

The response is often usually long, so the following examples are shortened using ellipses. Remember that the response differs depending on the activity and not all fields are always available. To test responses, set up a webhook.

Cron

When a cron job is triggered, the activity contains all the job’s information. The following example response was triggered by a setting where the cron is scheduled to run every five minutes (5 * * * *) with the command sleep 60 && echo sleep-60-finished && date and times out after 86,400 seconds. To get details about the configured cron job, see the parameters property:
...
  "parameters": {
    "user": "admin",
    "cluster": "abcdefgh1234567-main-abcd123",
    "environment": "main",
    "application": "app",
    "cron": "saybye",
    "spec": {
      "spec": "5 * * * *",
      "commands": {
        "start": "sleep 60 && echo sleep-60-finished && date",
        "stop": null
      },
      "shutdown_timeout": null,
      "timeout": 86400
    }
...
The following example shows the full activity response to a cron job:
{
  "id": "ypalrypnezbye",
  "_links": {
    "self": {
      "href": "https://eu-3.upsun.com/api/projects/abcdefgh1234567/activities/ypalrypnezbye"
    },
    "log": {
      "href": "/api/projects/abcdefgh1234567/activities/ypalrypnezbye/log"
    }
  },
  "created_at": "2026-12-13T16:06:08.081312+00:00",
  "updated_at": null,
  "type": "environment.cron",
  "parameters": {
    "user": "admin",
    "cluster": "abcdefgh1234567-main-abcd123",
    "environment": "main",
    "application": "app",
    "cron": "saybye",
    "spec": {
      "spec": "5 * * * *",
      "commands": {
        "start": "sleep 60 && echo sleep-60-finished && date",
        "stop": null
      },
      "shutdown_timeout": null,
      "timeout": 86400
    }
  },
  "project": "abcdefgh1234567",
  "environments": [
    "main"
  ],
  "state": "complete",
  "result": "success",
  "started_at": "2026-12-13T16:06:08.258090+00:00",
  "completed_at": "2026-12-13T16:07:09.658339+00:00",
  "completion_percent": 100,
  "cancelled_at": null,
  "timings": {
    "wait": 0,
    "execute": 61.244
  },
  "log": "hello world\nTue Jan 01 16:07:09 UTC 2026",
  "payload": {
    "user": {
      "id": "admin",
      "created_at": "2026-12-13T16:06:08.066085+00:00",
      "updated_at": null,
      "display_name": "Upsun Bot"
    },
    "project": {
      "id": "abcdefgh1234567",
      "created_at": "2026-03-22T15:47:28.739099+00:00",
      "updated_at": "2026-12-01T09:42:19.860188+00:00",
      "attributes": {},
      "title": "php-test",
      "description": "",
      "owner": "c9926428-44dc-4b10-be03-a26dd43b44c1",
      "namespace": "upsun",
      "organization": "01FF4NBNVMMDWP1NVK0G4EGJW0",
      "default_branch": "main",
      "status": {
        "code": "provisioned",
        "message": "ok"
      },
      "timezone": "Europe/Dublin",
      "region": "eu-3.upsun.com",
      "repository": {
        "url": "abcdefgh1234567@git.eu-3.upsun.com:abcdefgh1234567.git",
        "client_ssh_key": "ssh-rsa aaaaaaabbbbbbbcccccccddddddd abcdefgh1234567@upsun"
      },
      "default_domain": null,
      "subscription": {
        "license_uri": "https://accounts.upsun.com/api/v1/licenses/2291467",
        "plan": "development",
        "environments": 3,
        "storage": 5120,
        "included_users": 1,
        "subscription_management_uri": "https://console.upsun.com-/users/abcd12345/billing/plan/12345678",
        "restricted": false,
        "suspended": false,
        "user_licenses": 1
      }
    },
    "environment": {
      "id": "main",
      "created_at": "2026-03-22T15:47:43.750880+00:00",
      "updated_at": "2026-11-29T16:16:37.085719+00:00",
      "name": "main",
      "machine_name": "main-abcd123",
      "title": "Main",
      "attributes": {},
      "type": "production",
      "parent": null,
      "default_domain": null,
      "clone_parent_on_create": true,
      "deployment_target": "local",
      "is_pr": false,
      "status": "active",
      "enable_smtp": true,
      "restrict_robots": true,
      "edge_hostname": "main-abcd123-abcdefgh1234567.eu-3.platformsh.site",
      "deployment_state": {
        "last_deployment_successful": true,
        "last_deployment_at": "2026-11-29T16:16:37.085609+00:00",
        "crons": {
          "enabled": true,
          "status": "running"
        }
      },
      "resources_overrides": {},
      "last_active_at": "2026-12-13T15:07:10.862854+00:00",
      "last_backup_at": null,
      "project": "abcdefgh1234567",
      "is_main": true,
      "is_dirty": false,
      "has_code": true,
      "head_commit": "6aac318907b50252976c47e4e62ed95d438af0ea",
      "merge_info": {
        "commits_ahead": 0,
        "commits_behind": 0,
        "parent_ref": null
      },
      "has_deployment": true
    },
    "cron": "saybye"
  },
  "description": "<user data-id=\"admin\">Upsun Bot</user> ran cron <strong>saybye</strong>",
  "text": "Upsun Bot ran cron **saybye**",
  "expires_at": "2026-01-12T16:06:08.081293+00:00"
}

Push

A push activity contains several properties. The commits property contains everything related to the Git push that triggered the activity:
...
    "commits": [
      {
        "sha": "2bab04e050279ac078d5d34016f5dd9c466e948d",
        "author": {
          "email": "cloeweber@example.com",
          "name": "Cloé Weber",
          "date": 1671032461
        },
        "parents": [
          "6aac318907b50252976c47e4e62ed95d438af0ea"
        ],
        "message": "Add cron"
      }
    ],
...
The environment property contains the settings for the environment that was pushed to:
...
    "environment": {
      "id": "main",
      "created_at": "2026-03-22T15:47:43.750880+00:00",
      "updated_at": "2026-11-29T16:16:37.085719+00:00",
      "name": "main",
      "machine_name": "main-abcd123",
      "title": "Main",
      "attributes": {},
      "type": "production",
      "parent": null,
      "default_domain": null,
      "clone_parent_on_create": true,
      "deployment_target": "local",
      "is_pr": false,
      "status": "active",
      "enable_smtp": true,
      "restrict_robots": true,
      "edge_hostname": "main-abcd123-abcdefgh1234567.eu-3.platformsh.site",
      "deployment_state": {
        "last_deployment_successful": true,
        "last_deployment_at": "2026-11-29T16:16:37.085609+00:00",
        "crons": {
          "enabled": true,
          "status": "sleeping"
        }
      },
      "resources_overrides": {},
      "last_active_at": "2026-12-13T16:07:09.788910+00:00",
      "last_backup_at": null,
      "project": "abcdefgh1234567",
      "is_main": true,
      "is_dirty": false,
      "has_code": true,
      "head_commit": "6aac318907b50252976c47e4e62ed95d438af0ea",
      "merge_info": {
        "commits_ahead": 0,
        "commits_behind": 0,
        "parent_ref": null
      },
      "has_deployment": true
    },
...
The deployment property contains the settings for the deployment, including the image type and resource allocation. The following example shows a shortened excerpt of the deployment property:
...
 "deployment": {
      "id": "current",
      "created_at": "2026-03-22T15:48:05.396979+00:00",
      "updated_at": "2026-12-14T15:41:57.264813+00:00",
      "cluster_name": "abcdefgh1234567-main-abcd123",
      "project_info": {
          "deployment": {
      "id": "current",
      "created_at": "2026-03-22T15:48:05.396979+00:00",
      "updated_at": "2026-12-14T15:41:57.264813+00:00",
      "cluster_name": "abcdefgh1234567-main-abcd123",
      "project_info": {
        "name": "abcdefgh1234567",
        "settings": {
          "initialize": {
            "values": {
              "initialize": true,
              "start": false,
              "base": {
                "files": [],
                "profile": "PHP",
                "config": null,
                "repository": "https://github.com/platformsh-templates/php.git@master",
                "title": "PHP"
              }
            }
          },
          ...
          "application_config_file": ".upsun/config.yaml",
          "project_config_dir": ".upsun/",
          ...
          "development_service_size": "S",
          "development_application_size": "S",
          "enable_certificate_provisioning": true,
          "certificate_style": "ecdsa",
          "certificate_renewal_activity": true,
          ...
          "cron_minimum_interval": 5,
          "cron_maximum_jitter": 20,
          "concurrency_limits": {
            "internal": null,
            "integration": 4,
            "backup": 2,
            "cron": 10,
            "default": 2
          },
          ...
          "build_resources": {
            "cpu": 1,
            "memory": 2048
          },
          ...
          "max_allowed_routes": 50000,
          "max_allowed_redirects_paths": 50000,
          "enable_incremental_backups": true,
          ...
        }
      },
...
The following example shows the full activity response to a Git push:
Last modified on March 11, 2026