Skip to content

Deployment

CodeInterpreterAPI can be easily deployed to production using the CodeBox framework.

Prerequisites

  • CodeBox API key
  • Get your API key from CodeBox (you get an email with the api-key)
  • CodeInterpreterAPI installed
  • pip install codeinterpreterapi

Setup

Set the CODEBOX_API_KEY environment variable or directly in your code:

from codeinterpreterapi import settings

settings.CODEBOX_API_KEY = "sk-..."

Stopping the Session

Don't forget to stop the session when finished:

session.stop()

This will shutdown the CodeBox instance.

Next Steps

  • See the CodeBox docs for more details on deployment options.
  • Look at the examples for more usage ideas.
  • Contact Shroominic for assistance with deployment.