SDKs Available
- Python SDK: For Python developers.
- Node/Typescript SDK: For JavaScript and TypeScript developers.
- Go SDK: For Go developers.
End-to-End Walkthrough
Watch the video below to see an end-to-end walkthrough of how to use the Gitpod SDK. The steps below are based on the video.1. Sign Up
- Go to app.gitpod.io and sign up.
- Once logged in, generate a Personal Access Token for SDK authentication under your account settings at Personal Access Tokens.
2. Install the SDK
Install for your preferred language:- Python SDK:
- Node/Typescript SDK:
- Go SDK:
3. Authenticate
Authenticate using your personal access token. Set via environment variable or pass in code.-
Option 1: Set the environment variable
GITPOD_API_KEY
: -
Option 2: Authenticate directly in your code:
-
For Python SDK:
-
For Go SDK:
-
For Node/Typescript SDK:
-
For Python SDK:
4. Run an Example
Create an environment and run a command using the Python SDK:Available Examples
Examples in the SDK repositories:1. Run a Command in an Environment
- Description: Initialize an environment from a Git repository and run a command inside it.
- Location: Python SDK Example - Run Command
2. Run a Service in an Environment
- Description: Run a long-lived service (such as a database or message queue) inside an environment.
- Location: Python SDK Example - Run Service
3. Access the File System in an Environment
- Description: Access and interact with the file system programmatically.
- Location: Python SDK Example - File System Access
4. Use the Anthropic Tool in an Environment
- Description: Use the Anthropic tool within an environment and interact with Model Context Protocol (MCP).
- Location: Python SDK Example - Anthropic Tool Use
5. MCP Server Example
- Description: Demonstrate MCP integration.
- Location: Go SDK Example - MCP Server