Projects
A project separates the work of one environment or product from the rest of your organization. Sessions, profiles, credentials and Quick actions belong to a project, and a project key reaches only its own project. Use projects to keep staging apart from production, or one product apart from another. Every organization has a default project, named Default project. Projects and namespaces explains what a project holds.
The plan limits, such as concurrent sessions, apply to the whole organization, not to each project. See Limits.
Before you begin
Put your Steel API key in the STEEL_API_KEY environment variable, and install the Steel SDK for your language: TypeScript, Python, Go or Rust.
Create a project
An organization admin creates projects in the dashboard. Members who are not admins, and API keys, cannot create, change or delete projects.
- Open the project menu at the top of the dashboard. It shows the current project's name.
- Click Create project.
- Under Name your project, type a name.
- To make it a production project, turn on Production.
- Click Create project.
The dashboard switches to the new project. Steel makes the slug from the name. The project menu also has View & manage projects, which opens Project Settings. There an admin can create, rename, promote and delete projects, and copy each project ID.
A project has these properties:
| Property | Rule |
|---|---|
| Name | 1 to 100 characters |
| Slug | Lower-case letters, digits and hyphens. It must be unique in the organization. |
| Production | A project is a development project or a production project. Promoting a development project to production cannot be undone. |
| Default | One project of the organization is the default. The default project cannot be deleted. |
After you create a project, create a key for it. See API keys.
Switch projects
Each interface picks its project in its own way:
| Interface | How to use another project |
|---|---|
| Your code, with a project key | Use a key of the other project |
| Your code, with an organization key | Pass the other project's ID in projectId |
| MCP server, with sign-in | Sign in again, and pick the other project |
| MCP server, with an API key | Use a key of the other project |
In the dashboard, open the project menu at the top of the page, and click the other project. Each project in the menu has a Prod or Dev badge. The dashboard then shows that project's sessions, API keys, profiles and credentials. It remembers your choice for each organization. Until you choose, it uses the default project.
Use a project from the API
To use a project from your code, you need its ID. This program lists the projects that your key reaches, with their IDs.
import Steel from "steel-sdk";
const client = new Steel();
const { projects } = await client.projects.list();
for (const project of projects) {
console.log(project.id, project.name, project.isDefault ? "(default)" : "");
}from steel import Steel
client = Steel()
response = client.projects.list()
for project in response.projects:
print(project.id, project.name, "(default)" if project.is_default else "")package main
import (
"context"
"fmt"
"log"
"github.com/steel-dev/sdk/go"
)
func main() {
if err := run(context.Background()); err != nil {
log.Fatal(err)
}
}
func run(ctx context.Context) error {
client := steel.NewClient()
response, err := client.Projects.List(ctx)
if err != nil {
return err
}
for _, project := range response.Projects {
label := ""
if project.IsDefault {
label = "(default)"
}
fmt.Println(project.ID, project.Name, label)
}
return nil
}#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = steel_rs::Client::new();
let projects = client.projects().list().await?.projects;
for project in projects {
let label = if project.is_default { "(default)" } else { "" };
println!("{} {} {label}", project.id, project.name);
}
Ok(())
}Run the program:
npx tsx projects.mtspython projects.pygo run .cargo runWith an organization key, the program prints every project in the organization. With a project key, it prints only the key's project.
e4aa5c83-05bd-49eb-a83f-d36f710976b0 Default project (default)What projectId does depends on your key's scope:
- A project key always uses its own project. Steel does not read
projectIdfrom the request. - An organization key needs
projectIdto create a session, run a Quick action, or work with profiles or credentials. Without it, the request gets a400error. A list of sessions covers every project unless you passprojectId.
With an organization key, pass the ID when you create a session:
const session = await client.sessions.create({
projectId: process.env.STEEL_PROJECT_ID,
});import os
session = client.sessions.create(
project_id=os.environ["STEEL_PROJECT_ID"],
)import "os"
session, err := client.Sessions.New(ctx, steel.SessionNewParams{
ProjectID: steel.F(os.Getenv("STEEL_PROJECT_ID")),
})
if err != nil {
return err
}let session = client
.sessions()
.create(steel_rs::SessionCreateParams {
project_id: Some(std::env::var("STEEL_PROJECT_ID")?),
..Default::default()
})
.await?;The session runs in that project, and the response's projectId field shows it. Release the session in a finally block, as in Create a session. In Go, release it in a defer. In Rust, release it after the async block. Every endpoint for projects is on Projects API.
Check that it worked
Open the project menu at the top of the dashboard. It lists the new project, with a Prod badge if you turned on Production, or Dev if not. With an organization key, the program in Use a project from the API prints the new project's ID and name. A session that you create with that ID has it in projectId, and it is among that project's sessions in the dashboard.