Disable Model Access
Code Mode: praxis.model.models.access.delete
HTTP: DELETE /model/v1/models/{model}/access
Disable one model for your organization by deleting its grant, so the next call to a model that requires access is refused again with 403 MODEL_ACCESS_REQUIRED. Pass any id enableModelAccess accepts, including creator prefixes; the model may be enabled again later, and the new grant records whoever enabled it then. A model that is not currently enabled is already disabled, so deleting a grant that does not exist also answers 200 with revoked true; only an id no catalog model carries answers 404 MODEL_NOT_FOUND.
签名
praxis.model.models.access.delete(args:{path:{model:string}}):Promise<{/** The model id exactly as the caller passed it. */ model:string;/** Always true; the grant no longer exists for this organization, whether or not one did before. */ revoked:true}>;参数
| 名称 | 位置 | 类型 | 必填 | 说明 |
|---|---|---|---|---|
| model | path | string | 是 | Model ID the organization no longer wants enabled; same ids as enableModelAccess. |
响应
| 状态码 | 内容类型 | 说明 |
|---|---|---|
| 200 | application/json | The model is not enabled for this organization |
| 400 | application/problem+json | Missing or empty model id; pass the model on the path. |
| 401 | application/problem+json | Missing or invalid API credentials; supply a valid platform API key in Authorization: Bearer. |
| 404 | application/problem+json | MODEL_NOT_FOUND: no catalog model carries this id; take the id from praxis.model.models.list. |
| default | application/problem+json | Canonical problem |