Skip to content
Ona Docs

UpdateAnnouncementBanner

client.organizations.announcementBanner.update(AnnouncementBannerUpdateParams { organizationId, enabled, message } body, RequestOptionsoptions?): AnnouncementBannerUpdateResponse { banner }
POST/gitpod.v1.OrganizationService/UpdateAnnouncementBanner

Updates the announcement banner configuration for an organization.

Use this method to configure the announcement banner displayed to all users. Only organization admins can update the banner. Requires Enterprise tier.

Examples

  • Enable announcement banner:

    organizationId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
    message: "Scheduled maintenance on Saturday 10pm-2am UTC"
    enabled: true
  • Disable announcement banner:

    organizationId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
    enabled: false
ParametersExpand Collapse
body: AnnouncementBannerUpdateParams { organizationId, enabled, message }
organizationId: string

organization_id is the ID of the organization

formatuuid
enabled?: boolean | null

enabled controls whether the banner is displayed

message?: string | null

message is the banner message. Supports basic Markdown. Maximum 1000 characters.

maxLength1000
ReturnsExpand Collapse
AnnouncementBannerUpdateResponse { banner }

UpdateAnnouncementBanner

import Gitpod from '@gitpod/sdk';

const client = new Gitpod({
  bearerToken: process.env['GITPOD_API_KEY'], // This is the default and can be omitted
});

const announcementBanner = await client.organizations.announcementBanner.update({
  organizationId: 'b0e12f6c-4c67-429d-a4a6-d9838b5da047',
});

console.log(announcementBanner.banner);
{
  "banner": {
    "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "enabled": true,
    "message": "message"
  }
}
Returns Examples
{
  "banner": {
    "organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "enabled": true,
    "message": "message"
  }
}