Skip to content

Commit

Permalink
added new utility class
Browse files Browse the repository at this point in the history
  • Loading branch information
Allan-Nava authored Jun 11, 2024
1 parent 42346d2 commit 8f84805
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion lib/compressjs/tangram.ts
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ export class TangramClient {


/**
*
* To create a bulk events
* @param {string} instance_name
* @param {string} event_name
* @returns instance event object
Expand Down Expand Up @@ -593,6 +593,24 @@ export class TangramClient {
})
}

/**
* To create an external server object
* @param {string} audio_channel
* @param {string} ingest_protocol
* @param {string} external_server
* @returns external server object
*/
createExternalServer(audio_channel: string, ingest_protocol: string, external_server: string){
if (! this.isValidProtocol(ingest_protocol)){
return null
}
return {
"external_server": external_server,
"audio_channel": audio_channel,
"ingest_protocol": ingest_protocol,
}
}

/** TODO:
* RESTREAMER_PUSH_START
* ApiKey string `json:"api_key" `
Expand Down

0 comments on commit 8f84805

Please sign in to comment.