All URIs are relative to https://app.launchdarkly.com
Method | HTTP request | Description |
---|---|---|
create_big_segment_export | POST /api/v2/segments/{projectKey}/{environmentKey}/{segmentKey}/exports | Create big segment export |
create_big_segment_import | POST /api/v2/segments/{projectKey}/{environmentKey}/{segmentKey}/imports | Create big segment import |
get_big_segment_export | GET /api/v2/segments/{projectKey}/{environmentKey}/{segmentKey}/exports/{exportID} | Get big segment export |
get_big_segment_import | GET /api/v2/segments/{projectKey}/{environmentKey}/{segmentKey}/imports/{importID} | Get big segment import |
create_big_segment_export(project_key, environment_key, segment_key)
Create big segment export
Starts a new export process for a big segment. This is an export for a synced segment or a list-based segment that can include more than 15,000 entries.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import segments_beta_api
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
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 = segments_beta_api.SegmentsBetaApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
segment_key = "segmentKey_example" # str | The segment key
# example passing only required values which don't have defaults set
try:
# Create big segment export
api_instance.create_big_segment_export(project_key, environment_key, segment_key)
except launchdarkly_api.ApiException as e:
print("Exception when calling SegmentsBetaApi->create_big_segment_export: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
segment_key | str | The segment key |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Action succeeded | - |
400 | Invalid request | - |
401 | Invalid access token | - |
404 | Invalid resource identifier | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_big_segment_import(project_key, environment_key, segment_key)
Create big segment import
Start a new import process for a big segment. This is an import for a list-based segment that can include more than 15,000 entries.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import segments_beta_api
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
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 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 = segments_beta_api.SegmentsBetaApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
segment_key = "segmentKey_example" # str | The segment key
file = open('/path/to/file', 'rb') # file_type | CSV file containing keys (optional)
mode = "mode_example" # str | Import mode. Use either `merge` or `replace` (optional)
# example passing only required values which don't have defaults set
try:
# Create big segment import
api_instance.create_big_segment_import(project_key, environment_key, segment_key)
except launchdarkly_api.ApiException as e:
print("Exception when calling SegmentsBetaApi->create_big_segment_import: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Create big segment import
api_instance.create_big_segment_import(project_key, environment_key, segment_key, file=file, mode=mode)
except launchdarkly_api.ApiException as e:
print("Exception when calling SegmentsBetaApi->create_big_segment_import: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
segment_key | str | The segment key | |
file | file_type | CSV file containing keys | [optional] |
mode | str | Import mode. Use either `merge` or `replace` | [optional] |
void (empty response body)
- Content-Type: multipart/form-data
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
204 | Import request submitted successfully | - |
400 | Invalid request | - |
401 | Invalid access token | - |
404 | Invalid resource identifier | - |
409 | Conflicting process | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Export get_big_segment_export(project_key, environment_key, segment_key, export_id)
Get big segment export
Returns information about a big segment export process. This is an export for a synced segment or a list-based segment that can include more than 15,000 entries.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import segments_beta_api
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
from launchdarkly_api.model.not_found_error_rep import NotFoundErrorRep
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
from launchdarkly_api.model.export import Export
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 = segments_beta_api.SegmentsBetaApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
segment_key = "segmentKey_example" # str | The segment key
export_id = "exportID_example" # str | The export ID
# example passing only required values which don't have defaults set
try:
# Get big segment export
api_response = api_instance.get_big_segment_export(project_key, environment_key, segment_key, export_id)
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling SegmentsBetaApi->get_big_segment_export: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
segment_key | str | The segment key | |
export_id | str | The export ID |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Segment export response | - |
400 | Invalid request | - |
404 | Invalid resource identifier | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ModelImport get_big_segment_import(project_key, environment_key, segment_key, import_id)
Get big segment import
Returns information about a big segment import process. This is the import of a list-based segment that can include more than 15,000 entries.
- Api Key Authentication (ApiKey):
import time
import launchdarkly_api
from launchdarkly_api.api import segments_beta_api
from launchdarkly_api.model.invalid_request_error_rep import InvalidRequestErrorRep
from launchdarkly_api.model.not_found_error_rep import NotFoundErrorRep
from launchdarkly_api.model.model_import import ModelImport
from launchdarkly_api.model.rate_limited_error_rep import RateLimitedErrorRep
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 = segments_beta_api.SegmentsBetaApi(api_client)
project_key = "projectKey_example" # str | The project key
environment_key = "environmentKey_example" # str | The environment key
segment_key = "segmentKey_example" # str | The segment key
import_id = "importID_example" # str | The import ID
# example passing only required values which don't have defaults set
try:
# Get big segment import
api_response = api_instance.get_big_segment_import(project_key, environment_key, segment_key, import_id)
pprint(api_response)
except launchdarkly_api.ApiException as e:
print("Exception when calling SegmentsBetaApi->get_big_segment_import: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
project_key | str | The project key | |
environment_key | str | The environment key | |
segment_key | str | The segment key | |
import_id | str | The import ID |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Segment import response | - |
400 | Invalid request | - |
404 | Invalid resource identifier | - |
429 | Rate limited | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]