Skip to content

rivet-dev/daytona

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2,154 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Documentation License Go Report Card Issues - daytona GitHub Release

 

Daytona logo

Run AI Code.
Secure and Elastic Infrastructure for Running Your AI-Generated Code.

Documentation · Report Bug · Request Feature · Join our Slack · Connect on X

Daytona  - Secure and elastic infra for running your AI-generated code. | Product Hunt Daytona  - Secure and elastic infra for running your AI-generated code. | Product Hunt


Installation

Python SDK

pip install daytona

TypeScript SDK

npm install @daytonaio/sdk

Ruby SDK

gem install daytona

Go SDK

go get github.com/daytonaio/daytona/libs/sdk-go

Features

  • Lightning-Fast Infrastructure: Sub-90ms Sandbox creation from code to execution.
  • Separated & Isolated Runtime: Execute AI-generated code with zero risk to your infrastructure.
  • Massive Parallelization for Concurrent AI Workflows: Fork Sandbox filesystem and memory state (Coming soon!)
  • Programmatic Control: File, Git, LSP, and Execute API
  • Unlimited Persistence: Your Sandboxes can live forever
  • OCI/Docker Compatibility: Use any OCI/Docker image to create a Sandbox

Quick Start

  1. Create an account at app.daytona.io
  2. Generate a new API key
  3. Follow documentation to start using Daytona

Creating your first Sandbox

Python SDK

from daytona import Daytona, DaytonaConfig

config = DaytonaConfig(api_key="YOUR_API_KEY")
daytona = Daytona(config)
sandbox = daytona.create()
response = sandbox.process.code_run('print("Hello World!")')
print(response.result)

Typescript SDK

import { Daytona } from "@daytonaio/sdk";

const daytona = new Daytona({apiKey: "YOUR_API_KEY"});
const sandbox = await daytona.create();
const response = await sandbox.process.codeRun('print("Hello World!")');
console.log(response.result);

Ruby SDK

require 'daytona'

config = Daytona::Config.new(api_key: 'YOUR_API_KEY')
daytona = Daytona::Daytona.new(config)
sandbox = daytona.create
response = sandbox.process.code_run(code: 'print("Hello World!")')
puts response.result

Go SDK

package main

import (
  "context"
  "fmt"
  "github.com/daytonaio/daytona/libs/sdk-go/pkg/daytona"
  "github.com/daytonaio/daytona/libs/sdk-go/pkg/types"
)

func main() {
  config := &types.DaytonaConfig{APIKey: "YOUR_API_KEY"}
  client, _ := daytona.NewClientWithConfig(config)
  ctx := context.Background()
  sandbox, _ := client.Create(ctx, nil)
  response, _ := sandbox.Process.ExecuteCommand(ctx, "echo 'Hello World!'")
  fmt.Println(response.Result)
}

Contributing

Daytona is Open Source under the GNU AFFERO GENERAL PUBLIC LICENSE, and is the copyright of its contributors. If you would like to contribute to the software, read the Developer Certificate of Origin Version 1.1 (https://developercertificate.org/). Afterwards, navigate to the contributing guide to get started.

About

Daytona is a Secure and Elastic Infrastructure for Running AI-Generated Code

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • TypeScript 44.9%
  • MDX 24.0%
  • Go 14.8%
  • Python 9.2%
  • Ruby 3.0%
  • JavaScript 1.1%
  • Other 3.0%