Control d

Learn how to use Control d with Composio

Overview

SLUG: CONTROL_D

Description

Control D is a customizable DNS filtering and traffic redirection platform that allows users to manage internet access, enforce policies, and monitor usage across devices and networks.

Authentication Details

generic_api_key
stringRequired

Connecting to Control d

Create an auth config

Use the dashboard to create an auth config for the Control d toolkit. This allows you to connect multiple Control d accounts to Composio for agents to use.

2

Configure Auth Config Settings

Select among the supported auth schemes of and configure them here.

3

Create and Get auth config ID

Click “Create Control d Auth Config”. After creation, copy the displayed ID starting with ac_. This is your auth config ID. This is not a sensitive ID — you can save it in environment variables or a database. This ID will be used to create connections to the toolkit for a given user.

Connect Your Account

Using API Key

1from composio import Composio
2
3# Replace these with your actual values
4control_d_auth_config_id = "ac_YOUR_CONTROL_D_CONFIG_ID" # Auth config ID created above
5user_id = "0000-0000-0000" # UUID from database/app
6
7composio = Composio()
8
9def authenticate_toolkit(user_id: str, auth_config_id: str):
10 # Replace this with a method to retrieve an API key from the user.
11 # Or supply your own.
12 user_api_key = input("[!] Enter API key")
13
14 connection_request = composio.connected_accounts.initiate(
15 user_id=user_id,
16 auth_config_id=auth_config_id,
17 config={"auth_scheme": "API_KEY", "val": {"generic_api_key": user_api_key}}
18 )
19
20 # API Key authentication is immediate - no redirect needed
21 print(f"Successfully connected Control d for user {user_id}")
22 print(f"Connection status: {connection_request.status}")
23
24 return connection_request.id
25
26
27connection_id = authenticate_toolkit(user_id, control_d_auth_config_id)
28
29# You can verify the connection using:
30connected_account = composio.connected_accounts.get(connection_id)
31print(f"Connected account: {connected_account}")

Tools

Executing tools

