Add models to a project
Give a project models that your organization shares, or its own through a provider, and keep projects from adding keys of their own.
A project calls the models it has, under aliases such as fast. It adds a model your organization shares with it, or its own through a provider: the project's own, or one your organization shares with it. To add a model, you need Owner or LLM Gateway Admin on the project.
Add a model your organization shares
Your organization shares models with projects first: Add models to your organization shows how.
- In your project, click LLM Gateway. It opens on Models, whose Shared by section lists the models your organization shares with the project. Before the project has a model, they're under Set up your first model.
- Beside the model, click Add to project.
- Keep its Model alias, or enter another, and click Add model.
The model shows among the project's, marked as your organization's. Your organization changes it: its provider, provider model and pricing are the organization's. If your organization stops sharing it with the project, it shows Needs attention, and requests to it fail until it's shared again.
Add a model through a provider
You need a provider first: Add a provider shows how to add the project's own, or to share your organization's with it.
- In your project, click LLM Gateway. It opens on Models.
- Click Add models, and select the provider. Before the project has a model, click Choose a model under Set up your first model instead.
- Select the models to add from those the provider lists. Enter part of a name to filter them. For a model the provider serves but doesn't list, click Add by ID and enter its Model ID.
- Click Next.
- Enter each model's alias: what callers send as
model, such asfastorsmart. An alias is unique in the project. - Click Add model.
The models show among the project's, with their aliases to copy: Call models from your code shows how to call them. A project's own provider's page lists the models that go through it, and adds more on its Models tab.
A model through your organization's provider serves only while the organization shares the provider with the project. If it stops, the model shows Needs attention.
Keep projects from adding keys of their own
Your organization can keep its projects, or one of them, to the models and providers it shares. You need Owner or Policy Admin on the organization, on the Team or Enterprise plan (Limits and quotas).
- In your organization, click Settings, then Policies. For one project alone, open the project's Settings, then Policies, instead.
- Beside Turn off projects' own providers, click Edit.
- Select Enforced, and click Save.
Projects can't add providers of their own then. The models through those they added show Needs attention, and requests to them fail, until the policy is lifted. Nothing is deleted.
Add a model with the API
Set your API key (Call the API) and your project's ID:
export KOSEM_API_KEY='kosem_sk_…'
export KOSEM_PROJECT='prj_01m5r9dh9mf0ps98ktkap3562c'To add a model your organization shares, send its resource name as source. The alias is the organization's unless you send another:
export KOSEM_SOURCE_MODEL='organizations/org_01m5r8w2k3e9vbt6g0d4x7qz1h/models/mdl_01m5rb2x9ke4vbt6g0d4x7qz1k'
curl -s -X POST "https://api.kosem.ai/v1/projects/$KOSEM_PROJECT/models" \
-H "Authorization: Bearer $KOSEM_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"source\": \"$KOSEM_SOURCE_MODEL\"}"GET https://api.kosem.ai/v1/projects/$KOSEM_PROJECT/availableModels lists the models your organization shares with the project, by name, and what the project added of them.
For a model through a provider, name the provider, the project's own (projects/…/providers/…) or the organization's shared with it (organizations/…/providers/…), and the provider's name for the model:
export KOSEM_PROVIDER='organizations/org_01m5r8w2k3e9vbt6g0d4x7qz1h/providers/prv_01m5raq8h2e4vbt6g0d4x7qz1j'
curl -s -X POST "https://api.kosem.ai/v1/projects/$KOSEM_PROJECT/models" \
-H "Authorization: Bearer $KOSEM_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"alias\": \"mini\", \"provider\": \"$KOSEM_PROVIDER\", \"providerModel\": \"gpt-5-mini\"}"GET https://api.kosem.ai/v1/projects/$KOSEM_PROJECT/availableProviders lists the providers your organization shares with the project.