MuxWrapper.create_simulcast_target
You're seeing just the function
create_simulcast_target
, go back to MuxWrapper module for more information.
Specs
create_simulcast_target( %Tesla.Client{adapter: term(), fun: term(), post: term(), pre: term()}, String.t(), %MuxWrapper.EmbeddedSchema.Simulcast{ id: term(), passthrough: term(), stream_key: term(), url: term() } ) :: %MuxWrapper.EmbeddedSchema.Simulcast{ id: term(), passthrough: term(), stream_key: term(), url: term() }
Provide a function to create simulcast target, strongly suggest read Mux doc first
Parameters
- client: provide by
client/0
- live_stream_id: live stream id
- params: request body,
MuxWrapper.EmbeddedSchema.Simulcast
Example
iex> params = %MuxWrapper.EmbeddedSchema.Simulcast{url: "rtmp://live.example.com/app", stream_key: "abcdefgh"}
%MuxWrapper.EmbeddedSchema.Simulcast{
id: nil,
passthrough: nil,
stream_key: "abcdefgh",
url: "rtmp://live.example.com/app"
}
iex> MuxWrapper.clinet() |> MuxWrapper.create_simulcast_target("live_stream_id_very_long", params)
%MuxWrapper.EmbeddedSchema.Simulcast{
id: "vuOfW021mz5QA500wYEQ9SeUYvuYnpFz011mqSvski5T8claN02JN9ve2g",
passthrough: "Example 1",
stream_key: "abcdefgh",
url: "rtmp://live.example1.com/app"
}