• Logging query examples for the Wowza Streaming Engine REST API

    Wowza Streaming Engine™ media server software has a REST Application Programming Interface (API) that can be used to configure, manage, and monitor the media server through HTTP requests. This article demonstrates how to get logging information for a Wowza Streaming Engine instance using some basic cURL examples to query the Wowza Streaming Engine REST service. For a complete breakdown and documentation of the API, see How to access documentation for the Wowza Streaming Engine REST API.

    Note: Wowza Streaming Engine 4.3.0 or later is required. You must also have working knowledge of cURL and REST-related services.

    Contents


    Get log lines from a log file
    Search log files

    Get log lines from a log file


    To get log lines from a specific log file, you must get a list of log files before requesting the lines.

    1. Use the following request get a list of log files:
      curl -X GET --header 'Accept:application/json; charset=utf-8' "http://localhost:8087/v2/servers/Wowza%20Streaming%20Engine/logfiles?order=newestFirst"
    2. Then request log lines from a corresponding file, using lineCount to specify the total number of log lines to return:
      curl -X GET --header 'Accept:application/json; charset=utf-8' "http://localhost:8087/v2/servers/Wowza%20Streaming%20Engine/logfiles/wowzastreamingengine_access.log?lineCount=100"

    Search log files


    To search a log file, you must get a list of log files before sending the search request.

    1. Use the following request to get a list of log files:
      curl -X GET --header 'Accept:application/json; charset=utf-8' "http://localhost:8087/v2/servers/Wowza%20Streaming%20Engine/logfiles?order=newestFirst"
    2. Then search a corresponding log file using the following request, replacing [SEARCH-STRING] with your search parameters:
      curl -X GET --header 'Accept:application/json; charset=utf-8' "http://localhost:8087/v2/servers/Wowza%20Streaming%20Engine/logfiles/wowzastreamingengine_access.log?search=[SEARCH-STRING]"


    Originally Published: 06-16-2015.
    Updated: For Wowza Streaming Engine 4.3.0 on 10-06-2015.

    If you're having problems or want to discuss this article, post in our forum.