@roarkanalytics/sdk 4.10.0 → 4.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/client.d.mts +6 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +6 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/customer-flow-edge-case.d.mts +21 -4
  12. package/resources/customer-flow-edge-case.d.mts.map +1 -1
  13. package/resources/customer-flow-edge-case.d.ts +21 -4
  14. package/resources/customer-flow-edge-case.d.ts.map +1 -1
  15. package/resources/customer-flow.d.mts +36 -3
  16. package/resources/customer-flow.d.mts.map +1 -1
  17. package/resources/customer-flow.d.ts +36 -3
  18. package/resources/customer-flow.d.ts.map +1 -1
  19. package/resources/index.d.mts +2 -0
  20. package/resources/index.d.mts.map +1 -1
  21. package/resources/index.d.ts +2 -0
  22. package/resources/index.d.ts.map +1 -1
  23. package/resources/index.js +5 -1
  24. package/resources/index.js.map +1 -1
  25. package/resources/index.mjs +2 -0
  26. package/resources/index.mjs.map +1 -1
  27. package/resources/me.d.mts +56 -0
  28. package/resources/me.d.mts.map +1 -0
  29. package/resources/me.d.ts +56 -0
  30. package/resources/me.d.ts.map +1 -0
  31. package/resources/me.js +23 -0
  32. package/resources/me.js.map +1 -0
  33. package/resources/me.mjs +19 -0
  34. package/resources/me.mjs.map +1 -0
  35. package/resources/project.d.mts +51 -0
  36. package/resources/project.d.mts.map +1 -0
  37. package/resources/project.d.ts +51 -0
  38. package/resources/project.d.ts.map +1 -0
  39. package/resources/project.js +24 -0
  40. package/resources/project.js.map +1 -0
  41. package/resources/project.mjs +20 -0
  42. package/resources/project.mjs.map +1 -0
  43. package/src/client.ts +10 -0
  44. package/src/resources/customer-flow-edge-case.ts +23 -4
  45. package/src/resources/customer-flow.ts +40 -3
  46. package/src/resources/index.ts +2 -0
  47. package/src/resources/me.ts +76 -0
  48. package/src/resources/project.ts +65 -0
  49. package/src/version.ts +1 -1
  50. package/version.d.mts +1 -1
  51. package/version.d.ts +1 -1
  52. package/version.js +1 -1
  53. package/version.mjs +1 -1
@@ -17936,6 +17936,15 @@ export declare namespace CustomerFlowCreateParams {
17936
17936
 
17937
17937
  title: string;
17938
17938
 
17939
+ /**
17940
+ * The expectations graded on this variant only, on top of the flow's own. Sent as
17941
+ * the complete set: it replaces whatever the variant had, so omit it to leave the
17942
+ * set alone and send [] to clear it. Improv flows only: a scripted variant's
17943
+ * expectations come from the agent turns on its path and are rewritten on every
17944
+ * graph edit.
17945
+ */
17946
+ additionalExpectations?: Array<HappyPath.AdditionalExpectation>;
17947
+
17939
17948
  precededByCustomerFlowId?: string | null;
17940
17949
 
17941
17950
  precededByCustomerFlowVariantId?: string | null;
@@ -17943,6 +17952,15 @@ export declare namespace CustomerFlowCreateParams {
17943
17952
  prompt?: string | null;
17944
17953
  }
17945
17954
 
17955
+ export namespace HappyPath {
17956
+ export interface AdditionalExpectation {
17957
+ /**
17958
+ * What the agent under test is graded against.
17959
+ */
17960
+ prompt: string;
17961
+ }
17962
+ }
17963
+
17946
17964
  export interface AgentExpectation {
17947
17965
  /**
17948
17966
  * What the agent under test is graded against.
@@ -17953,6 +17971,15 @@ export declare namespace CustomerFlowCreateParams {
17953
17971
  export interface EdgeCase {
17954
17972
  title: string;
17955
17973
 
17974
+ /**
17975
+ * The expectations graded on this variant only, on top of the flow's own. Sent as
17976
+ * the complete set: it replaces whatever the variant had, so omit it to leave the
17977
+ * set alone and send [] to clear it. Improv flows only: a scripted variant's
17978
+ * expectations come from the agent turns on its path and are rewritten on every
17979
+ * graph edit.
17980
+ */
17981
+ additionalExpectations?: Array<EdgeCase.AdditionalExpectation>;
17982
+
17956
17983
  environmentId?: string | null;
17957
17984
 
17958
17985
  /**
@@ -17966,6 +17993,15 @@ export declare namespace CustomerFlowCreateParams {
17966
17993
 
17967
17994
  prompt?: string | null;
17968
17995
  }
17996
+
17997
+ export namespace EdgeCase {
17998
+ export interface AdditionalExpectation {
17999
+ /**
18000
+ * What the agent under test is graded against.
18001
+ */
18002
+ prompt: string;
18003
+ }
18004
+ }
17969
18005
  }
17970
18006
  }
17971
18007
 
