> **Building with AI coding agents?** If you're using an AI coding agent, install the official Scalekit plugin. It gives your agent full awareness of the Scalekit API — reducing hallucinations and enabling faster, more accurate code generation.
>
> - **Claude Code**: `/plugin marketplace add scalekit-inc/claude-code-authstack` then `/plugin install <auth-type>@scalekit-auth-stack`
> - **GitHub Copilot CLI**: `copilot plugin marketplace add scalekit-inc/github-copilot-authstack` then `copilot plugin install <auth-type>@scalekit-auth-stack`
> - **Codex**: run the bash installer, restart, then open Plugin Directory and enable `<auth-type>`
> - **Skills CLI** (Windsurf, Cline, 40+ agents): `npx skills add scalekit-inc/skills --list` then `--skill <skill-name>`
>
> `<auth-type>` / `<skill-name>`: `agentkit`, `full-stack-auth`, `mcp-auth`, `modular-sso`, `modular-scim` — [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Set up environment & SDK

Create your account, install SDK, set up AI tools, and verify your setup to start building with Scalekit
This guide shows you how to set up Scalekit in your development environment. You'll configure your workspace, get API credentials, install the SDK, verify everything works correctly, and optionally set up AI-powered development tools.

Before you begin, create a Scalekit account if you haven't already. After creating your account, a Scalekit workspace is automatically set up for you with dedicated development and production environments.

Create a Scalekit account

<br />
<br />

1. ## Get your API credentials

   Scalekit uses the OAuth 2.0 client credentials flow for secure API authentication.

   Navigate to **Dashboard > Developers > Settings > API credentials** and copy these values:

   ```sh showLineNumbers=false title=".env"
   SCALEKIT_ENVIRONMENT_URL=<your-environment-url> # Example: https://acme.scalekit.dev or https://auth.acme.com (if custom domain is set)
   SCALEKIT_CLIENT_ID=<app-client-id> # Example: skc_1234567890abcdef
   SCALEKIT_CLIENT_SECRET=<app-client-secret> # Example: test_abcdef1234567890
   ```

   Your workspace includes two environment URLs:

   ```md showLineNumbers=false wrap title="Environment URLs"
   https://{your-subdomain}.scalekit.dev  (Development)
   https://{your-subdomain}.scalekit.com  (Production)
   ```

   View your environment URLs in **Dashboard > Developers > Settings**.

2. ## Install and initialize the SDK

   Choose your preferred language and install the Scalekit SDK:

   ### Node.js

```bash showLineNumbers=false frame="none"
npm install @scalekit-sdk/node
```

   ### Python

```sh showLineNumbers=false frame="none"
pip install scalekit-sdk-python
```

  ### Go

```sh showLineNumbers=false frame="none"
go get -u github.com/scalekit-inc/scalekit-sdk-go
```

   ### Java

```groovy showLineNumbers=false frame="none"
/* Gradle users - add the following to your dependencies in build file */
implementation "com.scalekit:scalekit-sdk-java:2.0.11"
```

```xml showLineNumbers=false frame="none"
<!-- Maven users - add the following to your `pom.xml` -->
<dependency>
    <groupId>com.scalekit</groupId>
    <artifactId>scalekit-sdk-java</artifactId>
    <version>2.0.11</version>
</dependency>
```

   After installation, initialize the SDK with your credentials:

   
     ### Node.js

```js title="Initialize SDK"
import { Scalekit } from '@scalekit-sdk/node';

// Initialize the Scalekit client with your credentials
const scalekit = new Scalekit(
  process.env.SCALEKIT_ENVIRONMENT_URL,
  process.env.SCALEKIT_CLIENT_ID,
  process.env.SCALEKIT_CLIENT_SECRET
);
```

     ### Python

```python title="Initialize SDK"
from scalekit import ScalekitClient
import os

# Initialize the Scalekit client with your credentials
scalekit_client = ScalekitClient(
  env_url=os.getenv('SCALEKIT_ENVIRONMENT_URL'),
  client_id=os.getenv('SCALEKIT_CLIENT_ID'),
  client_secret=os.getenv('SCALEKIT_CLIENT_SECRET')
)
```

     ### Go

```go title="Initialize SDK"
import (
  "os"
  "github.com/scalekit-inc/scalekit-sdk-go"
)

// Initialize the Scalekit client with your credentials
scalekitClient := scalekit.NewScalekitClient(
  os.Getenv("SCALEKIT_ENVIRONMENT_URL"),
  os.Getenv("SCALEKIT_CLIENT_ID"),
  os.Getenv("SCALEKIT_CLIENT_SECRET"),
)
```

     ### Java

```java title="Initialize SDK"
import com.scalekit.ScalekitClient;

// Initialize the Scalekit client with your credentials
ScalekitClient scalekitClient = new ScalekitClient(
  System.getenv("SCALEKIT_ENVIRONMENT_URL"),
  System.getenv("SCALEKIT_CLIENT_ID"),
  System.getenv("SCALEKIT_CLIENT_SECRET")
);
```

   

   > tip: SDK features
>
> All official SDKs include automatic retries, error handling, typed models, and auth helper methods to simplify your integration.

3. ## Verify your setup

   Test your configuration by listing organizations in your workspace. This confirms your credentials work correctly.

   
   ### cURL

```bash wrap showLineNumbers=false title="Authenticate with client credentials"
# Get an access token
curl https:///oauth/token \
  -X POST \
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -d 'client_id=' \
  -d 'client_secret=' \
  -d 'grant_type=client_credentials'
```

This returns an access token:

```json wrap showLineNumbers=false
{
  "access_token": "eyJhbGciOiJSUzI1NiIsImInR5cCI6IkpXVCJ9...",
  "token_type": "Bearer",
  "expires_in": 86399,
  "scope": "openid"
}
```

Use the token to access the Scalekit API

```sh wrap showLineNumbers=false title="List organizations"
curl -L '/api/v1/organizations?page_size=5' \
  -H 'Authorization: Bearer '
```

   ### Node.js

Create a file `verify.js` with the following code:

```javascript collapse={1-8} wrap showLineNumbers=false title="verify.js"
import { ScalekitClient } from '@scalekit-sdk/node';

const scalekit = new ScalekitClient(
  process.env.SCALEKIT_ENVIRONMENT_URL,
  process.env.SCALEKIT_CLIENT_ID,
  process.env.SCALEKIT_CLIENT_SECRET,
);

const { organizations } = await scalekit.organization.listOrganization({
  pageSize: 5,
});

console.log(`Name of the first organization: ${organizations[0].display_name}`);
```

Run the verification script:

```bash title="Run verification" showLineNumbers=false
node verify.js
```

   ### Python

Create a file `verify.py` with the following code:

```python collapse={1-9} wrap showLineNumbers=false title="verify.py"
from scalekit import ScalekitClient
import os

# Initialize the SDK client
scalekit_client = ScalekitClient(
  os.getenv('SCALEKIT_ENVIRONMENT_URL'),
  os.getenv('SCALEKIT_CLIENT_ID'),
  os.getenv('SCALEKIT_CLIENT_SECRET')
)

org_list = scalekit_client.organization.list_organizations(page_size=5)

print(f'Name of the first organization: {org_list[0].display_name}')
```

Run the verification script:

```bash title="Run verification" showLineNumbers=false
python verify.py
```

   ### Go

Create a file `verify.go` with the following code:

```go collapse={1-18, 23-26} wrap showLineNumbers=false title="verify.go"
package main

import (
  "context"
  "fmt"
  "os"
  "github.com/scalekit-inc/scalekit-sdk-go"
)

func main() {
  ctx := context.Background()

  scalekitClient := scalekit.NewScalekitClient(
    os.Getenv("SCALEKIT_ENVIRONMENT_URL"),
    os.Getenv("SCALEKIT_CLIENT_ID"),
    os.Getenv("SCALEKIT_CLIENT_SECRET"),
  )

  organizations, err := scalekitClient.Organization.ListOrganizations(ctx, &scalekit.ListOrganizationsParams{
    PageSize: 5,
  })

  if err != nil {
    panic(err)
  }

  fmt.Printf("Name of the first organization: %s\n", organizations[0].DisplayName)
}
```

   ### Java

Create a file `Verify.java` with the following code:

```java collapse={1-7} wrap showLineNumbers=false title="Verify.java"
import com.scalekit.ScalekitClient;
import com.scalekit.models.ListOrganizationsResponse;

public class Verify {
  public static void main(String[] args) {
    ScalekitClient scalekitClient = new ScalekitClient(
      System.getenv("SCALEKIT_ENVIRONMENT_URL"),
      System.getenv("SCALEKIT_CLIENT_ID"),
      System.getenv("SCALEKIT_CLIENT_SECRET")
    );

    ListOrganizationsResponse organizations = scalekitClient.organizations().listOrganizations(5, "");
    System.out.println("Name of the first organization: " + organizations.getOrganizations()[0].getDisplayName());
  }
}
```

   

   If you see organization data, your setup is complete! You're now ready to implement authentication in your application.

## Set up Scalekit MCP Server 

Scalekit's Model Context Protocol (MCP) server connects your AI coding assistants to Scalekit. Manage environments, organizations, users, and authentication through natural language queries in Claude, Cursor, Windsurf, and other MCP-compatible tools.

The MCP server provides AI assistants with tools for environment management, organization and user management, authentication connection setup, role administration, and admin portal access. It uses OAuth 2.1 authentication to securely connect your AI tools to your Scalekit workspace.

> tip: Building your own MCP server?
>
> If you're building your own MCP server and need to add OAuth-based authorization, check out our guide: [Add auth to your MCP server](/authenticate/mcp/quickstart/).

### Configure your MCP client

Based on your MCP client, follow the configuration instructions below:

### Claude Desktop

1. Open the Claude Desktop app, go to Settings, then Developer
2. Click Edit Config
3. Open the `claude_desktop_config.json` file
4. Copy and paste the server config to your existing file, then save
5. Restart Claude

```json
{
  "mcpServers": {
    "scalekit": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.scalekit.com/"]
    }
  }
}
```

### Cursor

1. Open Cursor, go to Settings, then Cursor Settings
2. Select MCP on the left
3. Click Add "New Global MCP Server" at the top right
4. Copy and paste the server config to your existing file, then save
5. Restart Cursor

```json
{
  "mcpServers": {
    "scalekit": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.scalekit.com/"]
    }
  }
}
```

### Windsurf

1. Open Windsurf, go to Settings, then Developer
2. Click Edit Config
3. Open the `windsurf_config.json` file
4. Copy and paste the server config to your existing file, then save
5. Restart Windsurf

```json
{
  "mcpServers": {
    "scalekit": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.scalekit.com/"]
    }
  }
}
```

### VS Code (1.101+)

VS Code version 1.101 or greater supports OAuth natively. Configure the MCP server directly without the `mcp-remote` proxy:

```json
{
  "servers": {
    "scalekit": {
      "type": "http",
      "url": "https://mcp.scalekit.com/"
    }
  }
}
```

After configuration, your MCP client will initiate an OAuth authorization workflow to securely connect to Scalekit's MCP server.

> note
>
> The Scalekit MCP server source code is available on [GitHub](https://github.com/scalekit-inc/mcp). Feel free to explore the code, raise issues, or contribute new tools.

## Configure code editors for Scalekit documentation

In-code editor chat features are powered by models that understand your codebase and project context. These models search the web for relevant information to help you. However, they may not always have the latest information. Follow the instructions below to configure your code editors to explicitly index for up-to-date information.

### Set up Cursor

To enable Cursor to access up-to-date Scalekit documentation:

1. Open Cursor settings (Cmd/Ctrl + ,)
2. Navigate to **Indexing & Docs** section
3. Click on **Add**
4. Add `https://docs.scalekit.com/llms-full.txt` to the indexable URLs
5. Click on **Save**

Once configured, use `@Scalekit Docs` in your chat to ask questions about Scalekit features, APIs, and integration guides. Cursor will search the latest documentation to provide accurate, up-to-date answers.

### Use Windsurf

> Image: Screenshot

Windsurf enables `@docs` mentions within the Cascade chat to search for the best answers to your questions.

  ### Full Documentation

```
@docs:https://docs.scalekit.com/llms-full.txt
<your question here>
```
Costs more tokens.

  ### Specific Section

```
@docs:https://docs.scalekit.com/your-specific-section-or-file
<your question here>
```
Costs less tokens.

  ### Let AI decide

```
@docs:https://docs.scalekit.com/llms.txt
<your question here>
```
Costs tokens as per the model decisions.

## Use AI assistants

Assistants like **Anthropic Claude**, **Ollama**, **Google Gemini**, **Vercel v0**, **OpenAI's ChatGPT**, or your own models can help you with Scalekit projects.

> note: Need help with a specific AI tool?
>
> Don't see instructions for your favorite AI assistant? We'd love to add support for more tools! [Raise an issue](https://github.com/scalekit-inc/developer-docs/issues) on our GitHub repository and let us know which AI tool you'd like us to document.


---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
