From 450189f16acd151de15ccbde4531b243331212ef Mon Sep 17 00:00:00 2001 From: "siva.durga" Date: Thu, 17 Sep 2026 15:29:56 +0530 Subject: [PATCH] chore: added model provisioning beta feature docs --- .../integrations/create-integration.mdx | 35 +++++++++++++++++ .../models/update-model-access.mdx | 7 ++++ product/model-catalog/integrations.mdx | 39 +++++++++++++++++++ 3 files changed, 81 insertions(+) diff --git a/api-reference/admin-api/control-plane/integrations/create-integration.mdx b/api-reference/admin-api/control-plane/integrations/create-integration.mdx index 4aa8b6f72..38b167e77 100644 --- a/api-reference/admin-api/control-plane/integrations/create-integration.mdx +++ b/api-reference/admin-api/control-plane/integrations/create-integration.mdx @@ -6,3 +6,38 @@ openapi: post /integrations import PrismaAirsCta from "/snippets/prisma-airs-cta.mdx"; + +## Model provisioning (beta) + +Control how models are provisioned on a new Integration at creation time by opting into a beta feature with the `x-portkey-beta` header: + +``` +x-portkey-beta: model-provisioning-2026-09-02 +``` + +When this header is present, two additional request-body fields take effect: + +| Field | Type | Default | Description | +| :---- | :--- | :------ | :---------- | +| `enable_all_current_models` | boolean | `false` | Enables every model the provider currently offers at creation. When `false`, those models are attached to the Integration but left disabled, so you can enable only the ones you need. | +| `auto_enable_new_models` | boolean | `false` | Determines whether models the provider adds *later* are automatically enabled on this Integration. | + + +These defaults apply **only when the beta header is sent**. Without the header, the legacy behavior is preserved: all current models are enabled and new models are auto-enabled. If your integration relies on that implicit behavior, pass these fields explicitly - this beta behavior will become the default in a future release. + + +### Example + +```bash +curl -X POST "https://api.portkey.ai/v1/integrations" \ + -H "Content-Type: application/json" \ + -H "x-portkey-api-key: $PORTKEY_API_KEY" \ + -H "x-portkey-beta: model-provisioning-2026-09-02" \ + -d '{ + "name": "OpenAI Production", + "slug": "openai-prod", + "ai_provider_id": "openai", + "enable_all_current_models": true, + "auto_enable_new_models": false + }' +``` diff --git a/api-reference/admin-api/control-plane/integrations/models/update-model-access.mdx b/api-reference/admin-api/control-plane/integrations/models/update-model-access.mdx index 8007f99cb..2236900d4 100644 --- a/api-reference/admin-api/control-plane/integrations/models/update-model-access.mdx +++ b/api-reference/admin-api/control-plane/integrations/models/update-model-access.mdx @@ -11,6 +11,12 @@ import PrismaAirsCta from "/snippets/prisma-airs-cta.mdx"; Bulk-update which models an integration can use, plus optional per-model routing and pricing. +## Auto-enabling new models + +`auto_enable_new_models` controls whether models the provider adds later are automatically enabled on this integration. It is the preferred, clearer alias for `allow_all_models` - both are accepted and functionally identical. If you send both, `auto_enable_new_models` takes precedence. + +Each call also syncs the provider's catalog - any models the integration doesn't have yet are added. Synced models follow this flag: enabled when `true`, added but left disabled when `false`. Keep it `false` to curate access explicitly through the `models` list. + ## Per-model configurations Each item in `models` accepts an optional `configurations` object: @@ -34,6 +40,7 @@ curl -X PUT "https://api.portkey.ai/v1/integrations/openai-prod/models" \ -H "Content-Type: application/json" \ -H "x-portkey-api-key: $PORTKEY_API_KEY" \ -d '{ + "auto_enable_new_models": false, "models": [ { "slug": "my-custom-model-v1", diff --git a/product/model-catalog/integrations.mdx b/product/model-catalog/integrations.mdx index a0450f306..15f6f0585 100644 --- a/product/model-catalog/integrations.mdx +++ b/product/model-catalog/integrations.mdx @@ -165,6 +165,45 @@ This is essential for: **Important:** The model list you set here applies to all Providers created from this Integration. Workspaces will only see and be able to use the models you've enabled. +#### Controlling Model Provisioning via the API + +When you manage Integrations programmatically, model provisioning is controlled by two Admin API endpoints working together: +- The [Create Integration API](/api-reference/admin-api/control-plane/integrations/create-integration) creates the Integration and its initial model access. +- The [Update Model Access API](/api-reference/admin-api/control-plane/integrations/models/update-model-access) changes which models are enabled afterwards - the API equivalent of the Model Provisioning screen above. + +**Current default behavior:** Create Integration sets `allow_all_models` to `true`, so a new Integration enables every current model and auto-enables new ones. To restrict access, you follow up with an Update Model Access call - there's no way to lock an Integration down at creation time. + +#### Setting Provisioning at Creation Time (Beta) + + +This is a beta feature, opt in by sending the `x-portkey-beta: model-provisioning-2026-09-02` header. This behavior will become the default in a future release - if your API integration relies on today's defaults, see [Preparing for the default change](#preparing-for-the-default-change). + + +Creating Integrations through the UI is unaffected. The core change is a shift to a **restrictive default**: instead of a new Integration automatically enabling every model, it starts with nothing enabled, and you opt models in from the Create Integration call itself. + +When the header is present, two request fields govern model provisioning: + +| Field | Type | Default | Description | +| :---- | :--- | :------ | :---------- | +| `enable_all_current_models` | boolean | `false` | Enables every model the provider currently offers at creation. When `false`, those models are still attached to the Integration but left disabled, so you can enable only the ones you need. | +| `auto_enable_new_models` | boolean | `false` | Determines whether models the provider adds *later* are automatically enabled on this Integration. | + +These are the same controls you already have through `allow_all_models` and Update Model Access - what changes is the default and *when* you apply it: +- **Restrictive by default:** New Integrations enable nothing until you opt models in, rather than exposing every model automatically - no window where all models are briefly available before you curate them. +- **One-step setup:** Provision models in the create request itself, instead of creating an Integration wide-open and then locking it down with a follow-up Update Model Access call. +- **Current and future models together:** Decide up front which existing models are enabled and whether newly released ones auto-enable. + +##### Preparing for the default change + + +**The API default is changing.** Today, a new Integration enables all current models and auto-enables new ones. In a future release, both fields will default to `false` (the beta behavior) - new Integrations will start with no models enabled. + +If your integration relies on today's behavior, pass `enable_all_current_models: true` and `auto_enable_new_models: true` explicitly so it keeps working after the change. + + + + Set model provisioning controls when creating Integrations programmatically + #### Advanced Model Management