Generative AIAI tools for developersClaude Code

Getting started with Claude Code

2 minutes read

Today, there is a diverse ecosystem of AI-powered coding assistants available. Each assistant has unique strengths, and developers can select the ones that best fit their specific tasks and workflows. Integrating the right one can significantly enhance productivity for specialized development challenges.

In this topic, we'll focus on Anthropic's Claude Code. We will cover what it is, how it works, and how you can integrate it safely into your existing development workflow.

What is Claude Code?

Claude Code is an agentic coding assistant from Anthropic that goes beyond autocomplete. It understands your project's structure and can:

  • Generate or refactor code across multiple files.

  • Provide context-aware answers.

  • Perform routine development tasks, including running tests and working with Git.

  • Connect with external systems.

It runs as a command-line tool and also integrates directly into IDEs through a plugin. In more advanced setups, you can integrate it into your CI/CD pipelines or use the Claude Code SDK directly for programmatic access.

When you give Claude Code a task—such as fixing a bug or adding a feature—it follows a process similar to how developers work:

  1. Gather context — it identifies relevant files, error messages, key considerations, documentation, and other key information.

  2. Formulate a plan — decide on the approach based on the data at hand.

  3. Take action — apply changes, run commands, or provide feedback.

Claude, the LLM powering Claude Code, doesn't directly read files or run commands. Instead, it uses tools: a system where the LLM reasons about tasks and requests actions in a structured way. The assistant then executes these tasks.

This design lets Claude effectively "read files," "run commands," and "write code" safely while keeping you in control. It allows the assistant to handle complex multi-step tasks and integrate new tools effectively.

Installing Claude Code

You can install Claude Code for different OSes using these commands:

curl -fsSL https://claude.ai/install.sh | bash
irm https://claude.ai/install.ps1 | iex
curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd
brew install --cask claude-code
npm install -g @anthropic-ai/claude-code

This setup requires Node.js 18+.

After installation, verify everything works with:

$ claude doctor

 Diagnostics
 └ Currently running: native (2.0.37)
 └ Path: ~/.local/bin/claude
 └ Invoked: ~/.local/bin/claude
 └ Config install method: native
 └ Auto-updates: default (true)
 └ Search: OK (bundled)

You can launch Claude Code with:

claude

On the first run, Claude Code will prompt you to log in. You can use:

The payment option you choose depends on how much you plan to use Claude Code. For heavy, frequent use, the subscription plan is more cost-effective. For experimentation or occasional use, API credits (with budget limits set up) would be a better option.

Once logged in, you're ready to start using Claude Code. You will primarily work via the terminal, but IDEs like VS Code and JetBrains IDEs also have plugins for seamless integration. The plugin makes it easier to launch Claude Code, share context, and preview diffs in your projects.

Configuring Claude Code

You can configure Claude Code's behavior by running the /config command from the interactive REPL. Here, you can modify settings like the default model, theme, output style, editor mode, and others:

Settings available via /config

Settings are stored in settings.json files. You can further customize these files to control permissions, set environment variables, and customize tool behavior. Claude Code applies settings hierarchically, allowing for global defaults and project-specific overrides. You can also override settings using CLI arguments. For example, to override the set permission mode for a session, you can start Claude Code with --permission-mode acceptEdits. There are different scopes for settings files (in order of precedence):

  • managed-settings.json — enterprise-managed policy settings.

  • .claude/settings.local.json — personal project settings, which you don't share with others.

  • .claude/settings.json — project-level settings that you share with your team via source control.

  • ~/.claude/settings.json — personal preferences and settings that apply to all your projects.

For enterprise deployments, managed-settings.json allows admins to enforce organization-wide settings/limitations, like which commands are allowed for every developer in the organization.

A closer look at settings.json

As noted earlier, you can manage various aspects of Claude Code's operation with settings.json. A key use case is managing permissions, which control what actions Claude Code can take on your system. Let's look at an example:

{
  "permissions": {
    "allow": [
      "Bash(git commit:*)"
    ],
    "ask": [
      "Bash(git push:*)"
    ],
    "deny": [
      "Read(./.env)"
    ]
  },
}

Here, we ensure that:

  • Allgit commit operations can be performed.

  • Claude Code asks for confirmation before pushing to any branch.

  • Claude Code cannot read .env files containing potentially sensitive information.

You can apply many more settings similarly using different keys. Here are some examples:

Option

Description

Example

model

Override the default Claude model.

"claude-sonnet-4-5-20250929"

cleanupPeriodDays

How long to keep local chat history (default: 30 days).

5

env

Environment variables for all sessions.

{"MCP_TIMEOUT": "10"}

allowedMcpServers

Allowlist of permitted MCP servers.

[{"serverName": "slack"}]

deniedMcpServers

Deny list of MCP servers that are explicitly blocked.

[{ "serverName": "notionMCP" }]

outputStyle

Adjusts how Claude formats or phrases responses.

"Explanatory"

disableAllHooks

Disable all hooks

false

Complete settings.json file
{
  "model": "claude-sonnet-4-5-20250929",
  "cleanupPeriodDays": 5,
  "env": {
    "MCP_TIMEOUT": "10"
  },
  "allowedMcpServers": [
    { "serverName": "slack" }
  ],
  "outputStyle": "Explanatory",
  "disableAllHooks": false,

  "permissions": {
    "allow": [
      "Bash(git commit:*)"
    ],
    "ask": [
      "Bash(git push:*)"
    ],
    "deny": [
      "Read(./.env)",
      "Read(./.env.*)",
      "Read(./secrets/**)",
      "Read(./config/credentials.json)"
    ]
  }
}

You can apply many more configurations to Claude Code to customize its behavior. You can view all of them in the documentation.

Conclusion

In this topic, we introduced you to Claude Code, an agentic coding assistant that integrates directly into your development workflow. You've learned the essential first steps, from installing the command-line tool to performing the initial login. You learned how it operates by gathering context, creating a plan, and using a secure tool-based system to execute tasks.

We also covered how to configure Claude Code's behavior using settings.json files to manage permissions and tool settings safely. Mastering these configurations enhances your productivity while ensuring that Claude Code operates securely within your development environment

How did you like the theory?
Report a typo