@@ -18096,9 +18132,10 @@ export interface CustomerFlowReplaceGraphParams {
18096
18132
 
18097
18133
  export interface CustomerFlowUpdateHappyPathParams {
18098
18134
  /**
18099
- * Replaces the expectations that apply to this variant on top of the flow's. Omit
18100
- * to leave them alone, send [] to clear. Improv flows only: a scripted variant's
18101
- * expectations come from the agent turns on its path and are rewritten on the next
18135
+ * The expectations graded on this variant only, on top of the flow's own. Sent as
18136
+ * the complete set: it replaces whatever the variant had, so omit it to leave the
18137
+ * set alone and send [] to clear it. Improv flows only: a scripted variant's
18138
+ * expectations come from the agent turns on its path and are rewritten on every
18102
18139
  * graph edit.
18103
18140
  */
18104
18141
  additionalExpectations?: Array<CustomerFlowUpdateHappyPathParams.AdditionalExpectation>;
@@ -135,6 +135,7 @@ export {
135
135
  type HTTPRequestDefinitionListParams,
136
136
  } from './http-request-definition';
137
137
  export { Health, type HealthGetResponse } from './health';
138
+ export { Me, type MeGetResponse } from './me';
138
139
  export {
139
140
  Metric,
140
141
  type MetricCreateDefinitionResponse,
@@ -175,6 +176,7 @@ export {
175
176
  type MetricVariantDeleteParams,
176
177
  type MetricVariantGetByIDParams,
177
178
  } from './metric-variant';
179
+ export { Project, type ProjectListResponse } from './project';
178
180
  export {
179
181
  Simulation,
180
182
  type SimulationMockToolResponse,
@@ -0,0 +1,76 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+ import { APIPromise } from '../core/api-promise';
5
+ import { RequestOptions } from '../internal/request-options';
6
+
7
+ export class Me extends APIResource {
8
+ /**
9
+ * Returns the scope of the credential making the request, the organization it acts
10
+ * in, its default project (if any) and the permissions it was granted. Works for
11
+ * both project-scoped API keys and user-scoped credentials from the CLI or an MCP
12
+ * connector.
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const me = await client.me.get();
17
+ * ```
18
+ */
19
+ get(options?: RequestOptions): APIPromise<MeGetResponse> {
20
+ return this._client.get('/v1/me', options);
21
+ }
22
+ }
23
+
24
+ export interface MeGetResponse {
25
+ /**
26
+ * The credential making this request, and what it is bound to
27
+ */
28
+ data: MeGetResponse.Data;
29
+ }
30
+
31
+ export namespace MeGetResponse {
32
+ /**
33
+ * The credential making this request, and what it is bound to
34
+ */
35
+ export interface Data {
36
+ defaultProject: Data.DefaultProject | null;
37
+
38
+ grantedPermissions: Array<string>;
39
+
40
+ organization: Data.Organization;
41
+
42
+ scopes: Array<string>;
43
+
44
+ tokenScope: 'PROJECT' | 'USER';
45
+
46
+ user: Data.User | null;
47
+ }
48
+
49
+ export namespace Data {
50
+ export interface DefaultProject {
51
+ id: string;
52
+
53
+ name: string;
54
+
55
+ slug: string;
56
+ }
57
+
58
+ export interface Organization {
59
+ id: string;
60
+
61
+ name: string;
62
+ }
63
+
64
+ export interface User {
65
+ id: string;
66
+
67
+ email: string;
68
+
69
+ name: string | null;
70
+ }
71
+ }
72
+ }
73
+
74
+ export declare namespace Me {
75
+ export { type MeGetResponse as MeGetResponse };
76
+ }
@@ -0,0 +1,65 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+ import { APIPromise } from '../core/api-promise';
5
+ import { RequestOptions } from '../internal/request-options';
6
+
7
+ export class Project extends APIResource {
8
+ /**
9
+ * Returns every project the calling credential may act on, with the permissions it
10
+ * holds in each. A project-scoped API key returns the single project it is bound
11
+ * to. A user-scoped credential returns the projects in its organization where the
12
+ * holder is an active member. Use the returned id in the X-Roark-Project-Id
13
+ * header.
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * const projects = await client.project.list();
18
+ * ```
19
+ */
20
+ list(options?: RequestOptions): APIPromise<ProjectListResponse> {
21
+ return this._client.get('/v1/projects', options);
22
+ }
23
+ }
24
+
25
+ export interface ProjectListResponse {
26
+ /**
27
+ * Projects this credential may act on
28
+ */
29
+ data: ProjectListResponse.Data;
30
+ }
31
+
32
+ export namespace ProjectListResponse {
33
+ /**
34
+ * Projects this credential may act on
35
+ */
36
+ export interface Data {
37
+ projects: Array<Data.Project>;
38
+ }
39
+
40
+ export namespace Data {
41
+ export interface Project {
42
+ id: string;
43
+
44
+ grantedPermissions: Array<string>;
45
+
46
+ name: string;
47
+
48
+ organization: Project.Organization;
49
+
50
+ slug: string;
51
+ }
52
+
53
+ export namespace Project {
54
+ export interface Organization {
55
+ id: string;
56
+
57
+ name: string;
58
+ }
59
+ }
60
+ }
61
+ }
62
+
63
+ export declare namespace Project {
64
+ export { type ProjectListResponse as ProjectListResponse };
65
+ }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '4.10.0'; // x-release-please-version
1
+ export const VERSION = '4.12.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "4.10.0";
1
+ export declare const VERSION = "4.12.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "4.10.0";
1
+ export declare const VERSION = "4.12.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '4.10.0'; // x-release-please-version
4
+ exports.VERSION = '4.12.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '4.10.0'; // x-release-please-version
1
+ export const VERSION = '4.12.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map