tencent cloud

Feedback

Recording Callback Description

Last updated: 2024-01-18 14:13:49

    Description of the Server-Side Recording Callback

    Notes

    Subject to the network conditions, the sequence of the notifications received by your server may be different from the sequence of the events that actually occurred.The service offers a retry mechanism, but it is not guaranteed that all messages can arrive.In view of the above, it is not recommended that your core business logic depend on the message notification service.

    Network protocol

    If the callback URL, i.e., the URL of an HTTP(S) API, is configured in the console, then the POST method should be supported and transferred data should be encoded with UTF-8.

    HTTP header parameters

    Parameter
    Type
    Required
    Description
    Signature
    String
    Yes
    Signature. For more information, see Signature generation.

    Signature generation

    Signature = HMAC-SH1 ( strContent, SecretKey )
    strContent: Original signature string, which is the entire JSON content of body (the length is subject to Content-Length).
    body: JSON content called back to the business. The entire content in Sample callback is body.
    SecretKey: Application permission key, which can be viewed in Details in the console.
    HMAC-SH1: Signature algorithm.

    Callback parameters

    Name
    Type
    Description
    BizID
    Integer
    Application's `AppID`, which can be viewed in Details in the console.
    RoomID
    String
    Room ID
    UserID
    String
    User ID
    RecordMode
    Integer
    Recording mode. Valid values:
    0: Single stream
    1: Mixed stream
    Timestamp
    Integer
    Timestamp in seconds when the callback is sent
    TaskID
    Integer
    The task ID assigned by the cloud recording service, which uniquely identifies a recording process and becomes invalid after a recording task ends. When you use the custom recording mode, the task ID can be obtained through the response parameter when recording starts. It needs to be saved by the business as a request parameter for subsequent operations on the recording task.
    EventType
    Integer
    Event type
    Detail
    Event details, whose format is specified by EventType.

    EventDetail event details

    EventType
    Description
    Detail
    1
    Recording started.
    SeqNo: Segment number of the Number type
    FileName: Filename of the String type
    2
    Recording is completed.
    SeqNo: Segment number of the Number type
    FileName: Filename of the String type
    3
    The audio file has been uploaded.
    SeqNo: Segment number of the Number type
    FileName: Filename of the String type

    Sample callback

    {
    "BizID":1400000000,
    "RoomID":"100",
    "UserID":"999",
    "TaskID":446946705284000000,
    "RecordMode":1,
    "Timestamp":1675930605,
    "EventType":1,
    "Detail":{
    "SeqNo":0,
    "FileName":"1400000000_100_999/2023-02-09-16-16-45_446946705284000000_audio.mp3"
    }
    }
    
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support