Get Environment

GET /workspaces/{slug}/environments/{envSlug}

Returns the environment row plus a denormalized \`resolved\` block that mirrors the §5.2 provider-resolution precedence so clients (env selector, schema settings) can render provider + model without their own lookup.

curl -X GET \
-H "x-api-key: dsk_your_api_key" \
https://api.tracore.io/workspaces/my-workspace/environments/production
import { TracoreClient } from '@tracore/sdk';

const client = new TracoreClient({ apiKey: 'dsk_your_api_key' });

const env = await client.environments.get('my-workspace', 'production');
console.log(env);
200 Response
{
  "id": "ws_abc123",
  "workspaceId": "ws_abc123",
  "slug": "production",
  "name": "My Workspace",
  "isDefault": true,
  "isLocked": false,
  "createdAt": "2024-03-15T10:30:00Z",
  "updatedAt": "2024-03-15T10:30:00Z",
  "providerKeyId": "example-value",
  "model": "example-value",
  "resolved": {
    "provider": "mistral",
    "model": "example-value",
    "residency": "EU",
    "keySource": "system"
  }
}