To prototype you can execute some tools to see the responses and working on the [Control d toolkit’s playground](https://app.composio.dev/app/Control d)

Python
1from composio import Composio
2from openai import OpenAI
3import json
4
5openai = OpenAI()
6composio = Composio()
7
8# User ID must be a valid UUID format
9user_id = "0000-0000-0000" # Replace with actual user UUID from your database
10
11tools = composio.tools.get(user_id=user_id, toolkits=["CONTROL_D"])
12
13print("[!] Tools:")
14print(json.dumps(tools))
15
16def invoke_llm(task = "What can you do?"):
17 completion = openai.chat.completions.create(
18 model="gpt-4o",
19 messages=[
20 {
21 "role": "user",
22 "content": task, # Your task here!
23 },
24 ],
25 tools=tools,
26 )
27
28 # Handle Result from tool call
29 result = composio.provider.handle_tool_calls(user_id=user_id, response=completion)
30 print(f"[!] Completion: {completion}")
31 print(f"[!] Tool call result: {result}")
32
33invoke_llm()

Tool List

Tool Name: Delete Device by ID

Description

Tool to delete a Control-D device. Use when you need to remove a device by its identifier after confirming the device_id.

Action Parameters

device_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Delete Profile by ID

Description

Tool to delete a profile. Use when you need to remove a profile by its ID after ensuring it is not enforced by any device.

Action Parameters

profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Delete Profile Rule by Hostname

Description

Tool to delete a specific custom rule by hostname from a profile. Use after confirming profile_id and hostname.

Action Parameters

hostname
stringRequired
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Delete Profile Rule by Rule ID

Description

Tool to delete a specific custom rule by its ID within a profile. Use after confirming profile_id and rule_id.

Action Parameters

profile_id
stringRequired
rule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Delete Profile Rule in Folder

Description

Tool to delete a specific custom rule within a folder. Use after confirming profile_id, rule_id, and folder_id.

Action Parameters

folder_id
stringRequired
profile_id
stringRequired
rule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Delete Profile Schedule

Description

Tool to delete a specific schedule within a profile. Use after confirming profile_id and schedule_id.

Action Parameters

profile_id
stringRequired
schedule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: List Known Access IPs

Description

Tool to list known IPs associated with the account. Use when you need to retrieve recent access IPs for device resolver queries.

Action Parameters

X-Force-Org-Id
string
device_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Analytics Endpoints

Description

Tool to list analytics storage regions and their endpoints. Use after authenticating to retrieve available analytics regions.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Devices

Description

Tool to list all devices associated with the account. Use when you need to retrieve device inventory after authentication.

Action Parameters

device_type
string
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Organization Details

Description

Tool to view the authenticated organization's details. Use after confirming a valid API token.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profiles

Description

Tool to list all profiles associated with the authenticated account. Use when you need an overview of accessible profiles.

Action Parameters

X-Force-Org-Id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Options

Description

Tool to get all available profile options. Use when you need to retrieve the possible configurations for profiles after authenticating.

Action Parameters

X-Force-Org-Id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile by ID

Description

Tool to retrieve details of a specific profile by its ID. Use when you need full profile details after confirming the profile_id.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Analytics

Description

Tool to retrieve analytics data for a specific profile. Use after the profile has accrued usage data to fetch analytics.

Action Parameters

profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Analytics Logs

Description

Tool to list analytics log entries for a given profile. Use after confirming profile ID and optional date filters to fetch logs.

Action Parameters

X-Force-Org-Id
string
from_date
string
profile_id
stringRequired
to_date
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Analytics Log Entry

Description

Tool to retrieve a specific analytics log entry by its ID. Use when you need details of an analytics log for a given profile.

Action Parameters

X-Force-Org-Id
string
log_id
stringRequired
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Analytics Summary

Description

Tool to fetch a summary of analytics data for a given profile. Use after confirming profile ID and desired date range.

Action Parameters

from_date
string
profile_id
stringRequired
to_date
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Analytics Top Domains

Description

Tool to fetch top domains accessed within a specific profile. Use after confirming profile ID.

Action Parameters

from_date
string
profile_id
stringRequired
to_date
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Top Services

Description

Tool to fetch top services accessed within a profile. Use after confirming the profile ID and desired date range.

Action Parameters

from_date
string
profile_id
stringRequired
to_date
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Filters

Description

Tool to list native filters associated with a specific profile. Use when you have a profile ID and need to retrieve its filters and their states.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: List External Filters for Profile

Description

Tool to list third-party filters for a specific profile. Use when you need to retrieve all external filters and their states after confirming the profile ID.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Folders

Description

Tool to list rule folders (groups) within a profile. Use when you need to retrieve all folders for a given profile after confirming the profile ID.

Action Parameters

profile_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: List Custom Rules for Profile

Description

Tool to retrieve custom rules associated with a specific profile. Use after confirming the profile ID. Omit `folder_id` to list rules in the root folder.

Action Parameters

X-Force-Org-Id
string
folder_id
string
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: List Custom Rules in Folder

Description

Tool to retrieve custom rules in a specific folder of a profile. Use after confirming both profile ID and folder ID.

Action Parameters

X-Force-Org-Id
string
folder_id
stringRequired
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Custom Rule by Rule ID

Description

Tool to retrieve details of a specific custom rule by its ID. Use after confirming the profile_id and rule_id to fetch that rule's metadata.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
rule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Specific Rule in Folder

Description

Tool to retrieve a specific rule within a folder by its ID. Use when you need full details of a custom rule in a profile's folder.

Action Parameters

X-Force-Org-Id
string
folder_id
stringRequired
profile_id
stringRequired
rule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Schedules

Description

Tool to list schedules associated with a specific profile. Use after confirming the profile ID.

Action Parameters

profile_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Schedule

Description

Tool to retrieve a specific schedule by its ID within a profile. Use when you need details of a profile schedule after confirming the profile_id and schedule_id.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
schedule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Profile Services

Description

Tool to list services associated with a specific profile. Use when you need to retrieve all services that have any associated rules after confirming the profile ID.

Action Parameters

profile_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Service Categories

Description

Tool to list all service categories. Use when you need to retrieve available categories before filtering or assigning services.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: List Services by Category

Description

Tool to list all services within a specific category. Use after confirming a valid category identifier.

Action Parameters

category
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Get Users

Description

Tool to retrieve user account data. Use when you need account details after authentication.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Create Device

Description

Tool to create a new device. Use when you need to provision devices and retrieve their DNS resolvers.

Action Parameters

body
objectRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Create Profile

Description

Tool to create a new blank profile or clone an existing one. Use when you need to provision a profile before assigning rules or devices.

Action Parameters

X-Force-Org-Id
string
profile
objectRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Create Custom Rules for Profile

Description

Tool to create custom rules for a profile. Use after confirming the profile ID and preparing rule definitions. Provide a list of rule objects matching the API schema.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
rules
arrayRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Create Custom Rules in Profile Folder

Description

Tool to create custom rules within a specific folder for a profile. Use after confirming the profile and folder IDs and preparing rule definitions.

Action Parameters

X-Force-Org-Id
string
folder_id
stringRequired
profile_id
stringRequired
rules
arrayRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Create Profile Schedule

Description

Tool to create a new schedule within a specific profile. Use after gathering profile_id and schedule details.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
schedule
objectRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Modify Device

Description

Tool to modify an existing device. Use when you need to update device settings by providing its ID.

Action Parameters

body
objectRequired
device_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Modify Organization

Description

Tool to modify organization settings and limits. Use when you need to change organization limits such as max_users or max_routers. Changing these fields is a billable event.

Action Parameters

X-Force-Org-Id
string
max_routers
integer
max_users
integer

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Update Profile by ID

Description

Tool to modify an existing profile by ID. Use when you need to update profile fields after confirming the current profile. Example: Update profile '123abc' with new name and settings.

Action Parameters

X-Force-Org-Id
string
profile
objectRequired
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Bulk Update Profile Filters

Description

Tool to bulk update filters on a specific profile. Use when you need to enable or disable multiple filters at once. Provide a list of filter IDs with desired states.

Action Parameters

filters
arrayRequired
profile_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Update External Filters for Profile

Description

Tool to update external filters for a specific profile. Use when toggling third-party filters after listing them.

Action Parameters

X-Force-Org-Id
string
filters
arrayRequired
profile_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Modify Profile Filter

Description

Tool to modify the enabled state of a specific filter on a profile. Use when you need to enable or disable a particular filter.

Action Parameters

enabled
booleanRequired
filter
stringRequired
profile_id
stringRequired
x_force_org_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Modify Custom Rules for Profile

Description

Tool to modify existing custom rule(s) for a profile. Use when you need to update rule details such as name, description, severity, or enabled status. Ensure to include the rule IDs to modify.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
rules
arrayRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Update Custom Rule by Rule ID

Description

Tool to update an existing custom rule by its ID. Use when modifying details like name, description, severity, or enabled status for a specific rule.

Action Parameters

X-Force-Org-Id
string
description
string
enabled
boolean
name
string
profile_id
stringRequired
rule_id
stringRequired
severity
integer

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Move Profile Rule to Folder

Description

Tool to move a specific custom rule into a different folder. Use after confirming profile_id, rule_id, and folder_id.

Action Parameters

folder_id
stringRequired
profile_id
stringRequired
rule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Update Profile Schedule

Description

Tool to update a specific schedule within a profile. Use when you need to modify schedule details after confirming profile_id and schedule_id.

Action Parameters

X-Force-Org-Id
string
profile_id
stringRequired
schedule
objectRequired
schedule_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

Tool Name: Modify Service for Profile

Description

Tool to modify a specific service rule for a profile. Use when you need to update blocking, bypassing, spoofing, or proxy-redirect settings after reviewing existing rules.

Action Parameters

do
integerRequired
profile_id
stringRequired
service
stringRequired
status
integerRequired
via
string
via_v6
string

Action Response

data
objectRequired
error
string
successful
booleanRequired