Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
add more content
Vasek Mlejnsky7a7f89395b6d
diff --git a/apps/docs/src/app/getting-started/api-key/APIKey.tsx b/apps/docs/src/app/getting-started/api-key/APIKey.tsxindex b2ff4ce27..7917fbc71 100644--- a/apps/docs/src/app/getting-started/api-key/APIKey.tsx+++ b/apps/docs/src/app/getting-started/api-key/APIKey.tsx@@ -1,14 +1,18 @@'use client'+import clsx from 'clsx'import { Button } from '@/components/Button'import { useApiKey, useUser } from '@/utils/useUser'import { obfuscateKey } from '@/utils/obfuscate'import { createClientComponentClient } from '@supabase/auth-helpers-nextjs'+import { CopyButton } from '@/components/CopyButton'+import { usePostHog } from 'posthog-js/react'function APIKey() {const supabase = createClientComponentClient()const { user, isLoading, error } = useUser()const apiKey = useApiKey()+ const posthog = usePostHog()async function signInWithGitHub() {await supabase.auth.signInWithOAuth({@@ -24,11 +28,31 @@ function APIKey() {return (<div className="flex flex-col items-start justify-start space-y-4">{user ? (- <>- <span className="whitespace-nowrap text-zinc-400 group-hover:opacity-25">- API key+ <div+ className="+ group relative flex+ flex-row+ gap-2 text-xs+ "+ >+ <span className="whitespace-nowrap text-zinc-400 group-hover:opacity-25 font-bold">+ API Key</span>- </>+ <span className="whitespace-nowrap font-mono text-yellow-400 group-hover:opacity-25">+ {obfuscateKey(apiKey)}+ </span>+ <span className="absolute inset-0">+ <CopyButton+ code={apiKey}+ onAfterCopy={() => posthog?.capture('copied API key')}+ customPositionClassNames={clsx(+ 'top-[-2px] bottom-[2px]' /* nudge 2px up*/,+ 'left-[-6px] right-[-6px]' /* widen a little to fit nicely */,+ 'min-h-[28px]'+ )}+ />+ </span>+ </div>) : (<><span>You can get your API key by signing up.</span>diff --git a/apps/docs/src/app/playgrounds/limitations/page.mdx b/apps/docs/src/app/playgrounds/limitations/page.mdxnew file mode 100644index 000000000..c5731497b--- /dev/null+++ b/apps/docs/src/app/playgrounds/limitations/page.mdx@@ -0,0 +1,15 @@+# AI Playground Limitations++export const sections = [+ { title: 'Available Resources', id: 'available-resources' },+ { title: 'Customization', id: 'customization' },+]++### Available resources+- 4 vCPU {{ className: 'lead' }}+- 1GB RAM {{ className: 'lead' }}+- 2.5GB storage {{ className: 'lead' }}++If you need more resources, please [contact us](mailto:[email protected]) with your use case.++### Customization\ No newline at end of filediff --git a/apps/docs/src/app/playgrounds/overview/page.mdx b/apps/docs/src/app/playgrounds/overview/page.mdxindex 5584bdda7..846b770f8 100644--- a/apps/docs/src/app/playgrounds/overview/page.mdx+++ b/apps/docs/src/app/playgrounds/overview/page.mdx@@ -1,8 +1,26 @@export const metadata = {- title: 'E2B AI Playgrounds',- description: 'AI Playgrounds',+ title: 'E2B Documentation - AI Playgrounds',+ description: 'AI Playgrounds for your agents and AI apps',}# AI Playgrounds-AI Playground\ No newline at end of file+**AI Playground is a sandboxed cloud environment for your AI agent or AI app.** The AI playground is like a free sandbox where your AI agent or app can safely operate with filesystem, use any tools, run code, access the internet, and more. {{ className: 'lead' }}++The AI playgorunds run on E2B's cloud infrastructure. Use our [SDK](/getting-started/installation) to create and control the AI playground.++## Use cases+- Use case 1+- Use case 2+- Use case 3++## Create AI Playground++Here's a quick code example showing how to create an AI Playground.++<CodeGroup>+```python {{ language: 'python', snippet: 'python/basics/init.py' }}+```+</CodeGroup>++Head over to [SDK Basics](/getting-started/basics) to see more quick start examples.diff --git a/apps/docs/src/components/Auth.tsx b/apps/docs/src/components/Auth.tsxindex c77418095..59f695127 100644--- a/apps/docs/src/components/Auth.tsx+++ b/apps/docs/src/components/Auth.tsx@@ -63,8 +63,8 @@ export const Auth = function () {gap-2 text-xs">- <span className="whitespace-nowrap text-zinc-400 group-hover:opacity-25">- API key+ <span className="font-bold whitespace-nowrap text-zinc-400 group-hover:opacity-25">+ API Key</span><span className="whitespace-nowrap font-mono text-yellow-400 group-hover:opacity-25">{obfuscateKey(apiKey)}diff --git a/apps/docs/src/components/CopyButton.tsx b/apps/docs/src/components/CopyButton.tsxindex fa387db85..a5620021d 100644--- a/apps/docs/src/components/CopyButton.tsx+++ b/apps/docs/src/components/CopyButton.tsx@@ -45,10 +45,10 @@ export function CopyButton({ref={buttonRef}className={clsx(customPositionClassNames,- 'group/button absolute overflow-hidden rounded-full py-1 pl-2 pr-3 text-2xs font-medium opacity-0 backdrop-blur transition focus:opacity-100 group-hover:opacity-100',+ 'border border-zinc-700 group/button absolute overflow-hidden rounded-full py-1 pl-2 pr-3 text-2xs font-medium opacity-0 transition focus:opacity-100 group-hover:opacity-100',copied- ? 'bg-emerald-400/10 ring-1 ring-inset ring-emerald-400/20'- : 'bg-white/5 hover:bg-white/7.5 dark:bg-white/2.5 dark:hover:bg-white/5'+ ? 'bg-emerald-400/20 ring-1 ring-inset ring-emerald-400/20'+ : 'bg-white/5 hover:bg-white/7.5 dark:bg-white/2.5 dark:hover:bg-red-500/')}onClick={() => {window.navigator.clipboard.writeText(code).then(() => {diff --git a/apps/docs/src/components/Header.tsx b/apps/docs/src/components/Header.tsxindex 55cadb217..a6cada467 100644--- a/apps/docs/src/components/Header.tsx+++ b/apps/docs/src/components/Header.tsx@@ -81,15 +81,15 @@ export const Header = forwardRef(function Header({ className }, ref) {<div className="flex items-center gap-4"><nav className="hidden md:block"><ul role="list" className="flex items-center gap-4">- <TopLevelNavItem href="https://discord.gg/U7KEcGErtQ">- <DiscordIcon className="h-5 w-5 fill-current" />- </TopLevelNavItem><TopLevelNavItem href="https://twitter.com/e2b_dev"><TwitterIcon className="h-5 w-5 fill-current" /></TopLevelNavItem><TopLevelNavItem href="https://github.com/e2b-dev/e2b"><GitHubIcon className="h-5 w-5 fill-current" /></TopLevelNavItem>+ <TopLevelNavItem href="https://discord.gg/U7KEcGErtQ">+ <DiscordIcon className="h-5 w-5 fill-current" />+ </TopLevelNavItem></ul></nav><HeaderSeparator />diff --git a/apps/docs/src/components/Navigation.tsx b/apps/docs/src/components/Navigation.tsxindex 7b7830e9a..f04adce24 100644--- a/apps/docs/src/components/Navigation.tsx+++ b/apps/docs/src/components/Navigation.tsx@@ -151,14 +151,14 @@ function NavigationGroup({ group, className }) {// Running on the server, there's bug with usePathname() and basePath https://github.com/vercel/next.js/issues/52700if (typeof window === 'undefined' && initialPathname === '/') initialPathname = '/docs'-+let [pathname, sections] = useInitialValue([initialPathname, useSectionStore((s) => s.sections)],isInsideMobileNavigation)-+let isActiveGroup = activeGroupIndex(group, pathname) !== -1-+return (<li className={clsx('relative mt-6', className)}><motion.h2@@ -246,14 +246,14 @@ export const navigation = [{ title: 'SDK Basics', href: '/getting-started/basics' },],},- // {- // title: 'AI Playgrounds',- // links: [- // { title: 'Overview', href: '/playgrounds/overview' },- // { title: 'Limitations', href: '/playgrounds/limitations' },- // // { title: 'Use with AI Agents & Copilots', href: '/getting-started/how-to' },- // ],- // },+ {+ title: 'AI Playgrounds',+ links: [+ { title: 'Overview', href: '/playgrounds/overview' },+ { title: 'Limitations', href: '/playgrounds/limitations' },+ // { title: 'Use with AI Agents & Copilots', href: '/getting-started/how-to' },+ ],+ },// {// title: 'AI Environments',// links: [