Skip to main content

Get a list of currently active models

GET/v2/projects/{projectId}/ai-hosting-models
API version
v2
Request method
GET
Operation ID
ai-hosting-project-get-detailed-models

Request​

  • projectIdstring (uuid)required

Responses​

Format
application/json
Description

List of currently active models.

  • Array[
    • *object
      • activeAtstring (date-time)required
      • displayNamestringrequired
      • docLinkstringrequired
      • labelstring (one of: lts, stable, experimental, legacy stable, preview)
      • namestringrequired
      • removalAtstring (date-time)
      • replacedBystring

        This model was replaced by this value.

      • replacesModelNamestringdeprecated

        This Field is deprecated. You can use replacesModelNames.

      • replacesModelNamesarray of stringrequired

        List of models which were replaced by this model.

        • Array[
          • *string
          ]
      • statusstring (one of: active, needApproval, deprecated)required
      • termsOfServiceLinkstringrequired
      • tokenFactornumber (float)required
    ]
Content-Type: application/json

[
{
"activeAt": "1985-10-26T01:21:00.000Z",
"displayName": "string",
"docLink": "string",
"label": "lts",
"name": "string",
"removalAt": "1985-10-26T01:21:00.000Z",
"replacedBy": "string",
"replacesModelNames": [
"string"
],
"status": "active",
"termsOfServiceLink": "string",
"tokenFactor": 123
}
]
{
"items": {
"properties": {
"activeAt": {
"format": "date-time",
"type": "string"
},
"displayName": {
"type": "string"
},
"docLink": {
"type": "string"
},
"label": {
"enum": [
"lts",
"stable",
"experimental",
"legacy stable",
"preview"
],
"type": "string"
},
"name": {
"type": "string"
},
"removalAt": {
"format": "date-time",
"type": "string"
},
"replacedBy": {
"description": "This model was replaced by this value.",
"type": "string"
},
"replacesModelName": {
"deprecated": true,
"description": "This Field is deprecated. You can use replacesModelNames.",
"type": "string"
},
"replacesModelNames": {
"description": "List of models which were replaced by this model.",
"items": {
"type": "string"
},
"type": "array"
},
"status": {
"enum": [
"active",
"needApproval",
"deprecated"
],
"type": "string"
},
"termsOfServiceLink": {
"type": "string"
},
"tokenFactor": {
"format": "float",
"type": "number"
}
},
"required": [
"name",
"displayName",
"docLink",
"termsOfServiceLink",
"replacesModelNames",
"activeAt",
"status",
"tokenFactor"
],
"type": "object"
},
"type": "array"
}

Usage examples​

$ curl \
--fail \
--location \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
https://api.mittwald.de/v2/projects/f0f86186-0a5a-45b2-aa33-502777496347/ai-hosting-models
import { MittwaldAPIV2Client } from "@mittwald/api-client";
import { assertStatus } from "@mittwald/api-client-commons";

const client = MittwaldAPIClient.newWithToken(process.env.MITTWALD_API_TOKEN);
const response = await client.aiHosting.aiHostingProjectGetDetailedModels({
"projectId": "f0f86186-0a5a-45b2-aa33-502777496347"
});

assertStatus(response, 200);

use \Mittwald\ApiClient\Generated\V2\Clients\AIHosting\AiHostingProjectGetDetailedModels\AiHostingProjectGetDetailedModelsRequest;

$client = MittwaldAPIClient::newWithToken(getenv('MITTWALD_API_TOKEN'));

$request = (new AiHostingProjectGetDetailedModelsRequest(
projectId: "f0f86186-0a5a-45b2-aa33-502777496347"
));
$response = $client->aiHosting()->aiHostingProjectGetDetailedModels($request);

var_dump($response->getBody();

On this page