El contenido no se encuentra disponible en el idioma seleccionado. Estamos trabajando continuamente para agregar más idiomas. Gracias por su apoyo.

Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ Live/ Cloud Live/ Stream Push/ Stream Status Notifications

Stream Status Notifications

Updated on 2024-12-06 GMT+08:00

You can add a URL on the Live console for receiving messages when stream push starts or ends. The messages are sent as POST requests to your server through an HTTP API. Then your server returns the status code 200 to confirm that the messages have been received.

Notes

In the AP-Bangkok region, submit a service ticket for review after configuring stream status notifications. The configuration takes effect only after it is approved.

After stream status notifications are enabled, you will receive a message each time when a live stream is pushed or disconnected. However, when a stream is disconnected soon after it was pushed, the server may receive the message on stream disconnection before receiving the message on stream pushing due to network transmission latency. In this case, you need to check the Unix timestamp parameter publish_timestamp in the message to check whether the stream pushing and stream disconnection are in the same stream pushing event. The timestamps generated in the stream pushing and stream disconnection of the same stream pushing event are the same.

Prerequisites

Adding a Notification URL

  1. Log in to the Live console.
  2. In the navigation pane, choose Domains.
  3. Click Manage in the Operation column of the desired ingest domain name.
  4. In the navigation pane, choose Template > Stream Status Notifications.
  5. Click Add. On the displayed dialog box, add a notification URL, as shown in Figure 1.

    NOTE:

    Only HTTP and HTTPS URLs are supported.

    Figure 1 Adding a notification URL
    Authentication Key: authentication key. You need to configure this parameter only when notification authentication is required.
    • A key contains 32 to 128 characters.
    • A key can also be automatically generated.

  6. Click OK.

    When stream pushing starts or ends, you will receive a notification message. For details about the notification message body, see Callback Example.

Managing Notification URLs

You can also perform the following operations:

  • Editing a notification URL

    Click Edit in the Operation column to edit the URL or authentication key for receiving stream push messages.

  • Deleting a notification URL

    Click Delete in the Operation column to delete the URL or authentication key for receiving stream push messages.

Callback Example

The following is an example of stream pushing and stream disconnection messages. Table 1 describes the fields in a message body.

{
    "domain":"push.example.com",
    "app":"live",
    "stream":"example_stream",
    "user_args":"auth_info=yz1TG0PVN/5isfyrGrRj10gKPCWqSS2X02t6QsRrocH+mEq0gQ0g8k6KhalS84sQ+kDprFyqI0yajbYiFmUO8e45B7ryaS+MpJBlYkhwnuFLnRiKK/IXG7.33436b625354564f6e4d4d434f55&cdn=hw",
    "client_ip":"100.111.*.*",
    "node_ip":"112.11.*.*",
    "publish_timestamp":"1587954134",
    "event":"PUBLISH",
    "auth_timestamp":1587954140,
    "auth_sign":"ff3b2bxxx5cfd56e76d72bed4c4aa2dxxxca8c2e46467d205a6417d4fc"
}
Table 1 Message body

Field

Description

domain

Ingest domain name

app

Application name

stream

Stream name

user_args

Stream pushing parameter

client_ip

IP address of the streaming device

node_ip

IP address of the receiver

publish_timestamp

Unix timestamp. One single timestamp is generated for each stream pushing event.

event

Stream pushing or stream disconnection.

Options:

  • PUBLISH: Stream pushing starts.
  • PUBLISH_DONE: Stream pushing ends.

auth_timestamp

UNIX timestamp when the event notification signature expires. This parameter is carried when an authentication key is configured.

The value is a decimal UNIX timestamp, that is, the number of seconds that have elapsed since January 1, 1970 (midnight UTC/GMT).

Example: 1592639100 (June 20, 2020 15:45)

auth_sign

Event notification signature. This parameter is carried when an authentication key is configured.

auth_sign = HmacSHA256 (event + domain + app + stream + auth_timestamp, key)

key indicates the key used for authentication.

Utilizamos cookies para mejorar nuestro sitio y tu experiencia. Al continuar navegando en nuestro sitio, tú aceptas nuestra política de cookies. Descubre más

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback