Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/openstatusHQ/sdk-php. php sdk for openstatus www.openstatus.dev
Something went wrong. Try again.
3.5 kB · 102 lines
PHP
at main
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103<?php# Generated by the protocol buffer compiler. DO NOT EDIT!# NO CHECKED-IN PROTOBUF GENCODE# source: openstatus/status_page/v1/service.proto
namespace Openstatus\Status_page\V1;
use Google\Protobuf\Internal\GPBType;use Google\Protobuf\Internal\GPBUtil;use Google\Protobuf\RepeatedField;
/** * WebhookChannel carries the webhook-channel fields for CreatePageSubscription. * * Generated from protobuf message <code>openstatus.status_page.v1.WebhookChannel</code> */class WebhookChannel extends \Google\Protobuf\Internal\Message{ /** * Webhook URL (required). Payload flavor (Slack / Discord / generic) is auto-detected from the URL prefix. * * Generated from protobuf field <code>string webhook_url = 1 [json_name = "webhookUrl", (.buf.validate.field) = {</code> */ protected $webhook_url = ''; /** * Optional custom HTTP headers attached to every dispatch. * * Generated from protobuf field <code>repeated .openstatus.status_page.v1.WebhookChannelHeader headers = 2 [json_name = "headers"];</code> */ private $headers;
/** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $webhook_url * Webhook URL (required). Payload flavor (Slack / Discord / generic) is auto-detected from the URL prefix. * @type \Openstatus\Status_page\V1\WebhookChannelHeader[] $headers * Optional custom HTTP headers attached to every dispatch. * } */ public function __construct($data = NULL) { \GPBMetadata\Openstatus\StatusPage\V1\Service::initOnce(); parent::__construct($data); }
/** * Webhook URL (required). Payload flavor (Slack / Discord / generic) is auto-detected from the URL prefix. * * Generated from protobuf field <code>string webhook_url = 1 [json_name = "webhookUrl", (.buf.validate.field) = {</code> * @return string */ public function getWebhookUrl() { return $this->webhook_url; }
/** * Webhook URL (required). Payload flavor (Slack / Discord / generic) is auto-detected from the URL prefix. * * Generated from protobuf field <code>string webhook_url = 1 [json_name = "webhookUrl", (.buf.validate.field) = {</code> * @param string $var * @return $this */ public function setWebhookUrl(string $var) { GPBUtil::checkString($var, true); $this->webhook_url = $var;
return $this; }
/** * Optional custom HTTP headers attached to every dispatch. * * Generated from protobuf field <code>repeated .openstatus.status_page.v1.WebhookChannelHeader headers = 2 [json_name = "headers"];</code> * @return RepeatedField<\Openstatus\Status_page\V1\WebhookChannelHeader> */ public function getHeaders() { return $this->headers; }
/** * Optional custom HTTP headers attached to every dispatch. * * Generated from protobuf field <code>repeated .openstatus.status_page.v1.WebhookChannelHeader headers = 2 [json_name = "headers"];</code> * @param \Openstatus\Status_page\V1\WebhookChannelHeader[] $var * @return $this */ public function setHeaders(array|RepeatedField $var) { $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Openstatus\Status_page\V1\WebhookChannelHeader::class); $this->headers = $arr;
return $this; }
}