Skip to content
This repository was archived by the owner on Sep 3, 2021. It is now read-only.

Latest commit

 

History

History
650 lines (491 loc) · 18.3 KB

File metadata and controls

650 lines (491 loc) · 18.3 KB

LaunchDarkly.Api.Api.CustomerMetricsApi

All URIs are relative to https://app.launchdarkly.com/api/v2

Method HTTP request Description
GetEvaluations GET /usage/evaluations/{envId}/{flagKey} Get events usage by event id and the feature flag key.
GetEvent GET /usage/events/{type} Get events usage by event type.
GetEvents GET /usage/events Get events usage endpoints.
GetMAU GET /usage/mau Get monthly active user data.
GetMAUByCategory GET /usage/mau/bycategory Get monthly active user data by category.
GetStream GET /usage/streams/{source} Get a stream endpoint and return timeseries data.
GetStreamBySDK GET /usage/streams/{source}/bysdkversion Get a stream timeseries data by source show sdk version metadata.
GetStreamSDKVersion GET /usage/streams/{source}/sdkversions Get a stream timeseries data by source and show all sdk version associated.
GetStreams GET /usage/streams Returns a list of all streams.
GetUsage GET /usage Returns of the usage endpoints available.

GetEvaluations

StreamSDKVersion GetEvaluations (string envId, string flagKey)

Get events usage by event id and the feature flag key.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetEvaluationsExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();
            var envId = envId_example;  // string | The environment id for the flag evaluations in question.
            var flagKey = flagKey_example;  // string | The key of the flag we want metrics for.

            try
            {
                // Get events usage by event id and the feature flag key.
                StreamSDKVersion result = apiInstance.GetEvaluations(envId, flagKey);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetEvaluations: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
envId string The environment id for the flag evaluations in question.
flagKey string The key of the flag we want metrics for.

Return type

StreamSDKVersion

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEvent

StreamSDKVersion GetEvent (string type)

Get events usage by event type.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetEventExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();
            var type = type_example;  // string | The type of event we would like to track.

            try
            {
                // Get events usage by event type.
                StreamSDKVersion result = apiInstance.GetEvent(type);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetEvent: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
type string The type of event we would like to track.

Return type

StreamSDKVersion

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEvents

Events GetEvents ()

Get events usage endpoints.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetEventsExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();

            try
            {
                // Get events usage endpoints.
                Events result = apiInstance.GetEvents();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetEvents: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

Events

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetMAU

MAU GetMAU ()

Get monthly active user data.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetMAUExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();

            try
            {
                // Get monthly active user data.
                MAU result = apiInstance.GetMAU();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetMAU: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

MAU

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetMAUByCategory

MAUbyCategory GetMAUByCategory ()

Get monthly active user data by category.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetMAUByCategoryExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();

            try
            {
                // Get monthly active user data by category.
                MAUbyCategory result = apiInstance.GetMAUByCategory();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetMAUByCategory: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

MAUbyCategory

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetStream

Stream GetStream (string source)

Get a stream endpoint and return timeseries data.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetStreamExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();
            var source = source_example;  // string | The source of where the stream comes from.

            try
            {
                // Get a stream endpoint and return timeseries data.
                Stream result = apiInstance.GetStream(source);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetStream: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
source string The source of where the stream comes from.

Return type

Stream

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetStreamBySDK

StreamBySDK GetStreamBySDK (string source)

Get a stream timeseries data by source show sdk version metadata.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetStreamBySDKExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();
            var source = source_example;  // string | The source of where the stream comes from.

            try
            {
                // Get a stream timeseries data by source show sdk version metadata.
                StreamBySDK result = apiInstance.GetStreamBySDK(source);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetStreamBySDK: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
source string The source of where the stream comes from.

Return type

StreamBySDK

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetStreamSDKVersion

StreamSDKVersion GetStreamSDKVersion (string source)

Get a stream timeseries data by source and show all sdk version associated.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetStreamSDKVersionExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();
            var source = source_example;  // string | The source of where the stream comes from.

            try
            {
                // Get a stream timeseries data by source and show all sdk version associated.
                StreamSDKVersion result = apiInstance.GetStreamSDKVersion(source);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetStreamSDKVersion: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
source string The source of where the stream comes from.

Return type

StreamSDKVersion

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetStreams

Streams GetStreams ()

Returns a list of all streams.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetStreamsExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();

            try
            {
                // Returns a list of all streams.
                Streams result = apiInstance.GetStreams();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetStreams: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

Streams

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetUsage

Usage GetUsage ()

Returns of the usage endpoints available.

Example

using System;
using System.Diagnostics;
using LaunchDarkly.Api.Api;
using LaunchDarkly.Api.Client;
using LaunchDarkly.Api.Model;

namespace Example
{
    public class GetUsageExample
    {
        public void main()
        {
            
            // Configure API key authorization: Token
            Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");

            var apiInstance = new CustomerMetricsApi();

            try
            {
                // Returns of the usage endpoints available.
                Usage result = apiInstance.GetUsage();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomerMetricsApi.GetUsage: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

Usage

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]