All URIs are relative to https://app.launchdarkly.com
Method | HTTP request | Description |
---|---|---|
delete_destination | DELETE /api/v2/destinations/{projectKey}/{environmentKey}/{id} | Delete Data Export destination |
get_destination | GET /api/v2/destinations/{projectKey}/{environmentKey}/{id} | Get destination |
get_destinations | GET /api/v2/destinations | List destinations |
patch_destination | PATCH /api/v2/destinations/{projectKey}/{environmentKey}/{id} | Update Data Export destination |
post_destination | POST /api/v2/destinations/{projectKey}/{environmentKey} | Create Data Export destination |
delete_destination(project_key, environment_key, id)
Delete Data Export destination
Delete a Data Export destination by ID.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import data_export_destinations_api
from launchdarkly_api.model.forbidden_error_rep import ForbiddenErrorRep
from launchdarkly_api.model.not_found_error_rep import NotFoundErrorRep
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.unauthorized_error_rep import UnauthorizedErrorRep
from pprint import pprint
# Defining the host is optional and defaults to https://app.launchdarkly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = launchdarkly_api.Configuration(
host = "https://app.launchdarkly.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKey
configuration.api_key['ApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKey'] = 'Bearer'
# Enter a context with an instance of the API client
with launchdarkly_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_export_destinations_api.DataExportDestinationsApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
id = "id_example" # str | The Data Export destination ID
# example passing only required values which don't have defaults set
try:
# Delete Data Export destination
api_instance.delete_destination(project_key, environment_key, id)
except launchdarkly_api.ApiException as e:
print("Exception when calling DataExportDestinationsApi->delete_destination: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
id | str | The Data Export destination ID |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
204 | Destination response | - |
401 | Invalid access token | - |
403 | Forbidden | - |
404 | Invalid resource identifier | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Destination get_destination(project_key, environment_key, id)
Get destination
Get a single Data Export destination by ID.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import data_export_destinations_api
from launchdarkly_api.model.forbidden_error_rep import ForbiddenErrorRep
from launchdarkly_api.model.not_found_error_rep import NotFoundErrorRep
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.destination import Destination
from launchdarkly_api.model.unauthorized_error_rep import UnauthorizedErrorRep
from pprint import pprint
# Defining the host is optional and defaults to https://app.launchdarkly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = launchdarkly_api.Configuration(
host = "https://app.launchdarkly.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKey
configuration.api_key['ApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKey'] = 'Bearer'
# Enter a context with an instance of the API client
with launchdarkly_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_export_destinations_api.DataExportDestinationsApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
id = "id_example" # str | The Data Export destination ID
# example passing only required values which don't have defaults set
try:
# Get destination
api_response = api_instance.get_destination(project_key, environment_key, id)
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling DataExportDestinationsApi->get_destination: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
id | str | The Data Export destination ID |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Destination response | - |
401 | Invalid access token | - |
403 | Forbidden | - |
404 | Invalid resource identifier | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Destinations get_destinations()
List destinations
Get a list of Data Export destinations configured across all projects and environments.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import data_export_destinations_api
from launchdarkly_api.model.forbidden_error_rep import ForbiddenErrorRep
from launchdarkly_api.model.destinations import Destinations
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.unauthorized_error_rep import UnauthorizedErrorRep
from pprint import pprint
# Defining the host is optional and defaults to https://app.launchdarkly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = launchdarkly_api.Configuration(
host = "https://app.launchdarkly.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKey
configuration.api_key['ApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKey'] = 'Bearer'
# Enter a context with an instance of the API client
with launchdarkly_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_export_destinations_api.DataExportDestinationsApi(api_client)
# example, this endpoint has no required or optional parameters
try:
# List destinations
api_response = api_instance.get_destinations()
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling DataExportDestinationsApi->get_destinations: %s\n" % e)
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Destination collection response | - |
401 | Invalid access token | - |
403 | Forbidden | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Destination patch_destination(project_key, environment_key, id, json_patch)
Update Data Export destination
Update a Data Export destination. Updating a destination uses a JSON patch or JSON merge patch representation of the desired changes. To learn more, read Updates.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import data_export_destinations_api
from launchdarkly_api.model.json_patch import JSONPatch
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
from launchdarkly_api.model.forbidden_error_rep import ForbiddenErrorRep
from launchdarkly_api.model.not_found_error_rep import NotFoundErrorRep
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.destination import Destination
from launchdarkly_api.model.unauthorized_error_rep import UnauthorizedErrorRep
from launchdarkly_api.model.status_conflict_error_rep import StatusConflictErrorRep
from pprint import pprint
# Defining the host is optional and defaults to https://app.launchdarkly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = launchdarkly_api.Configuration(
host = "https://app.launchdarkly.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKey
configuration.api_key['ApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKey'] = 'Bearer'
# Enter a context with an instance of the API client
with launchdarkly_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_export_destinations_api.DataExportDestinationsApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
id = "id_example" # str | The Data Export destination ID
json_patch = JSONPatch([
PatchOperation(
op="replace",
path="/exampleField",
value=None,
),
]) # JSONPatch |
# example passing only required values which don't have defaults set
try:
# Update Data Export destination
api_response = api_instance.patch_destination(project_key, environment_key, id, json_patch)
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling DataExportDestinationsApi->patch_destination: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
id | str | The Data Export destination ID | |
json_patch | JSONPatch |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Destination response | - |
400 | Invalid request | - |
401 | Invalid access token | - |
403 | Forbidden | - |
404 | Invalid resource identifier | - |
409 | Status conflict | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Destination post_destination(project_key, environment_key, destination_post)
Create Data Export destination
Create a new Data Export destination. In the config
request body parameter, the fields required depend on the type of Data Export destination.
Click to expand config
parameter details
#### Azure Event Hubs To create a Data Export destination with a kind
of azure-event-hubs
, the config
object requires the following fields: * namespace
: The Event Hub Namespace name * name
: The Event Hub name * policyName
: The shared access signature policy name. You can find your policy name in the settings of your Azure Event Hubs Namespace. * policyKey
: The shared access signature key. You can find your policy key in the settings of your Azure Event Hubs Namespace. #### Google Cloud Pub/Sub To create a Data Export destination with a kind
of google-pubsub
, the config
object requires the following fields: * project
: The Google PubSub project ID for the project to publish to * topic
: The Google PubSub topic ID for the topic to publish to #### Amazon Kinesis To create a Data Export destination with a kind
of kinesis
, the config
object requires the following fields: * region
: The Kinesis stream's AWS region key * roleArn
: The Amazon Resource Name (ARN) of the AWS role that will be writing to Kinesis * streamName
: The name of the Kinesis stream that LaunchDarkly is sending events to. This is not the ARN of the stream. #### mParticle To create a Data Export destination with a kind
of mparticle
, the config
object requires the following fields: * apiKey
: The mParticle API key * secret
: The mParticle API secret * userIdentity
: The type of identifier you use to identify your end users in mParticle * anonymousUserIdentity
: The type of identifier you use to identify your anonymous end users in mParticle #### Segment To create a Data Export destination with a kind
of segment
, the config
object requires the following fields: * writeKey
: The Segment write key. This is used to authenticate LaunchDarkly's calls to Segment. - Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import data_export_destinations_api
from launchdarkly_api.model.destination_post import DestinationPost
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
from launchdarkly_api.model.forbidden_error_rep import ForbiddenErrorRep
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.destination import Destination
from launchdarkly_api.model.unauthorized_error_rep import UnauthorizedErrorRep
from launchdarkly_api.model.status_conflict_error_rep import StatusConflictErrorRep
from pprint import pprint
# Defining the host is optional and defaults to https://app.launchdarkly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = launchdarkly_api.Configuration(
host = "https://app.launchdarkly.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKey
configuration.api_key['ApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKey'] = 'Bearer'
# Enter a context with an instance of the API client
with launchdarkly_api.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_export_destinations_api.DataExportDestinationsApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
destination_post = DestinationPost(
name="example-destination",
kind="google-pubsub",
config=None,
on=True,
) # DestinationPost |
# example passing only required values which don't have defaults set
try:
# Create Data Export destination
api_response = api_instance.post_destination(project_key, environment_key, destination_post)
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling DataExportDestinationsApi->post_destination: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
destination_post | DestinationPost |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
201 | Destination response | - |
400 | Invalid request | - |
401 | Invalid access token | - |
403 | Forbidden | - |
409 | Status conflict | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]