Skip to content

Commit a95d597

Browse files
committed
Updated wrapped clients
1 parent 4a0e489 commit a95d597

File tree

2 files changed

+27
-1
lines changed

2 files changed

+27
-1
lines changed

src/CustomClient.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { WrappedAgentVersions, WrappedArtifactVersions, WrappedModelVersions, WrappedPromptVersions, WrappedToolVersions, WrappedWorkspaces } from "./api/resources/v1/_WrappedClients";
1+
import { WrappedAgentVersions, WrappedArtifactVersions, WrappedModelVersions, WrappedPromptVersions, WrappedToolVersions, WrappedTracingProjects, WrappedWorkspaces } from "./api/resources/v1/_WrappedClients";
22
import { V1 as BaseV1 } from "./api/resources/v1/client/Client";
33
import { TrueFoundryClient as BaseTrueFoundryClient } from "./Client";
44

@@ -9,6 +9,7 @@ class V1 extends BaseV1 {
99
protected _modelVersions: WrappedModelVersions | undefined;
1010
protected _promptVersions: WrappedPromptVersions | undefined;
1111
protected _toolVersions: WrappedToolVersions | undefined;
12+
protected _tracingProjects: WrappedTracingProjects | undefined;
1213
protected _workspaces: WrappedWorkspaces | undefined;
1314

1415
public get agentVersions(): WrappedAgentVersions {
@@ -31,6 +32,10 @@ class V1 extends BaseV1 {
3132
return (this._toolVersions ??= new WrappedToolVersions(this._options));
3233
}
3334

35+
public get tracingProjects(): WrappedTracingProjects {
36+
return (this._tracingProjects ??= new WrappedTracingProjects(this._options));
37+
}
38+
3439
public get workspaces(): WrappedWorkspaces {
3540
return (this._workspaces ??= new WrappedWorkspaces(this._options));
3641
}

src/api/resources/v1/_WrappedClients.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { Workspaces } from "./resources/workspaces/client/Client";
66
import { ModelVersions } from "./resources/modelVersions/client/Client";
77
import { AgentVersions } from "./resources/agentVersions/client/Client";
88
import { ArtifactVersions } from "./resources/artifactVersions/client/Client";
9+
import { TracingProjects } from "./resources/tracingProjects/client/Client";
910

1011
interface HasAsyncListMethod<T> {
1112
list(request: { fqn: string; limit?: number }, requestOptions?: object): Promise<core.Page<T>>;
@@ -128,6 +129,26 @@ export class WrappedToolVersions extends ToolVersions {
128129
}
129130
}
130131

132+
export class WrappedTracingProjects extends TracingProjects {
133+
/**
134+
* Get tracing project API
135+
*
136+
* @param {string} fqn
137+
* @param {TracingProjects.RequestOptions} requestOptions - Request-specific configuration.
138+
*
139+
* @throws {@link TrueFoundry.UnprocessableEntityError}
140+
*
141+
* @example
142+
* await client.v1.tracingProjects.getByFqn("fqn")
143+
*/
144+
public async getByFqn(
145+
fqn: string,
146+
requestOptions?: TracingProjects.RequestOptions,
147+
): Promise<TrueFoundry.GetTracingProjectResponse> {
148+
return { data: await getByFqn(this, fqn, requestOptions) }
149+
}
150+
}
151+
131152
export class WrappedWorkspaces extends Workspaces {
132153
/**
133154
* Get workspace API

0 commit comments

Comments
 (0)