Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 48 additions & 36 deletions java/scripts/codegen/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion java/scripts/codegen/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"generate:java": "tsx java.ts"
},
"dependencies": {
"@github/copilot": "^1.0.81-6",
"@github/copilot": "^1.0.81-7",
"json-schema": "^0.4.0",
"tsx": "^4.23.12"
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------------------------------------------*/

// AUTO-GENERATED FILE - DO NOT EDIT
// Generated from: api.schema.json

package com.github.copilot.generated.rpc;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import javax.annotation.processing.Generated;

/**
* Identity of the integrating host, declared once on the `server.connect` handshake so telemetry from this connection is attributed to a single, consistent surface. All fields are optional; omit them to keep the default attribution.
*
* @since 1.0.0
*/
@javax.annotation.processing.Generated("copilot-sdk-codegen")
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignoreUnknown = true)
public record ConnectClientInfo(
/** Name of the host editor, e.g. `"vscode"`. */
@JsonProperty("editorName") String editorName,
/** Version of the host editor, e.g. `"1.124.2"`. Ignored unless it looks like a version string. */
@JsonProperty("editorVersion") String editorVersion,
/** Name of the Copilot extension within the host, e.g. `"copilot-chat"`. */
@JsonProperty("extensionName") String extensionName,
/** Version of the Copilot extension within the host, e.g. `"0.54.0"`. Ignored unless it looks like a version string. */
@JsonProperty("extensionVersion") String extensionVersion
) {
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
public record ConnectParams(
/** Opt this connection in to GitHub telemetry forwarding for its lifetime. When set, the runtime forwards every internal telemetry event it emits — across all sessions, plus sessionless events — to this connection over the `gitHubTelemetry.event` notification. Regular events are also written to the runtime's normal GitHub/CTS path (dual-write); host-only compatibility events are forward-only and intentionally skip that path. Intended for first-party hosts that re-emit the events into their own telemetry stores. Both unrestricted and restricted events are forwarded, each tagged with a `restricted` discriminator; a backstop drops restricted events when restricted telemetry is disabled — using the process-global gate for ordinary events and an explicit session-scoped decision for host-only events. */
@JsonProperty("enableGitHubTelemetryForwarding") Boolean enableGitHubTelemetryForwarding,
/** Identity of the integrating host. Optional; omit it to keep the default attribution. */
@JsonProperty("clientInfo") ConnectClientInfo clientInfo,
/** Connection token; required when the server was started with COPILOT_CONNECTION_TOKEN */
@JsonProperty("token") String token
) {
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ public record Model(
/** Model capability category for grouping in the model picker */
@JsonProperty("modelPickerCategory") ModelPickerCategory modelPickerCategory,
/** Relative cost tier for token-based billing users */
@JsonProperty("modelPickerPriceCategory") ModelPickerPriceCategory modelPickerPriceCategory
@JsonProperty("modelPickerPriceCategory") ModelPickerPriceCategory modelPickerPriceCategory,
/** Informational notices the service published for this model, such as an upcoming change or a recommended alternative. Present only when the service published at least one notice. Hosts should surface these without implying anything is wrong with the model. */
@JsonProperty("infoMessages") List<ModelMessage> infoMessages,
/** Warnings the service published for this model, such as a deprecated client version. Present only when the service published at least one warning. The model remains usable; hosts should surface these as advisory rather than blocking. */
@JsonProperty("warningMessages") List<ModelMessage> warningMessages
) {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------------------------------------------*/

// AUTO-GENERATED FILE - DO NOT EDIT
// Generated from: api.schema.json

package com.github.copilot.generated.rpc;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import javax.annotation.processing.Generated;

/**
* A service-published message about a model, carrying a stable machine-readable code alongside human-readable text.
*
* @since 1.0.0
*/
@javax.annotation.processing.Generated("copilot-sdk-codegen")
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignoreUnknown = true)
public record ModelMessage(
/** Stable machine-readable identifier for the message, such as `client_version_deprecated`. Hosts can key custom presentation off this; unrecognized codes should fall back to displaying `message`. */
@JsonProperty("code") String code,
/** Human-readable message text intended for display to the user. */
@JsonProperty("message") String message
) {
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public record SandboxConfig(
@JsonProperty("addCurrentWorkingDirectory") Boolean addCurrentWorkingDirectory,
/** Credential-injection capability flags. */
@JsonProperty("auth") SandboxConfigAuth auth,
/** Whether to auto-grant read access to the tool directories discovered on PATH and in toolchain environment variables (GOROOT, CARGO_HOME, JAVA_HOME, VIRTUAL_ENV, and similar), and to common developer-tool caches, registries, and toolchains in their default home locations (cargo, go, npm, Maven, and more), plus read-write access to (and, on Unix, up-front creation of) the scratch caches builds write on every run (go-build, ccache, sccache, Gradle caches, Cargo lock/tracker files), so builds work without extra configuration; a relocated CARGO_HOME additionally gets its Cargo lock files granted read-write. Set to false to disable every grant listed above: user-installed toolchains (rustup, nvm, pyenv, conda, pipx) then need explicit userPolicy.filesystem entries — readonlyPaths to read them, plus readwriteFiles for a relocated CARGO_HOME's .package-cache and .global-cache, which Cargo locks on every build. Only these developer-tool grants are affected: the working directory (see addCurrentWorkingDirectory), temporary storage, session log paths, and system locations follow their own rules and stay granted, so commands still run. Default: true (enabled by default; set to false to opt out). */
/** Whether to auto-grant read access to the tool directories discovered on PATH and in toolchain environment variables (GOROOT, CARGO_HOME, JAVA_HOME, VIRTUAL_ENV, and similar), and to common developer-tool caches, registries, and toolchains in their default home locations (cargo, go, npm, Maven, and more), plus read-write access to (and up-front creation of) the scratch caches builds write on every run (go-build, ccache, sccache, Gradle caches, Cargo lock/tracker files), so builds work without extra configuration; a relocated CARGO_HOME additionally gets its Cargo lock files granted read-write. Set to false to disable every grant listed above: user-installed toolchains (rustup, nvm, pyenv, conda, pipx) then need explicit userPolicy.filesystem entries — readonlyPaths to read them, plus readwriteFiles for a relocated CARGO_HOME's .package-cache and .global-cache, which Cargo locks on every build. Only these developer-tool grants are affected: the working directory (see addCurrentWorkingDirectory), temporary storage, session log paths, and system locations follow their own rules and stay granted, so commands still run. Default: true (enabled by default; set to false to opt out). */
@JsonProperty("allowDevToolAccess") Boolean allowDevToolAccess
) {
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignoreUnknown = true)
public record SessionManagedPermissions(
/** When set to `disable`, prevents bypass/allow-all permission modes. */
@JsonProperty("disableBypassPermissionsMode") DisableBypassPermissionsMode disableBypassPermissionsMode,
/** When set to `disable`, prevents bypass/allow-all permission modes. `allow-auto-only` blocks full allow-all but permits advisory auto-approval. Any other value is accepted rather than failing the session, but is enforced as `disable`: the key is only present to restrict something, so a mode this runtime cannot interpret fails closed to the most restrictive one it knows. Omit the key entirely to impose no restriction. */
@JsonProperty("disableBypassPermissionsMode") String disableBypassPermissionsMode,
/** Permission rules that block matching operations. Deny has highest precedence. */
@JsonProperty("deny") List<String> deny,
/** Permission rules that require explicit human approval. */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ public record SessionQueuePendingItemsResult(
/** Pending queued items in submission order. Includes user messages, queued slash commands, and queued model changes; omits internal system items. */
@JsonProperty("items") List<QueuePendingItems> items,
/** Display text for messages currently in the immediate steering queue (interjections sent during a running turn). */
@JsonProperty("steeringMessages") List<String> steeringMessages
@JsonProperty("steeringMessages") List<String> steeringMessages,
/** How many leading entries of `steeringMessages` have already been folded into the running turn (and so have an emitted `user.message`), as opposed to still waiting for one. Absent for hosts that do not distinguish the two. */
@JsonProperty("inFlightSteeringCount") Long inFlightSteeringCount
) {
}
Loading