CorefinityCorefinityDocs
Open the Control PanelControl Panel
Team · 2 of 17

Update your company's notification settings

Changes your company's alert preferences and the Slack channel each kind of notification goes to. Anything you leave out stays as it is; send at least one setting. A channel must be one of your connected Slack workspace's channels, with or without the leading #; null means no channel. The company's name, phone number and address cannot be changed here.

PUT/api/company

Body

alerts_notificationsboolean
deployment_started_notificationsboolean
slack_channelsobject

The channels to change. A key left out stays as it is.

Fields
alertsstring or null

Up to 255 characters.

deployment_startedstring or null

Up to 255 characters.

deploymentsstring or null

Up to 255 characters.

maintenance_windowsstring or null

Up to 255 characters.

ticketsstring or null

Up to 255 characters.

Returns

200 The company and its settings as they are now.

Fields of the 200 answer
dataobjectRequired

Your company and its settings. Ids are numbers here, unlike in GET /company.

Fields
addressstring or nullRequired
can_changebooleanRequired

Whether you may change the settings.

countrystring or nullRequired
idintegerRequired

At least 1.

namestringRequired
phonestring or nullRequired
settingsobjectRequired
Fields
alerts_notificationsbooleanRequired
deployment_started_notificationsbooleanRequired
slack_channelsobjectRequired

The Slack channel each kind of notification goes to, as #name, or null for none. A null deployment_started uses the deployments channel.

Fields
alertsstring or nullRequired
deployment_startedstring or nullRequired
deploymentsstring or nullRequired
maintenance_windowsstring or nullRequired
ticketsstring or nullRequired
slackobjectRequired
Fields
connectedbooleanRequired

Whether your company has connected Slack. Slack is connected in the Control Panel.

deliveryarray of objectsRequired

The state of recent notification deliveries to Slack, one item for each destination. Empty when there is nothing to report.

Fields of each item
actionstring or nullRequired

What to do, in plain words, when state is needs_attention. Null otherwise.

attemptsintegerRequired

At least 1.

checked_atstringRequired

When the last delivery was tried, in UTC, written with +00:00. Format: date-time.

destination_idstringRequired

An opaque id for the destination, 64 hexadecimal characters.

driverstringRequired

How the notification is sent, such as slack.

errorstring or nullRequired

Slack's error code for the last delivery, such as channel_not_found. Null after a delivery that worked.

last_delivered_atstring or nullRequired

When a notification last arrived. Null when none has. Format: date-time.

statestringRequired

healthy, retrying after a delivery that will be tried again, or needs_attention when deliveries have stopped.

healthyretryingneeds_attention
workspacestring or nullRequired

The connected workspace's name. Null while Slack is not connected.

typestringRequired
agencyclient

If it is refused

StatusReasonWhat to do
401noneSend a valid token as Authorization: Bearer <token>.
403scope_requiredUse a token with the scope named in scope.
404noneCheck the id. You see only what your account can reach.
409not_connectedThe outside account this needs is not connected for your company. Connect it first; the message names it.
422invalidFix the field named in field; errors says why.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl -X PUT https://manage.corefinity.com/api/company \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "alerts_notifications": false,
    "deployment_started_notifications": true
  }'
{
  "data": {
    "address": "14 Quay Street, Anytown, AB1 2CD",
    "can_change": true,
    "country": "GB",
    "id": 1204,
    "name": "Harbour & Finch",
    "phone": "+44 20 7946 0142",
    "settings": {
      "alerts_notifications": false,
      "deployment_started_notifications": true,
      "slack_channels": {
        "alerts": "#alerts",
        "deployment_started": null,
        "deployments": "#deployments",
        "maintenance_windows": null,
        "tickets": null
      }
    },
    "slack": {
      "connected": true,
      "delivery": [],
      "workspace": "harbourandfinch"
    },
    "type": "client"
  }
}
Try it
Held in this tab's memory only. Never stored or sent to us.

This sends a real PUT request and changes your account.

Use a token with only the write scope. How to make one

Was this helpful?
Open in ClaudeOpen in ChatGPT