@myagentroam/protocol 0.10.8 → 0.10.9

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.
package/dist/index.d.ts CHANGED
@@ -2,6 +2,7 @@ import { z } from 'zod';
2
2
  export * from './tool-result-resource.js';
3
3
  import { type ResourceOwnership } from './enterprise.js';
4
4
  export * from './chatgpt-oauth.js';
5
+ export declare const GROK_SUBSCRIPTION_BASE_URL = "https://cli-chat-proxy.grok.com/v1";
5
6
  export * from './composer-tags.js';
6
7
  export * from './enterprise.js';
7
8
  export * from './skill.js';
@@ -41,6 +42,7 @@ export declare const marAgentRuntimeCredentialCapabilitySchema: z.ZodObject<{
41
42
  fastMode: z.ZodOptional<z.ZodBoolean>;
42
43
  serviceTiers: z.ZodOptional<z.ZodArray<z.ZodEnum<["auto", "default", "flex", "priority", "fast", "ultrafast"]>, "many">>;
43
44
  namespacedTools: z.ZodOptional<z.ZodBoolean>;
45
+ responsesOptionalParameters: z.ZodOptional<z.ZodBoolean>;
44
46
  httpVersions: z.ZodEffects<z.ZodArray<z.ZodEnum<["1.1", "2"]>, "many">, ("2" | "1.1")[], ("2" | "1.1")[]>;
45
47
  }, "strict", z.ZodTypeAny, {
46
48
  apiVersion: 1;
@@ -49,6 +51,7 @@ export declare const marAgentRuntimeCredentialCapabilitySchema: z.ZodObject<{
49
51
  fastMode?: boolean | undefined;
50
52
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
51
53
  namespacedTools?: boolean | undefined;
54
+ responsesOptionalParameters?: boolean | undefined;
52
55
  }, {
53
56
  apiVersion: 1;
54
57
  websocket: boolean;
@@ -56,6 +59,7 @@ export declare const marAgentRuntimeCredentialCapabilitySchema: z.ZodObject<{
56
59
  fastMode?: boolean | undefined;
57
60
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
58
61
  namespacedTools?: boolean | undefined;
62
+ responsesOptionalParameters?: boolean | undefined;
59
63
  }>;
60
64
  export type MarAgentRuntimeCredentialCapability = z.infer<typeof marAgentRuntimeCredentialCapabilitySchema>;
61
65
  export declare const conversationHostingCapabilitySchema: z.ZodEffects<z.ZodObject<{
@@ -980,6 +984,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
980
984
  fastMode: z.ZodOptional<z.ZodBoolean>;
981
985
  serviceTiers: z.ZodOptional<z.ZodArray<z.ZodEnum<["auto", "default", "flex", "priority", "fast", "ultrafast"]>, "many">>;
982
986
  namespacedTools: z.ZodOptional<z.ZodBoolean>;
987
+ responsesOptionalParameters: z.ZodOptional<z.ZodBoolean>;
983
988
  httpVersions: z.ZodEffects<z.ZodArray<z.ZodEnum<["1.1", "2"]>, "many">, ("2" | "1.1")[], ("2" | "1.1")[]>;
984
989
  }, "strict", z.ZodTypeAny, {
985
990
  apiVersion: 1;
@@ -988,6 +993,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
988
993
  fastMode?: boolean | undefined;
989
994
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
990
995
  namespacedTools?: boolean | undefined;
996
+ responsesOptionalParameters?: boolean | undefined;
991
997
  }, {
992
998
  apiVersion: 1;
993
999
  websocket: boolean;
@@ -995,6 +1001,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
995
1001
  fastMode?: boolean | undefined;
996
1002
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
997
1003
  namespacedTools?: boolean | undefined;
1004
+ responsesOptionalParameters?: boolean | undefined;
998
1005
  }>>;
999
1006
  chatgptLogin: z.ZodOptional<z.ZodObject<{
1000
1007
  apiVersion: z.ZodLiteral<1>;
@@ -1131,6 +1138,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
1131
1138
  fastMode?: boolean | undefined;
1132
1139
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
1133
1140
  namespacedTools?: boolean | undefined;
1141
+ responsesOptionalParameters?: boolean | undefined;
1134
1142
  } | undefined;
1135
1143
  chatgptLogin?: {
1136
1144
  apiVersion: 1;
@@ -1239,6 +1247,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
1239
1247
  fastMode?: boolean | undefined;
1240
1248
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
1241
1249
  namespacedTools?: boolean | undefined;
1250
+ responsesOptionalParameters?: boolean | undefined;
1242
1251
  } | undefined;
1243
1252
  chatgptLogin?: {
1244
1253
  apiVersion: 1;
@@ -1347,6 +1356,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
1347
1356
  fastMode?: boolean | undefined;
1348
1357
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
1349
1358
  namespacedTools?: boolean | undefined;
1359
+ responsesOptionalParameters?: boolean | undefined;
1350
1360
  } | undefined;
1351
1361
  chatgptLogin?: {
1352
1362
  apiVersion: 1;
@@ -1455,6 +1465,7 @@ export declare const nodeCapabilitiesSchema: z.ZodEffects<z.ZodObject<{
1455
1465
  fastMode?: boolean | undefined;
1456
1466
  serviceTiers?: ("auto" | "default" | "flex" | "priority" | "fast" | "ultrafast")[] | undefined;
1457
1467
  namespacedTools?: boolean | undefined;
1468
+ responsesOptionalParameters?: boolean | undefined;
1458
1469
  } | undefined;
1459
1470
  chatgptLogin?: {
1460
1471
  apiVersion: 1;
@@ -3152,6 +3163,25 @@ export declare const marAgentRuntimeModelConfigurationSchema: z.ZodEffects<z.Zod
3152
3163
  }>]>>;
3153
3164
  responsesToolNamespace: z.ZodOptional<z.ZodString>;
3154
3165
  responsesConfigurationUpdates: z.ZodOptional<z.ZodBoolean>;
3166
+ responsesOptionalParameters: z.ZodOptional<z.ZodObject<{
3167
+ reasoningEffort: z.ZodBoolean;
3168
+ reasoningSummary: z.ZodBoolean;
3169
+ textVerbosity: z.ZodBoolean;
3170
+ promptCacheKey: z.ZodBoolean;
3171
+ nativeTools: z.ZodOptional<z.ZodBoolean>;
3172
+ }, "strict", z.ZodTypeAny, {
3173
+ reasoningEffort: boolean;
3174
+ reasoningSummary: boolean;
3175
+ textVerbosity: boolean;
3176
+ promptCacheKey: boolean;
3177
+ nativeTools?: boolean | undefined;
3178
+ }, {
3179
+ reasoningEffort: boolean;
3180
+ reasoningSummary: boolean;
3181
+ textVerbosity: boolean;
3182
+ promptCacheKey: boolean;
3183
+ nativeTools?: boolean | undefined;
3184
+ }>>;
3155
3185
  imageGeneration: z.ZodOptional<z.ZodObject<{
3156
3186
  provider: z.ZodOptional<z.ZodString>;
3157
3187
  config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -3413,6 +3443,13 @@ export declare const marAgentRuntimeModelConfigurationSchema: z.ZodEffects<z.Zod
3413
3443
  hostedWebSearch: boolean;
3414
3444
  responsesPreviousResponseId: boolean;
3415
3445
  fastMode?: boolean | undefined;
3446
+ responsesOptionalParameters?: {
3447
+ reasoningEffort: boolean;
3448
+ reasoningSummary: boolean;
3449
+ textVerbosity: boolean;
3450
+ promptCacheKey: boolean;
3451
+ nativeTools?: boolean | undefined;
3452
+ } | undefined;
3416
3453
  credential?: {
3417
3454
  value: string;
3418
3455
  type: "INLINE_API_KEY";
@@ -3488,6 +3525,13 @@ export declare const marAgentRuntimeModelConfigurationSchema: z.ZodEffects<z.Zod
3488
3525
  reasoningEfforts: ("low" | "medium" | "high" | "xhigh" | "max" | "ultra")[];
3489
3526
  hostedWebSearch: boolean;
3490
3527
  fastMode?: boolean | undefined;
3528
+ responsesOptionalParameters?: {
3529
+ reasoningEffort: boolean;
3530
+ reasoningSummary: boolean;
3531
+ textVerbosity: boolean;
3532
+ promptCacheKey: boolean;
3533
+ nativeTools?: boolean | undefined;
3534
+ } | undefined;
3491
3535
  credential?: {
3492
3536
  value: string;
3493
3537
  type: "INLINE_API_KEY";
@@ -3737,6 +3781,25 @@ export declare const marAgentRuntimeCompactConfigurationSchema: z.ZodObject<{
3737
3781
  }>]>>;
3738
3782
  responsesToolNamespace: z.ZodOptional<z.ZodString>;
3739
3783
  responsesConfigurationUpdates: z.ZodOptional<z.ZodBoolean>;
3784
+ responsesOptionalParameters: z.ZodOptional<z.ZodObject<{
3785
+ reasoningEffort: z.ZodBoolean;
3786
+ reasoningSummary: z.ZodBoolean;
3787
+ textVerbosity: z.ZodBoolean;
3788
+ promptCacheKey: z.ZodBoolean;
3789
+ nativeTools: z.ZodOptional<z.ZodBoolean>;
3790
+ }, "strict", z.ZodTypeAny, {
3791
+ reasoningEffort: boolean;
3792
+ reasoningSummary: boolean;
3793
+ textVerbosity: boolean;
3794
+ promptCacheKey: boolean;
3795
+ nativeTools?: boolean | undefined;
3796
+ }, {
3797
+ reasoningEffort: boolean;
3798
+ reasoningSummary: boolean;
3799
+ textVerbosity: boolean;
3800
+ promptCacheKey: boolean;
3801
+ nativeTools?: boolean | undefined;
3802
+ }>>;
3740
3803
  imageGeneration: z.ZodOptional<z.ZodObject<{
3741
3804
  provider: z.ZodOptional<z.ZodString>;
3742
3805
  config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -3998,6 +4061,13 @@ export declare const marAgentRuntimeCompactConfigurationSchema: z.ZodObject<{
3998
4061
  hostedWebSearch: boolean;
3999
4062
  responsesPreviousResponseId: boolean;
4000
4063
  fastMode?: boolean | undefined;
4064
+ responsesOptionalParameters?: {
4065
+ reasoningEffort: boolean;
4066
+ reasoningSummary: boolean;
4067
+ textVerbosity: boolean;
4068
+ promptCacheKey: boolean;
4069
+ nativeTools?: boolean | undefined;
4070
+ } | undefined;
4001
4071
  credential?: {
4002
4072
  value: string;
4003
4073
  type: "INLINE_API_KEY";
@@ -4073,6 +4143,13 @@ export declare const marAgentRuntimeCompactConfigurationSchema: z.ZodObject<{
4073
4143
  reasoningEfforts: ("low" | "medium" | "high" | "xhigh" | "max" | "ultra")[];
4074
4144
  hostedWebSearch: boolean;
4075
4145
  fastMode?: boolean | undefined;
4146
+ responsesOptionalParameters?: {
4147
+ reasoningEffort: boolean;
4148
+ reasoningSummary: boolean;
4149
+ textVerbosity: boolean;
4150
+ promptCacheKey: boolean;
4151
+ nativeTools?: boolean | undefined;
4152
+ } | undefined;
4076
4153
  credential?: {
4077
4154
  value: string;
4078
4155
  type: "INLINE_API_KEY";
@@ -4314,6 +4391,25 @@ export declare const marAgentModelTransportTestInputSchema: z.ZodObject<{
4314
4391
  }>]>>;
4315
4392
  responsesToolNamespace: z.ZodOptional<z.ZodString>;
4316
4393
  responsesConfigurationUpdates: z.ZodOptional<z.ZodBoolean>;
4394
+ responsesOptionalParameters: z.ZodOptional<z.ZodObject<{
4395
+ reasoningEffort: z.ZodBoolean;
4396
+ reasoningSummary: z.ZodBoolean;
4397
+ textVerbosity: z.ZodBoolean;
4398
+ promptCacheKey: z.ZodBoolean;
4399
+ nativeTools: z.ZodOptional<z.ZodBoolean>;
4400
+ }, "strict", z.ZodTypeAny, {
4401
+ reasoningEffort: boolean;
4402
+ reasoningSummary: boolean;
4403
+ textVerbosity: boolean;
4404
+ promptCacheKey: boolean;
4405
+ nativeTools?: boolean | undefined;
4406
+ }, {
4407
+ reasoningEffort: boolean;
4408
+ reasoningSummary: boolean;
4409
+ textVerbosity: boolean;
4410
+ promptCacheKey: boolean;
4411
+ nativeTools?: boolean | undefined;
4412
+ }>>;
4317
4413
  imageGeneration: z.ZodOptional<z.ZodObject<{
4318
4414
  provider: z.ZodOptional<z.ZodString>;
4319
4415
  config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -4575,6 +4671,13 @@ export declare const marAgentModelTransportTestInputSchema: z.ZodObject<{
4575
4671
  hostedWebSearch: boolean;
4576
4672
  responsesPreviousResponseId: boolean;
4577
4673
  fastMode?: boolean | undefined;
4674
+ responsesOptionalParameters?: {
4675
+ reasoningEffort: boolean;
4676
+ reasoningSummary: boolean;
4677
+ textVerbosity: boolean;
4678
+ promptCacheKey: boolean;
4679
+ nativeTools?: boolean | undefined;
4680
+ } | undefined;
4578
4681
  credential?: {
4579
4682
  value: string;
4580
4683
  type: "INLINE_API_KEY";
@@ -4650,6 +4753,13 @@ export declare const marAgentModelTransportTestInputSchema: z.ZodObject<{
4650
4753
  reasoningEfforts: ("low" | "medium" | "high" | "xhigh" | "max" | "ultra")[];
4651
4754
  hostedWebSearch: boolean;
4652
4755
  fastMode?: boolean | undefined;
4756
+ responsesOptionalParameters?: {
4757
+ reasoningEffort: boolean;
4758
+ reasoningSummary: boolean;
4759
+ textVerbosity: boolean;
4760
+ promptCacheKey: boolean;
4761
+ nativeTools?: boolean | undefined;
4762
+ } | undefined;
4653
4763
  credential?: {
4654
4764
  value: string;
4655
4765
  type: "INLINE_API_KEY";
@@ -4742,31 +4852,70 @@ export declare const marAgentModelTransportTestResultSchema: z.ZodDiscriminatedU
4742
4852
  code: z.ZodNull;
4743
4853
  message: z.ZodNull;
4744
4854
  httpStatus: z.ZodNull;
4855
+ requestId: z.ZodOptional<z.ZodString>;
4745
4856
  }, "strict", z.ZodTypeAny, {
4746
4857
  code: null;
4747
4858
  message: null;
4748
4859
  success: true;
4749
4860
  httpStatus: null;
4861
+ requestId?: string | undefined;
4750
4862
  }, {
4751
4863
  code: null;
4752
4864
  message: null;
4753
4865
  success: true;
4754
4866
  httpStatus: null;
4867
+ requestId?: string | undefined;
4755
4868
  }>, z.ZodObject<{
4756
4869
  success: z.ZodLiteral<false>;
4757
4870
  code: z.ZodString;
4758
4871
  message: z.ZodString;
4759
4872
  httpStatus: z.ZodNullable<z.ZodNumber>;
4873
+ requestId: z.ZodOptional<z.ZodString>;
4874
+ response: z.ZodOptional<z.ZodObject<{
4875
+ body: z.ZodString;
4876
+ bodyTruncated: z.ZodBoolean;
4877
+ contentType: z.ZodNullable<z.ZodString>;
4878
+ requestId: z.ZodNullable<z.ZodString>;
4879
+ retryAfter: z.ZodNullable<z.ZodString>;
4880
+ }, "strict", z.ZodTypeAny, {
4881
+ requestId: string | null;
4882
+ body: string;
4883
+ bodyTruncated: boolean;
4884
+ contentType: string | null;
4885
+ retryAfter: string | null;
4886
+ }, {
4887
+ requestId: string | null;
4888
+ body: string;
4889
+ bodyTruncated: boolean;
4890
+ contentType: string | null;
4891
+ retryAfter: string | null;
4892
+ }>>;
4760
4893
  }, "strict", z.ZodTypeAny, {
4761
4894
  code: string;
4762
4895
  message: string;
4763
4896
  success: false;
4764
4897
  httpStatus: number | null;
4898
+ requestId?: string | undefined;
4899
+ response?: {
4900
+ requestId: string | null;
4901
+ body: string;
4902
+ bodyTruncated: boolean;
4903
+ contentType: string | null;
4904
+ retryAfter: string | null;
4905
+ } | undefined;
4765
4906
  }, {
4766
4907
  code: string;
4767
4908
  message: string;
4768
4909
  success: false;
4769
4910
  httpStatus: number | null;
4911
+ requestId?: string | undefined;
4912
+ response?: {
4913
+ requestId: string | null;
4914
+ body: string;
4915
+ bodyTruncated: boolean;
4916
+ contentType: string | null;
4917
+ retryAfter: string | null;
4918
+ } | undefined;
4770
4919
  }>]>;
4771
4920
  export type MarAgentModelTransportTestResult = z.infer<typeof marAgentModelTransportTestResultSchema>;
4772
4921
  export declare const marAgentStoredModelConfigurationSchema: z.ZodEffects<z.ZodObject<{
@@ -4916,7 +5065,7 @@ export type CodexCredentialOwnership = z.infer<typeof codexCredentialOwnershipSc
4916
5065
  export declare const codexCredentialSummarySchema: z.ZodObject<{
4917
5066
  id: z.ZodString;
4918
5067
  name: z.ZodString;
4919
- type: z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH"]>;
5068
+ type: z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH", "XAI_OAUTH"]>;
4920
5069
  authorization: z.ZodOptional<z.ZodEnum<["AUTHORIZED", "UNAUTHORIZED"]>>;
4921
5070
  ownership: z.ZodDiscriminatedUnion<"ownerType", [z.ZodObject<{
4922
5071
  ownerType: z.ZodLiteral<"PERSONAL">;
@@ -4968,7 +5117,7 @@ export declare const codexCredentialSummarySchema: z.ZodObject<{
4968
5117
  revision: z.ZodNumber;
4969
5118
  }, "strict", z.ZodTypeAny, {
4970
5119
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
4971
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5120
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
4972
5121
  name: string;
4973
5122
  id: string;
4974
5123
  revision: number;
@@ -4995,7 +5144,7 @@ export declare const codexCredentialSummarySchema: z.ZodObject<{
4995
5144
  earliestRefreshAt?: number | null | undefined;
4996
5145
  }, {
4997
5146
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
4998
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5147
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
4999
5148
  name: string;
5000
5149
  id: string;
5001
5150
  revision: number;
@@ -5026,7 +5175,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5026
5175
  credential: z.ZodObject<{
5027
5176
  id: z.ZodString;
5028
5177
  name: z.ZodString;
5029
- type: z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH"]>;
5178
+ type: z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH", "XAI_OAUTH"]>;
5030
5179
  authorization: z.ZodOptional<z.ZodEnum<["AUTHORIZED", "UNAUTHORIZED"]>>;
5031
5180
  ownership: z.ZodDiscriminatedUnion<"ownerType", [z.ZodObject<{
5032
5181
  ownerType: z.ZodLiteral<"PERSONAL">;
@@ -5078,7 +5227,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5078
5227
  revision: z.ZodNumber;
5079
5228
  }, "strict", z.ZodTypeAny, {
5080
5229
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5081
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5230
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5082
5231
  name: string;
5083
5232
  id: string;
5084
5233
  revision: number;
@@ -5105,7 +5254,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5105
5254
  earliestRefreshAt?: number | null | undefined;
5106
5255
  }, {
5107
5256
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5108
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5257
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5109
5258
  name: string;
5110
5259
  id: string;
5111
5260
  revision: number;
@@ -5136,7 +5285,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5136
5285
  socks5Url: string | null;
5137
5286
  credential: {
5138
5287
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5139
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5288
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5140
5289
  name: string;
5141
5290
  id: string;
5142
5291
  revision: number;
@@ -5166,7 +5315,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5166
5315
  socks5Url: string | null;
5167
5316
  credential: {
5168
5317
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5169
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5318
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5170
5319
  name: string;
5171
5320
  id: string;
5172
5321
  revision: number;
@@ -5196,7 +5345,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5196
5345
  socks5Url: string | null;
5197
5346
  credential: {
5198
5347
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5199
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5348
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5200
5349
  name: string;
5201
5350
  id: string;
5202
5351
  revision: number;
@@ -5226,7 +5375,7 @@ export declare const codexCredentialDetailsSchema: z.ZodEffects<z.ZodObject<{
5226
5375
  socks5Url: string | null;
5227
5376
  credential: {
5228
5377
  status: "DEGRADED" | "ACTIVE" | "REAUTH_REQUIRED";
5229
- type: "CODEX_OAUTH" | "CHATGPT_OAUTH";
5378
+ type: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH";
5230
5379
  name: string;
5231
5380
  id: string;
5232
5381
  revision: number;
@@ -5318,8 +5467,11 @@ export declare const codexUsageProfileSchema: z.ZodEffects<z.ZodObject<{
5318
5467
  }[];
5319
5468
  }>;
5320
5469
  export type CodexUsageProfile = z.infer<typeof codexUsageProfileSchema>;
5321
- export declare const codexCredentialUsageSchema: z.ZodObject<{
5470
+ export declare const codexCredentialUsageSchema: z.ZodEffects<z.ZodObject<{
5322
5471
  runner: z.ZodEnum<["codex", "claude-code", "opencode", "mar-agent"]>;
5472
+ fetchedAt: z.ZodNumber;
5473
+ cached: z.ZodBoolean;
5474
+ } & {
5323
5475
  windows: z.ZodArray<z.ZodObject<{
5324
5476
  id: z.ZodString;
5325
5477
  label: z.ZodString;
@@ -5336,9 +5488,6 @@ export declare const codexCredentialUsageSchema: z.ZodObject<{
5336
5488
  usedPercentage: number;
5337
5489
  resetsAt: number | null;
5338
5490
  }>, "many">;
5339
- fetchedAt: z.ZodNumber;
5340
- cached: z.ZodBoolean;
5341
- } & {
5342
5491
  profile: z.ZodEffects<z.ZodObject<{
5343
5492
  lifetimeTokens: z.ZodNullable<z.ZodNumber>;
5344
5493
  currentDayTokens: z.ZodNullable<z.ZodNumber>;
@@ -5391,6 +5540,28 @@ export declare const codexCredentialUsageSchema: z.ZodObject<{
5391
5540
  startDate: string;
5392
5541
  }[];
5393
5542
  }>;
5543
+ subscription: z.ZodOptional<z.ZodObject<{
5544
+ provider: z.ZodLiteral<"XAI">;
5545
+ period: z.ZodEnum<["WEEKLY", "MONTHLY", "UNKNOWN"]>;
5546
+ startsAt: z.ZodNullable<z.ZodNumber>;
5547
+ resetsAt: z.ZodNullable<z.ZodNumber>;
5548
+ usedPercentage: z.ZodNullable<z.ZodNumber>;
5549
+ prepaidBalanceCents: z.ZodNullable<z.ZodNumber>;
5550
+ }, "strict", z.ZodTypeAny, {
5551
+ provider: "XAI";
5552
+ usedPercentage: number | null;
5553
+ resetsAt: number | null;
5554
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5555
+ startsAt: number | null;
5556
+ prepaidBalanceCents: number | null;
5557
+ }, {
5558
+ provider: "XAI";
5559
+ usedPercentage: number | null;
5560
+ resetsAt: number | null;
5561
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5562
+ startsAt: number | null;
5563
+ prepaidBalanceCents: number | null;
5564
+ }>>;
5394
5565
  }, "strip", z.ZodTypeAny, {
5395
5566
  runner: "mar-agent" | "codex" | "claude-code" | "opencode";
5396
5567
  windows: {
@@ -5411,6 +5582,70 @@ export declare const codexCredentialUsageSchema: z.ZodObject<{
5411
5582
  startDate: string;
5412
5583
  }[];
5413
5584
  };
5585
+ subscription?: {
5586
+ provider: "XAI";
5587
+ usedPercentage: number | null;
5588
+ resetsAt: number | null;
5589
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5590
+ startsAt: number | null;
5591
+ prepaidBalanceCents: number | null;
5592
+ } | undefined;
5593
+ }, {
5594
+ runner: "mar-agent" | "codex" | "claude-code" | "opencode";
5595
+ windows: {
5596
+ label: string;
5597
+ id: string;
5598
+ usedPercentage: number;
5599
+ resetsAt: number | null;
5600
+ }[];
5601
+ fetchedAt: number;
5602
+ cached: boolean;
5603
+ profile: {
5604
+ lifetimeTokens: number | null;
5605
+ currentDayTokens: number | null;
5606
+ lastSevenDaysTokens: number | null;
5607
+ statsAsOf: string | null;
5608
+ dailyUsageBuckets: {
5609
+ tokens: number;
5610
+ startDate: string;
5611
+ }[];
5612
+ };
5613
+ subscription?: {
5614
+ provider: "XAI";
5615
+ usedPercentage: number | null;
5616
+ resetsAt: number | null;
5617
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5618
+ startsAt: number | null;
5619
+ prepaidBalanceCents: number | null;
5620
+ } | undefined;
5621
+ }>, {
5622
+ runner: "mar-agent" | "codex" | "claude-code" | "opencode";
5623
+ windows: {
5624
+ label: string;
5625
+ id: string;
5626
+ usedPercentage: number;
5627
+ resetsAt: number | null;
5628
+ }[];
5629
+ fetchedAt: number;
5630
+ cached: boolean;
5631
+ profile: {
5632
+ lifetimeTokens: number | null;
5633
+ currentDayTokens: number | null;
5634
+ lastSevenDaysTokens: number | null;
5635
+ statsAsOf: string | null;
5636
+ dailyUsageBuckets: {
5637
+ tokens: number;
5638
+ startDate: string;
5639
+ }[];
5640
+ };
5641
+ subscription?: {
5642
+ provider: "XAI";
5643
+ usedPercentage: number | null;
5644
+ resetsAt: number | null;
5645
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5646
+ startsAt: number | null;
5647
+ prepaidBalanceCents: number | null;
5648
+ } | undefined;
5414
5649
  }, {
5415
5650
  runner: "mar-agent" | "codex" | "claude-code" | "opencode";
5416
5651
  windows: {
@@ -5431,12 +5666,20 @@ export declare const codexCredentialUsageSchema: z.ZodObject<{
5431
5666
  startDate: string;
5432
5667
  }[];
5433
5668
  };
5669
+ subscription?: {
5670
+ provider: "XAI";
5671
+ usedPercentage: number | null;
5672
+ resetsAt: number | null;
5673
+ period: "WEEKLY" | "MONTHLY" | "UNKNOWN";
5674
+ startsAt: number | null;
5675
+ prepaidBalanceCents: number | null;
5676
+ } | undefined;
5434
5677
  }>;
5435
5678
  export type CodexCredentialUsage = z.infer<typeof codexCredentialUsageSchema>;
5436
5679
  export declare const codexLoginAttemptSchema: z.ZodEffects<z.ZodObject<{
5437
5680
  id: z.ZodString;
5438
5681
  status: z.ZodEnum<["PENDING", "SUCCEEDED", "FAILED", "CANCELLED", "EXPIRED"]>;
5439
- type: z.ZodOptional<z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH"]>>;
5682
+ type: z.ZodOptional<z.ZodEnum<["CODEX_OAUTH", "CHATGPT_OAUTH", "XAI_OAUTH"]>>;
5440
5683
  userCode: z.ZodOptional<z.ZodString>;
5441
5684
  verificationUri: z.ZodOptional<z.ZodString>;
5442
5685
  expiresAt: z.ZodOptional<z.ZodNumber>;
@@ -5449,7 +5692,7 @@ export declare const codexLoginAttemptSchema: z.ZodEffects<z.ZodObject<{
5449
5692
  id: string;
5450
5693
  code?: string | undefined;
5451
5694
  message?: string | undefined;
5452
- type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | undefined;
5695
+ type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH" | undefined;
5453
5696
  verificationUri?: string | undefined;
5454
5697
  expiresAt?: number | undefined;
5455
5698
  credentialId?: string | undefined;
@@ -5460,7 +5703,7 @@ export declare const codexLoginAttemptSchema: z.ZodEffects<z.ZodObject<{
5460
5703
  id: string;
5461
5704
  code?: string | undefined;
5462
5705
  message?: string | undefined;
5463
- type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | undefined;
5706
+ type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH" | undefined;
5464
5707
  verificationUri?: string | undefined;
5465
5708
  expiresAt?: number | undefined;
5466
5709
  credentialId?: string | undefined;
@@ -5471,7 +5714,7 @@ export declare const codexLoginAttemptSchema: z.ZodEffects<z.ZodObject<{
5471
5714
  id: string;
5472
5715
  code?: string | undefined;
5473
5716
  message?: string | undefined;
5474
- type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | undefined;
5717
+ type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH" | undefined;
5475
5718
  verificationUri?: string | undefined;
5476
5719
  expiresAt?: number | undefined;
5477
5720
  credentialId?: string | undefined;
@@ -5482,7 +5725,7 @@ export declare const codexLoginAttemptSchema: z.ZodEffects<z.ZodObject<{
5482
5725
  id: string;
5483
5726
  code?: string | undefined;
5484
5727
  message?: string | undefined;
5485
- type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | undefined;
5728
+ type?: "CODEX_OAUTH" | "CHATGPT_OAUTH" | "XAI_OAUTH" | undefined;
5486
5729
  verificationUri?: string | undefined;
5487
5730
  expiresAt?: number | undefined;
5488
5731
  credentialId?: string | undefined;
package/dist/index.js CHANGED
@@ -7,6 +7,7 @@ import { workspaceDirectTransferCapabilitySchema } from './direct-transfer.js';
7
7
  import { terminalDirectCapabilitySchema } from './terminal-direct.js';
8
8
  import { chatgptLoginCapabilitySchema } from './chatgpt-oauth.js';
9
9
  export * from './chatgpt-oauth.js';
10
+ export const GROK_SUBSCRIPTION_BASE_URL = 'https://cli-chat-proxy.grok.com/v1';
10
11
  export * from './composer-tags.js';
11
12
  export * from './enterprise.js';
12
13
  export * from './skill.js';
@@ -47,6 +48,7 @@ export const marAgentRuntimeCredentialCapabilitySchema = z
47
48
  fastMode: z.boolean().optional(),
48
49
  serviceTiers: z.array(marAgentResponsesServiceTierSchema).min(1).max(6).optional(),
49
50
  namespacedTools: z.boolean().optional(),
51
+ responsesOptionalParameters: z.boolean().optional(),
50
52
  httpVersions: z
51
53
  .array(runtimeCredentialHttpVersionSchema)
52
54
  .min(1)
@@ -808,6 +810,16 @@ export const marAgentRuntimeModelConfigurationSchema = refineMarAgentModel(z
808
810
  .regex(/^[a-zA-Z][a-zA-Z0-9_]{0,63}$/u)
809
811
  .optional(),
810
812
  responsesConfigurationUpdates: z.boolean().optional(),
813
+ responsesOptionalParameters: z
814
+ .object({
815
+ reasoningEffort: z.boolean(),
816
+ reasoningSummary: z.boolean(),
817
+ textVerbosity: z.boolean(),
818
+ promptCacheKey: z.boolean(),
819
+ nativeTools: z.boolean().optional()
820
+ })
821
+ .strict()
822
+ .optional(),
811
823
  imageGeneration: marAgentImageGenerationSchema.optional()
812
824
  })
813
825
  .strip()).superRefine((configuration, context) => {
@@ -868,7 +880,8 @@ export const marAgentModelTransportTestResultSchema = z.discriminatedUnion('succ
868
880
  success: z.literal(true),
869
881
  code: z.null(),
870
882
  message: z.null(),
871
- httpStatus: z.null()
883
+ httpStatus: z.null(),
884
+ requestId: z.string().min(1).max(128).optional()
872
885
  })
873
886
  .strict(),
874
887
  z
@@ -876,7 +889,18 @@ export const marAgentModelTransportTestResultSchema = z.discriminatedUnion('succ
876
889
  success: z.literal(false),
877
890
  code: z.string().trim().min(1).max(80),
878
891
  message: z.string().trim().min(1).max(1_000),
879
- httpStatus: z.number().int().min(100).max(599).nullable()
892
+ httpStatus: z.number().int().min(100).max(599).nullable(),
893
+ requestId: z.string().min(1).max(128).optional(),
894
+ response: z
895
+ .object({
896
+ body: z.string().max(4096),
897
+ bodyTruncated: z.boolean(),
898
+ contentType: z.string().max(256).nullable(),
899
+ requestId: z.string().max(256).nullable(),
900
+ retryAfter: z.string().max(128).nullable()
901
+ })
902
+ .strict()
903
+ .optional()
880
904
  })
881
905
  .strict()
882
906
  ]);
@@ -911,7 +935,7 @@ export const codexCredentialSummarySchema = z
911
935
  .object({
912
936
  id: boundedIdentifierSchema,
913
937
  name: z.string().trim().min(1).max(128),
914
- type: z.enum(['CODEX_OAUTH', 'CHATGPT_OAUTH']),
938
+ type: z.enum(['CODEX_OAUTH', 'CHATGPT_OAUTH', 'XAI_OAUTH']),
915
939
  authorization: z.enum(['AUTHORIZED', 'UNAUTHORIZED']).optional(),
916
940
  ownership: codexCredentialOwnershipSchema,
917
941
  status: z.enum(['ACTIVE', 'DEGRADED', 'REAUTH_REQUIRED']),
@@ -996,14 +1020,31 @@ export const codexUsageProfileSchema = z
996
1020
  message: 'daily usage dates must be unique'
997
1021
  });
998
1022
  });
999
- export const codexCredentialUsageSchema = runnerUsageSchema.extend({
1000
- profile: codexUsageProfileSchema
1023
+ export const codexCredentialUsageSchema = runnerUsageSchema
1024
+ .extend({
1025
+ windows: z.array(runnerUsageWindowSchema).max(8),
1026
+ profile: codexUsageProfileSchema,
1027
+ subscription: z
1028
+ .object({
1029
+ provider: z.literal('XAI'),
1030
+ period: z.enum(['WEEKLY', 'MONTHLY', 'UNKNOWN']),
1031
+ startsAt: nonnegativeSafeIntegerSchema.nullable(),
1032
+ resetsAt: nonnegativeSafeIntegerSchema.nullable(),
1033
+ usedPercentage: z.number().finite().min(0).max(100).nullable(),
1034
+ prepaidBalanceCents: nonnegativeSafeIntegerSchema.nullable()
1035
+ })
1036
+ .strict()
1037
+ .optional()
1038
+ })
1039
+ .superRefine((usage, context) => {
1040
+ if (!usage.subscription && usage.windows.length === 0)
1041
+ context.addIssue({ code: 'custom', message: 'Usage requires a window or subscription data' });
1001
1042
  });
1002
1043
  export const codexLoginAttemptSchema = z
1003
1044
  .object({
1004
1045
  id: boundedIdentifierSchema,
1005
1046
  status: z.enum(['PENDING', 'SUCCEEDED', 'FAILED', 'CANCELLED', 'EXPIRED']),
1006
- type: z.enum(['CODEX_OAUTH', 'CHATGPT_OAUTH']).optional(),
1047
+ type: z.enum(['CODEX_OAUTH', 'CHATGPT_OAUTH', 'XAI_OAUTH']).optional(),
1007
1048
  userCode: z.string().trim().min(1).max(128).optional(),
1008
1049
  verificationUri: z.string().url().max(2048).optional(),
1009
1050
  expiresAt: nonnegativeSafeIntegerSchema.optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myagentroam/protocol",
3
- "version": "0.10.8",
3
+ "version": "0.10.9",
4
4
  "description": "Shared runtime protocol schemas for MyAgentRoam.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",