> ## Documentation Index
> Fetch the complete documentation index at: https://learn.nexudus.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update SystemNotification

> Update an existing SystemNotification record.

Updates an existing SystemNotification record. You must include the `Id` of the record to update along with all required fields.

## Authentication

<Note>
  This endpoint requires OAuth2 authentication. Include a valid bearer token in the `Authorization` header.
  The authenticated user must be a full unrestricted administrator or have the **`SystemNotification-Edit`** role.
</Note>

## Enums

<Accordion title="eSystemNotificationSeverity — Severity values">
  | Value | Name   |
  | ----- | ------ |
  | 1     | Low    |
  | 2     | Medium |
  | 3     | High   |
</Accordion>

<Accordion title="eSystemNotificationMessageType — MessageType values">
  | Value | Name         |
  | ----- | ------------ |
  | 1     | Issue        |
  | 2     | Announcement |
</Accordion>

## Request Body

### Required Fields

<ParamField body="Id" type="integer" required>
  The Id of the SystemNotification record to update.
</ParamField>

<ParamField body="Title" type="string" required>
  The title value for this system notification.
</ParamField>

<ParamField body="Severity" type="integer" required>
  The severity value for this system notification.
</ParamField>

<ParamField body="StartTime" type="string" required>
  Date/time value for start time.
</ParamField>

<ParamField body="ShortDescription" type="string" required>
  The short description value for this system notification.
</ParamField>

<ParamField body="Description" type="string" required>
  Free-text description of this system notification.
</ParamField>

<ParamField body="MessageType" type="integer" required>
  The message type value for this system notification.
</ParamField>

### Optional Fields

<ParamField body="PublishOn" type="string">
  Date/time value for publish on.
</ParamField>

<ParamField body="UnPublishOn" type="string">
  Date/time value for un publish on.
</ParamField>

<ParamField body="ResolutionDescription" type="string">
  The resolution description value for this system notification.
</ParamField>

<ParamField body="Resolved" type="boolean">
  Whether resolved is enabled.
</ParamField>

<ParamField body="ResolvedOn" type="string">
  Date/time value for resolved on.
</ParamField>

<ParamField body="DisplayToAdmins" type="boolean">
  Whether display to admins is enabled.
</ParamField>

<ParamField body="DisplayToSettingIntegrations" type="string">
  The display to setting integrations value for this system notification.
</ParamField>

<ParamField body="DisplayToSettingGeneral" type="string">
  The display to setting general value for this system notification.
</ParamField>

<ParamField body="DisplayToPortalVersion" type="string">
  The display to portal version value for this system notification.
</ParamField>

<ParamField body="HasButton" type="boolean">
  Whether has button is enabled.
</ParamField>

<ParamField body="ButtonLabel" type="string">
  The button label value for this system notification.
</ParamField>

<ParamField body="ButtonUrl" type="string">
  The button url value for this system notification.
</ParamField>

## Code Examples

<CodeGroup>
  ```bash cURL theme={null}
  curl -X PUT \
    "https://spaces.nexudus.com/api/sys/systemnotifications" \
    -H "Authorization: Bearer YOUR_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "Title": "",
      "Severity": 0,
      "StartTime": "2025-01-15T10:30:00Z",
      "ShortDescription": "",
      "Description": "",
      "MessageType": 0,
      "Id": 87654321
  }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch(
    'https://spaces.nexudus.com/api/sys/systemnotifications',
    {
      method: 'PUT',
      headers: {
        'Authorization': 'Bearer YOUR_TOKEN',
        'Content-Type': 'application/json'
      },
      body: JSON.stringify({
        Title: '',
        Severity: 0,
        StartTime: '2025-01-15T10:30:00Z',
        ShortDescription: '',
        Description: '',
        MessageType: 0,
        Id: 87654321
      })
    }
  );

  const data = await response.json();
  ```

  ```python Python theme={null}
  import requests

  response = requests.put(
      'https://spaces.nexudus.com/api/sys/systemnotifications',
      headers={
          'Authorization': 'Bearer YOUR_TOKEN',
          'Content-Type': 'application/json'
      },
      json={
          'Title': '',
          'Severity': 0,
          'StartTime': '2025-01-15T10:30:00Z',
          'ShortDescription': '',
          'Description': '',
          'MessageType': 0,
          'Id': 87654321
      }
  )

  data = response.json()
  ```
</CodeGroup>

## Response

### 200

<ResponseField name="Status" type="integer">
  HTTP status code. `200` on success.
</ResponseField>

<ResponseField name="Message" type="string">
  A human-readable message confirming the update.
</ResponseField>

<ResponseField name="Value" type="object">
  Contains the `Id` of the updated record.
</ResponseField>

<ResponseField name="WasSuccessful" type="boolean">
  `true` if the systemnotification was updated successfully.
</ResponseField>

<ResponseField name="Errors" type="array">
  `null` on success.
</ResponseField>

```json Example Response theme={null}
{
  "Status": 200,
  "Message": "SystemNotification was successfully updated.",
  "Value": {
    "Id": 87654321
  },
  "OpenInDialog": false,
  "OpenInWindow": false,
  "RedirectURL": null,
  "JavaScript": null,
  "UpdatedOn": "2025-01-15T10:30:00Z",
  "UpdatedBy": "admin@example.com",
  "Errors": null,
  "WasSuccessful": true
}
```

### 400

<ResponseField name="Message" type="string">
  A summary of the validation error(s), in the format `PropertyName: error message`.
</ResponseField>

<ResponseField name="Value" type="any">
  `null` on validation failure.
</ResponseField>

<ResponseField name="Errors" type="object[]">
  Array of validation errors.

  <Expandable>
    <ResponseField name="AttemptedValue" type="any">
      The value that was submitted for the field, or `null` if missing.
    </ResponseField>

    <ResponseField name="Message" type="string">
      The validation error message.
    </ResponseField>

    <ResponseField name="PropertyName" type="string">
      The name of the property that failed validation.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="WasSuccessful" type="boolean">
  `false` when the request fails validation.
</ResponseField>

```json Example Response theme={null}
{
  "Message": "Title: is a required field",
  "Value": null,
  "Errors": [
    {
      "AttemptedValue": null,
      "Message": "is a required field",
      "PropertyName": "Title"
    }
  ],
  "WasSuccessful": false
}
```
