productivity
Dub CLI for AI Agents
Use the Dub CLI from KosmoKrator to call Dub tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.Dub CLI Setup
Dub can be configured headlessly with `kosmokrator integrations:configure dub`.
# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash
# Configure and verify this integration.
kosmokrator integrations:configure dub --set access_token="$DUB_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmokrator integrations:doctor dub --json
kosmokrator integrations:status --json Credentials
Authentication type: Bearer token bearer_token. Configure credentials once, then reuse the same stored profile from scripts, coding CLIs, Lua, and MCP.
| Key | Env var | Type | Required | Label |
|---|---|---|---|---|
access_token | DUB_ACCESS_TOKEN | Secret secret | yes | Access Token |
base_url | DUB_BASE_URL | URL url | no | Base URL |
Command Patterns
The generic command is stable across every integration. The provider shortcut is shorter for humans.
kosmo integrations:call dub.dub_analytics_retrieve '{}' --json kosmo integrations:dub dub_analytics_retrieve '{}' --json Discovery
These commands return structured output for coding agents that need to inspect capabilities before choosing a function.
kosmo integrations:docs dub --json
kosmo integrations:docs dub.dub_analytics_retrieve --json
kosmo integrations:schema dub.dub_analytics_retrieve --json
kosmo integrations:search "Dub" --json
kosmo integrations:list --json Automation Contexts
The same configured command surface works in these environments. The command does not change unless the host wrapper, credentials, or permissions change.
CLI Functions
Every function below can be called headlessly. Commands are highlighted, copyable, and scroll horizontally when payloads are long.
dub.dub_analytics_retrieve
Retrieve analytics for a link, a domain, or the authenticated workspace.
read - Parameters
- none
kosmo integrations:call dub.dub_analytics_retrieve '{}' --json kosmo integrations:dub dub_analytics_retrieve '{}' --json dub.dub_bounties_approve_submission
Approve a bounty submission
write - Parameters
- none
kosmo integrations:call dub.dub_bounties_approve_submission '{}' --json kosmo integrations:dub dub_bounties_approve_submission '{}' --json dub.dub_bounties_list_submissions
List bounty submissions
read - Parameters
- none
kosmo integrations:call dub.dub_bounties_list_submissions '{}' --json kosmo integrations:dub dub_bounties_list_submissions '{}' --json dub.dub_bounties_reject_submission
Reject a bounty submission
write - Parameters
- none
kosmo integrations:call dub.dub_bounties_reject_submission '{}' --json kosmo integrations:dub dub_bounties_reject_submission '{}' --json dub.dub_commissions_list
List all commissions
read - Parameters
- none
kosmo integrations:call dub.dub_commissions_list '{}' --json kosmo integrations:dub dub_commissions_list '{}' --json dub.dub_commissions_update
Update a commission
write - Parameters
- none
kosmo integrations:call dub.dub_commissions_update '{}' --json kosmo integrations:dub dub_commissions_update '{}' --json dub.dub_commissions_update_many
Bulk update commissions
write - Parameters
- none
kosmo integrations:call dub.dub_commissions_update_many '{}' --json kosmo integrations:dub dub_commissions_update_many '{}' --json dub.dub_customers_delete
Delete a customer
write - Parameters
- none
kosmo integrations:call dub.dub_customers_delete '{}' --json kosmo integrations:dub dub_customers_delete '{}' --json dub.dub_customers_get
Retrieve a customer
read - Parameters
- none
kosmo integrations:call dub.dub_customers_get '{}' --json kosmo integrations:dub dub_customers_get '{}' --json dub.dub_customers_list
List all customers
read - Parameters
- none
kosmo integrations:call dub.dub_customers_list '{}' --json kosmo integrations:dub dub_customers_list '{}' --json dub.dub_customers_update
Update a customer
write - Parameters
- none
kosmo integrations:call dub.dub_customers_update '{}' --json kosmo integrations:dub dub_customers_update '{}' --json dub.dub_domains_check_status
Check the availability of one or more domains
read - Parameters
- none
kosmo integrations:call dub.dub_domains_check_status '{}' --json kosmo integrations:dub dub_domains_check_status '{}' --json dub.dub_domains_create
Create a domain
write - Parameters
- none
kosmo integrations:call dub.dub_domains_create '{}' --json kosmo integrations:dub dub_domains_create '{}' --json dub.dub_domains_delete
Delete a domain
write - Parameters
- none
kosmo integrations:call dub.dub_domains_delete '{}' --json kosmo integrations:dub dub_domains_delete '{}' --json dub.dub_domains_list
List all domains
read - Parameters
- none
kosmo integrations:call dub.dub_domains_list '{}' --json kosmo integrations:dub dub_domains_list '{}' --json dub.dub_domains_register
Register a domain
write - Parameters
- none
kosmo integrations:call dub.dub_domains_register '{}' --json kosmo integrations:dub dub_domains_register '{}' --json dub.dub_domains_update
Update a domain
write - Parameters
- none
kosmo integrations:call dub.dub_domains_update '{}' --json kosmo integrations:dub dub_domains_update '{}' --json dub.dub_embed_tokens_referrals
Create a referrals embed token
write - Parameters
- none
kosmo integrations:call dub.dub_embed_tokens_referrals '{}' --json kosmo integrations:dub dub_embed_tokens_referrals '{}' --json dub.dub_events_list
List all events
read - Parameters
- none
kosmo integrations:call dub.dub_events_list '{}' --json kosmo integrations:dub dub_events_list '{}' --json dub.dub_folders_create
Create a folder
write - Parameters
- none
kosmo integrations:call dub.dub_folders_create '{}' --json kosmo integrations:dub dub_folders_create '{}' --json dub.dub_folders_delete
Delete a folder
write - Parameters
- none
kosmo integrations:call dub.dub_folders_delete '{}' --json kosmo integrations:dub dub_folders_delete '{}' --json dub.dub_folders_list
List all folders
read - Parameters
- none
kosmo integrations:call dub.dub_folders_list '{}' --json kosmo integrations:dub dub_folders_list '{}' --json dub.dub_folders_update
Update a folder
write - Parameters
- none
kosmo integrations:call dub.dub_folders_update '{}' --json kosmo integrations:dub dub_folders_update '{}' --json dub.dub_links_count
Retrieve links count
read - Parameters
- none
kosmo integrations:call dub.dub_links_count '{}' --json kosmo integrations:dub dub_links_count '{}' --json dub.dub_links_create
Create a link
write - Parameters
- none
kosmo integrations:call dub.dub_links_create '{}' --json kosmo integrations:dub dub_links_create '{}' --json dub.dub_links_create_many
Bulk create links
write - Parameters
- none
kosmo integrations:call dub.dub_links_create_many '{}' --json kosmo integrations:dub dub_links_create_many '{}' --json dub.dub_links_delete
Delete a link
write - Parameters
- none
kosmo integrations:call dub.dub_links_delete '{}' --json kosmo integrations:dub dub_links_delete '{}' --json dub.dub_links_delete_many
Bulk delete links
write - Parameters
- none
kosmo integrations:call dub.dub_links_delete_many '{}' --json kosmo integrations:dub dub_links_delete_many '{}' --json dub.dub_links_get
Retrieve a link
read - Parameters
- none
kosmo integrations:call dub.dub_links_get '{}' --json kosmo integrations:dub dub_links_get '{}' --json dub.dub_links_list
List all links
read - Parameters
- none
kosmo integrations:call dub.dub_links_list '{}' --json kosmo integrations:dub dub_links_list '{}' --json dub.dub_links_update
Update a link
write - Parameters
- none
kosmo integrations:call dub.dub_links_update '{}' --json kosmo integrations:dub dub_links_update '{}' --json dub.dub_links_update_many
Bulk update links
write - Parameters
- none
kosmo integrations:call dub.dub_links_update_many '{}' --json kosmo integrations:dub dub_links_update_many '{}' --json dub.dub_links_upsert
Upsert a link
write - Parameters
- none
kosmo integrations:call dub.dub_links_upsert '{}' --json kosmo integrations:dub dub_links_upsert '{}' --json dub.dub_partner_applications_approve
Approve a partner application
write - Parameters
- none
kosmo integrations:call dub.dub_partner_applications_approve '{}' --json kosmo integrations:dub dub_partner_applications_approve '{}' --json dub.dub_partner_applications_list
List all pending partner applications
read - Parameters
- none
kosmo integrations:call dub.dub_partner_applications_list '{}' --json kosmo integrations:dub dub_partner_applications_list '{}' --json dub.dub_partner_applications_reject
Reject a partner application
write - Parameters
- none
kosmo integrations:call dub.dub_partner_applications_reject '{}' --json kosmo integrations:dub dub_partner_applications_reject '{}' --json dub.dub_partners_analytics
Retrieve analytics for a partner
read - Parameters
- none
kosmo integrations:call dub.dub_partners_analytics '{}' --json kosmo integrations:dub dub_partners_analytics '{}' --json dub.dub_partners_ban
Ban a partner
write - Parameters
- none
kosmo integrations:call dub.dub_partners_ban '{}' --json kosmo integrations:dub dub_partners_ban '{}' --json dub.dub_partners_create
Create or update a partner
write - Parameters
- none
kosmo integrations:call dub.dub_partners_create '{}' --json kosmo integrations:dub dub_partners_create '{}' --json dub.dub_partners_create_link
Create a link for a partner
write - Parameters
- none
kosmo integrations:call dub.dub_partners_create_link '{}' --json kosmo integrations:dub dub_partners_create_link '{}' --json dub.dub_partners_deactivate
Deactivate a partner
write - Parameters
- none
kosmo integrations:call dub.dub_partners_deactivate '{}' --json kosmo integrations:dub dub_partners_deactivate '{}' --json dub.dub_partners_list
List all partners
read - Parameters
- none
kosmo integrations:call dub.dub_partners_list '{}' --json kosmo integrations:dub dub_partners_list '{}' --json dub.dub_partners_retrieve_links
Retrieve a partner's links.
read - Parameters
- none
kosmo integrations:call dub.dub_partners_retrieve_links '{}' --json kosmo integrations:dub dub_partners_retrieve_links '{}' --json dub.dub_partners_upsert_link
Upsert a link for a partner
write - Parameters
- none
kosmo integrations:call dub.dub_partners_upsert_link '{}' --json kosmo integrations:dub dub_partners_upsert_link '{}' --json dub.dub_payouts_list
List all payouts
read - Parameters
- none
kosmo integrations:call dub.dub_payouts_list '{}' --json kosmo integrations:dub dub_payouts_list '{}' --json dub.dub_qr_codes_get
Retrieve a QR code
read - Parameters
- none
kosmo integrations:call dub.dub_qr_codes_get '{}' --json kosmo integrations:dub dub_qr_codes_get '{}' --json dub.dub_tags_create
Create a tag
write - Parameters
- none
kosmo integrations:call dub.dub_tags_create '{}' --json kosmo integrations:dub dub_tags_create '{}' --json dub.dub_tags_delete
Delete a tag
write - Parameters
- none
kosmo integrations:call dub.dub_tags_delete '{}' --json kosmo integrations:dub dub_tags_delete '{}' --json dub.dub_tags_list
List all tags
read - Parameters
- none
kosmo integrations:call dub.dub_tags_list '{}' --json kosmo integrations:dub dub_tags_list '{}' --json dub.dub_tags_update
Update a tag
write - Parameters
- none
kosmo integrations:call dub.dub_tags_update '{}' --json kosmo integrations:dub dub_tags_update '{}' --json dub.dub_track_lead
Track a lead
write - Parameters
- none
kosmo integrations:call dub.dub_track_lead '{}' --json kosmo integrations:dub dub_track_lead '{}' --json dub.dub_track_sale
Track a sale
write - Parameters
- none
kosmo integrations:call dub.dub_track_sale '{}' --json kosmo integrations:dub dub_track_sale '{}' --json Function Schemas
Use these parameter tables when building CLI payloads without calling integrations:schema first.
dub.dub_analytics_retrieve 0 parameters
kosmo integrations:schema dub.dub_analytics_retrieve --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_bounties_approve_submission 0 parameters
kosmo integrations:schema dub.dub_bounties_approve_submission --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_bounties_list_submissions 0 parameters
kosmo integrations:schema dub.dub_bounties_list_submissions --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_bounties_reject_submission 0 parameters
kosmo integrations:schema dub.dub_bounties_reject_submission --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_commissions_list 0 parameters
kosmo integrations:schema dub.dub_commissions_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_commissions_update 0 parameters
kosmo integrations:schema dub.dub_commissions_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_commissions_update_many 0 parameters
kosmo integrations:schema dub.dub_commissions_update_many --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_customers_delete 0 parameters
kosmo integrations:schema dub.dub_customers_delete --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_customers_get 0 parameters
kosmo integrations:schema dub.dub_customers_get --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_customers_list 0 parameters
kosmo integrations:schema dub.dub_customers_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_customers_update 0 parameters
kosmo integrations:schema dub.dub_customers_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_check_status 0 parameters
kosmo integrations:schema dub.dub_domains_check_status --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_create 0 parameters
kosmo integrations:schema dub.dub_domains_create --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_delete 0 parameters
kosmo integrations:schema dub.dub_domains_delete --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_list 0 parameters
kosmo integrations:schema dub.dub_domains_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_register 0 parameters
kosmo integrations:schema dub.dub_domains_register --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_domains_update 0 parameters
kosmo integrations:schema dub.dub_domains_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_embed_tokens_referrals 0 parameters
kosmo integrations:schema dub.dub_embed_tokens_referrals --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_events_list 0 parameters
kosmo integrations:schema dub.dub_events_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_folders_create 0 parameters
kosmo integrations:schema dub.dub_folders_create --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_folders_delete 0 parameters
kosmo integrations:schema dub.dub_folders_delete --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_folders_list 0 parameters
kosmo integrations:schema dub.dub_folders_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_folders_update 0 parameters
kosmo integrations:schema dub.dub_folders_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_count 0 parameters
kosmo integrations:schema dub.dub_links_count --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_create 0 parameters
kosmo integrations:schema dub.dub_links_create --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_create_many 0 parameters
kosmo integrations:schema dub.dub_links_create_many --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_delete 0 parameters
kosmo integrations:schema dub.dub_links_delete --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_delete_many 0 parameters
kosmo integrations:schema dub.dub_links_delete_many --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_get 0 parameters
kosmo integrations:schema dub.dub_links_get --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_list 0 parameters
kosmo integrations:schema dub.dub_links_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_update 0 parameters
kosmo integrations:schema dub.dub_links_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_update_many 0 parameters
kosmo integrations:schema dub.dub_links_update_many --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_links_upsert 0 parameters
kosmo integrations:schema dub.dub_links_upsert --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partner_applications_approve 0 parameters
kosmo integrations:schema dub.dub_partner_applications_approve --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partner_applications_list 0 parameters
kosmo integrations:schema dub.dub_partner_applications_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partner_applications_reject 0 parameters
kosmo integrations:schema dub.dub_partner_applications_reject --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_analytics 0 parameters
kosmo integrations:schema dub.dub_partners_analytics --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_ban 0 parameters
kosmo integrations:schema dub.dub_partners_ban --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_create 0 parameters
kosmo integrations:schema dub.dub_partners_create --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_create_link 0 parameters
kosmo integrations:schema dub.dub_partners_create_link --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_deactivate 0 parameters
kosmo integrations:schema dub.dub_partners_deactivate --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_list 0 parameters
kosmo integrations:schema dub.dub_partners_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_retrieve_links 0 parameters
kosmo integrations:schema dub.dub_partners_retrieve_links --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_partners_upsert_link 0 parameters
kosmo integrations:schema dub.dub_partners_upsert_link --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_payouts_list 0 parameters
kosmo integrations:schema dub.dub_payouts_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_qr_codes_get 0 parameters
kosmo integrations:schema dub.dub_qr_codes_get --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_tags_create 0 parameters
kosmo integrations:schema dub.dub_tags_create --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_tags_delete 0 parameters
kosmo integrations:schema dub.dub_tags_delete --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_tags_list 0 parameters
kosmo integrations:schema dub.dub_tags_list --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_tags_update 0 parameters
kosmo integrations:schema dub.dub_tags_update --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_track_lead 0 parameters
kosmo integrations:schema dub.dub_track_lead --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
dub.dub_track_sale 0 parameters
kosmo integrations:schema dub.dub_track_sale --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
Permissions
Headless calls still follow the integration read/write permission policy. Configure read/write defaults with
integrations:configure. Add --force only for trusted automation that should bypass that policy.