{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"CLI","description":"The developer documentation portal and API reference for Unstoppable Domains.","siteUrl":"https://docs.unstoppabledomains.com","keywords":"unstoppable domains developer portal, api reference docs","lang":"en-US","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"cli","__idx":0},"children":["CLI"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The Unstoppable Domains CLI (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ud"]},") gives you command-line access to the ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/user-api/overview"},"children":["User API"]},". Search for domains, manage DNS, interact with the marketplace, and complete purchases — all from your terminal."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"installation","__idx":1},"children":["Installation"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"macos--linux","__idx":2},"children":["macOS / Linux"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"curl -fsSL https://raw.githubusercontent.com/unstoppabledomains/ud-cli/main/install.sh | sh\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"npm","__idx":3},"children":["npm"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npm install -g @unstoppabledomains/ud-cli\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"build-from-source","__idx":4},"children":["Build from Source"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"git clone https://github.com/unstoppabledomains/ud-cli.git\ncd ud-cli\nnpm install\nnpm run build\nnpm install -g .\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["After installation, verify it works:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud --help\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"authentication","__idx":5},"children":["Authentication"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"signup-new-account","__idx":6},"children":["Signup (New Account)"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud auth signup\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Creates a new account directly from the terminal. Prompts for email and password, sends a verification code to your email, and signs you in — no browser needed."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For scripting or headless environments, pass credentials as flags:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"# Step 1: Create account (outputs the verify command to stdout)\nud auth signup --email user@example.com --password 'SecurePass1!'\n\n# Step 2: Verify with the code from your email\nud auth signup --token <session_token> --code ABC123\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"oauth-existing-account","__idx":7},"children":["OAuth (Existing Account)"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud auth login\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Opens your browser for authorization using OAuth 2.0 with PKCE. Use this to sign in to an existing account. Tokens refresh automatically."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"api-key","__idx":8},"children":["API Key"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud auth login --key ud_mcp_<your-key>\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Generate an API key from ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"https://unstoppabledomains.com/account/settings?tab=advanced"},"children":["Account Settings"]}," under the \"Advanced\" tab."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"managing-credentials","__idx":9},"children":["Managing Credentials"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud auth status   # Check authentication status\nud auth logout   # Clear stored credentials\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Credentials are stored in your system keychain (macOS Keychain, Windows Credential Vault, or Linux Secret Service). If the keychain is unavailable, credentials fall back to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["~/.ud-cli/credentials-{env}.json"]}," with restricted permissions."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"quick-example","__idx":10},"children":["Quick Example"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"# Search for available domains\nud search \"mybusiness\"\n\n# List your domains\nud domains list\n\n# Check DNS records\nud domains dns records show example.com\n\n# Add a domain to your cart and checkout\nud cart add registration example.com\nud cart checkout\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"global-options","__idx":11},"children":["Global Options"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Every command accepts these flags:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Flag"},"children":["Flag"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--format <format>"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Output as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["table"]}," (default), ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["json"]},", or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["csv"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fields [columns]"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Display specific columns (comma-separated)"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--env <environment>"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Override active environment (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["production"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sandbox"]},")"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--quiet"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Suppress output except errors"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--verbose"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Show detailed output"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"output-customization","__idx":12},"children":["Output Customization"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"choosing-a-format","__idx":13},"children":["Choosing a Format"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"# Default table output\nud domains list\n\n# JSON for scripting\nud domains list --format json\n\n# CSV for spreadsheets\nud domains list --format csv\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"selecting-fields","__idx":14},"children":["Selecting Fields"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Show only the columns you need:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud domains list --fields name,expiresAt,offersCount\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Use dot notation for nested properties:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud domains list --fields name,listing.price,autoRenewal.status\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Run ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fields"]}," with no value to see all available columns for a command:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud domains list --fields\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"piping-json","__idx":15},"children":["Piping JSON"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Combine with tools like ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jq"]}," for scripting workflows:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud domains list --format json | jq '.[].name'\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"saving-defaults","__idx":16},"children":["Saving Defaults"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Save frequently used options so you don't have to type them every time:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"# Save default fields for 'domains list'\nud config set \"domains list\" fields name,expiresAt,offersCount\n\n# Save JSON as default format\nud config set \"domains list\" format json\n\n# View saved defaults\nud config get \"domains list\"\n\n# Reset a saved default\nud config reset \"domains list\" fields\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["CLI flags always override saved defaults."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"environments","__idx":17},"children":["Environments"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Two environments are available:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Environment"},"children":["Environment"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"API Base URL"},"children":["API Base URL"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["production"]}," (default)"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://api.unstoppabledomains.com"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sandbox"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://api.ud-sandbox.com"]}]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Switch environments:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"# Set the active environment\nud env set sandbox\n\n# Check current environment\nud env show\n\n# Override per-command\nud search \"test\" --env sandbox\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Credentials are stored separately per environment, so you can authenticate in both simultaneously."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"auto-updates","__idx":18},"children":["Auto-Updates"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The CLI checks for updates every 24 hours. You can also check and update manually:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud update check   # Check for available updates\nud update         # Update to the latest version\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"shell-completion","__idx":19},"children":["Shell Completion"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Generate shell completions for your shell:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"ud completion\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"whats-next","__idx":20},"children":["What's Next"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/user-api/cli-commands"},"children":["Command Reference"]}," — Full list of all commands, flags, and examples"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/user-api/cli-workflows"},"children":["Common Workflows"]}," — Step-by-step guides for common tasks"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"a","attributes":{"href":"/apis/user-api/openapi"},"children":["API Reference"]}," — The underlying REST API"]}]}]},"headings":[{"value":"CLI","id":"cli","depth":1},{"value":"Installation","id":"installation","depth":2},{"value":"macOS / Linux","id":"macos--linux","depth":3},{"value":"npm","id":"npm","depth":3},{"value":"Build from Source","id":"build-from-source","depth":3},{"value":"Authentication","id":"authentication","depth":2},{"value":"Signup (New Account)","id":"signup-new-account","depth":3},{"value":"OAuth (Existing Account)","id":"oauth-existing-account","depth":3},{"value":"API Key","id":"api-key","depth":3},{"value":"Managing Credentials","id":"managing-credentials","depth":3},{"value":"Quick Example","id":"quick-example","depth":2},{"value":"Global Options","id":"global-options","depth":2},{"value":"Output Customization","id":"output-customization","depth":2},{"value":"Choosing a Format","id":"choosing-a-format","depth":3},{"value":"Selecting Fields","id":"selecting-fields","depth":3},{"value":"Piping JSON","id":"piping-json","depth":3},{"value":"Saving Defaults","id":"saving-defaults","depth":2},{"value":"Environments","id":"environments","depth":2},{"value":"Auto-Updates","id":"auto-updates","depth":2},{"value":"Shell Completion","id":"shell-completion","depth":2},{"value":"What's Next","id":"whats-next","depth":2}],"frontmatter":{"title":"CLI | Unstoppable Domains Developer Portal","description":"Install and use the Unstoppable Domains CLI to search, register, and manage domains from your terminal.","seo":{"title":"CLI"}},"editPage":{"to":"https://github.com/unstoppabledomains/dev-docs/blob/main/user-api/cli.md"},"lastModified":"2026-03-06T04:10:41.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/user-api/cli","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}