CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/pypi-azure-mgmt-media

Microsoft Azure Media Services Client Library for Python - A management library for Azure Media Services that provides programmatic access to media processing and streaming capabilities in the cloud.

83

1.09x

Quality

Pending

Does it follow best practices?

Impact

83%

1.09x

Average score across 10 eval scenarios

Overview
Eval results
Files

task.mdevals/scenario-4/

Live Event Streaming Manager

Build a system to manage live streaming events including creation, lifecycle control, and monitoring capabilities.

Capabilities

Live Event Creation

  • Creates a live event with pass-through encoding type and configures it for RTMP ingest @test
  • Creates a live event with standard cloud encoding and configures appropriate settings @test

Live Event Lifecycle Management

  • Starts a live event that is in stopped state @test
  • Stops a running live event @test
  • Resets a live event to clear its state @test

Live Output Management

  • Creates a live output to archive a live stream to an asset @test
  • Deletes a live output when archiving is complete @test

Event Monitoring

  • Retrieves the current state of a live event @test
  • Gets the ingest endpoint URL for a live event @test
  • Gets the preview endpoint URL for monitoring a live event @test

Implementation

@generates

API

class LiveEventManager:
    """Manages Azure Media Services live streaming events."""

    def __init__(self, client, resource_group: str, account_name: str):
        """
        Initialize the live event manager.

        Args:
            client: Azure Media Services client instance
            resource_group: Azure resource group name
            account_name: Media Services account name
        """
        pass

    def create_passthrough_event(self, event_name: str, description: str = None) -> dict:
        """
        Create a pass-through live event that doesn't perform cloud encoding.

        Args:
            event_name: Name for the live event
            description: Optional description

        Returns:
            Dictionary containing live event details
        """
        pass

    def create_encoding_event(self, event_name: str, encoding_type: str = "Standard", description: str = None) -> dict:
        """
        Create a live event with cloud encoding.

        Args:
            event_name: Name for the live event
            encoding_type: Encoding type (e.g., "Standard", "Premium1080p")
            description: Optional description

        Returns:
            Dictionary containing live event details
        """
        pass

    def start_event(self, event_name: str) -> None:
        """
        Start a live event.

        Args:
            event_name: Name of the live event to start
        """
        pass

    def stop_event(self, event_name: str) -> None:
        """
        Stop a running live event.

        Args:
            event_name: Name of the live event to stop
        """
        pass

    def reset_event(self, event_name: str) -> None:
        """
        Reset a live event to clear its state.

        Args:
            event_name: Name of the live event to reset
        """
        pass

    def create_live_output(self, event_name: str, output_name: str, asset_name: str, archive_window_minutes: int = 60) -> dict:
        """
        Create a live output to archive the live stream to an asset.

        Args:
            event_name: Name of the live event
            output_name: Name for the live output
            asset_name: Name of the asset to archive to
            archive_window_minutes: DVR window length in minutes

        Returns:
            Dictionary containing live output details
        """
        pass

    def delete_live_output(self, event_name: str, output_name: str) -> None:
        """
        Delete a live output.

        Args:
            event_name: Name of the live event
            output_name: Name of the live output to delete
        """
        pass

    def get_event_state(self, event_name: str) -> str:
        """
        Get the current state of a live event.

        Args:
            event_name: Name of the live event

        Returns:
            Current state as a string (e.g., "Running", "Stopped")
        """
        pass

    def get_ingest_endpoint(self, event_name: str) -> str:
        """
        Get the RTMP ingest endpoint URL for a live event.

        Args:
            event_name: Name of the live event

        Returns:
            Ingest endpoint URL
        """
        pass

    def get_preview_endpoint(self, event_name: str) -> str:
        """
        Get the preview endpoint URL for monitoring a live event.

        Args:
            event_name: Name of the live event

        Returns:
            Preview endpoint URL
        """
        pass

Dependencies { .dependencies }

azure-mgmt-media { .dependency }

Provides Azure Media Services management capabilities for live streaming.

Install with Tessl CLI

npx tessl i tessl/pypi-azure-mgmt-media

tile.json