canonical: https://jentic.com/apis/visualstudio.com/visualstudio

# Visualstudio VSOnline

Public APIs for managing VS Codespaces. The API exposes 57 endpoints secured with bearer authentication.

## For AI agents

Programmatically getenvironmentroute, getprebuildreadinessskusroute. Covers 57 operations with bearer authentication.

## Scope

Does not handle payments, communications, or crm - use for developer tools only.

## Capabilities

- GetEnvironmentRoute
- GetPrebuildReadinessSkusRoute
- Integrate VSOnline into automated workflows
- Query and filter VSOnline records by parameters
- Monitor VSOnline operational status and events

## Use cases

### Developer Tools Operations

Use the VSOnline to perform developer tools operations programmatically. The API provides 57 endpoints covering core functionality including getenvironmentroute, getprebuildreadinessskusroute.

Example prompt: Call GET `/api/v1/Environments/{environmentId}` to getenvironmentroute

### Data Retrieval and Monitoring

Query VSOnline resources on a schedule to track changes, generate alerts, or feed downstream dashboards. Agents poll relevant endpoints, compare against previous state, and trigger actions when thresholds are crossed.

Example prompt: Poll the primary VSOnline endpoint, compare response to last known state, and alert if changed

### AI Agent Integration via Jentic

AI agents discover and call VSOnline endpoints through Jentic without managing credentials directly. An agent searches for the required operation by intent, receives the matching endpoint schema, and executes the call with Jentic-managed authentication. This eliminates the need to read API documentation or handle bearer tokens manually.

Example prompt: Search Jentic for 'getenvironmentroute', load the operation schema, and execute with Jentic-managed credentials

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/api/v1/Environments/{environmentId}` | GetEnvironmentRoute |
| GET | `/api/v2/prebuilds/templates/skus/repo/{repoId}/branch/{branchName}/hash/{prebuildHash}/location/{location}/devcontainerpath/{devContainerPath}` | GetPrebuildReadinessSkusRoute |

## Key resources

- **Agenttelemetry** — Operations for AgentTelemetry
- **Agents** — Operations for Agents
- **Billing** — Operations for Billing
- **Environments** — Operations for Environments
- **Genevaactions** — Operations for GenevaActions

## AI readiness

This API is usable in Jentic One now. Its AI-readiness score against Jentic's framework shows where it stands today and where improvements would make it even easier for agents to use.

- **Score:** 0 / 100
- **Maturity:** Non-Ready
- **Dimensions:**
  - Foundational Compliance: 65 / 100
  - Developer Experience & Jentic Compatibility: 63 / 100
  - AI-Readiness & Agent Experience: 22 / 100
  - Agent Usability: 93 / 100
  - Security: 75 / 100
  - AI Discoverability: 0 / 100
- **View full report:** https://jentic.com/apis/visualstudio.com/visualstudio/scorecard
- **How the score is calculated:** https://docs.jentic.com/reference/api-readiness-framework/overview/
- **More about the dimensions:** https://docs.jentic.com/reference/api-readiness-framework/specification/#dimensional-model-overview

### Score it yourself

Every API in the directory is allowlisted, so you can re-score it with no key required.

- **Score your own API:** https://jentic.com/scorecard.md
- **Scoring CLI agent skill:** https://github.com/jentic/jentic-api-scorecard/blob/main/skills/jentic-api-scorecard/SKILL.md

```sh
npx @jentic/api-scorecard-cli score <openapi-url>
```

## Why Jentic

- **Setup:** Wiring the VSOnline API by hand means passing its JWT bearer token in the Authorization header and forming its environment and prebuild-template calls yourself. Through Jentic you install once, import the VSOnline API from the API Directory, store the token once, and your agent calls it.
- **Permission scoping:** VSOnline puts the environment id in the URL path (`/api/v1/Environments/{environmentId}`), so a rule can pin your agent to one environment and the operations around it. You choose the operations it may call, so anything beyond reading that environment is not included unless you add it.
- **Credential handling:** Your VSOnline token is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'get a codespace environment by id' or 'list prebuild templates for a repository branch', and Jentic returns the matching VSOnline operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Github** — Alternative developer tools API
- **Gitlab** — Alternative developer tools API

## FAQ

### What authentication does the VSOnline use?

The VSOnline uses a Bearer token in the Authorization header. Through Jentic, these credentials are stored encrypted in your Jentic One instance and injected at execution time, so raw secrets never enter the agent context.

### Can I getenvironmentroute with the VSOnline?

Yes. Use the GET `/api/v1/Environments/{environmentId}` endpoint. The API returns structured JSON responses that agents can parse and act on directly.

### What are the rate limits for the VSOnline?

Rate limits are not specified in the OpenAPI spec. Check the vendor documentation for current limits. Through Jentic, rate limiting is handled automatically with retry logic built into the execution layer.

### How do I getenvironmentroute through Jentic?

Install the Jentic SDK with pip install jentic, authenticate through Jentic One, the self-hosted execution layer, then search for 'getenvironmentroute'. Jentic returns the matching VSOnline operation with its input schema. Load the schema and execute the call - credentials are injected automatically.

### How many endpoints does the VSOnline have?

The VSOnline exposes 57 endpoints covering agenttelemetry, agents, billing operations.

### Can I limit what my agent is allowed to do with the VSOnline API?

Yes. Because you run Jentic One yourself, your own rules decide which VSOnline operations and credentials the agent may use. Since VSOnline carries the environment id in the URL path (`/api/v1/Environments/{environmentId}`), you can pin the agent to a single environment and only the operations around it. You pick the operations it may call, so anything beyond reading that one environment is excluded until you add it.
