@wdio/browserstack-service 9.29.1 → 9.30.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 (175) hide show
  1. package/build/Percy/Percy-Handler.d.ts +0 -1
  2. package/build/Percy/Percy.d.ts +0 -1
  3. package/build/Percy/PercyBinary.d.ts +0 -1
  4. package/build/Percy/PercyCaptureMap.d.ts +0 -1
  5. package/build/Percy/PercyHelper.d.ts +0 -1
  6. package/build/Percy/PercyLogger.d.ts +0 -1
  7. package/build/Percy/PercySDK.d.ts +0 -1
  8. package/build/accessibility-handler.d.ts +22 -1
  9. package/build/ai-handler.d.ts +0 -1
  10. package/build/bstackLogger.d.ts +0 -1
  11. package/build/cleanup.d.ts +0 -1
  12. package/build/cleanup.js +260 -202
  13. package/build/cli/apiUtils.d.ts +0 -1
  14. package/build/cli/cliLogger.d.ts +0 -1
  15. package/build/cli/cliUtils.d.ts +0 -8
  16. package/build/cli/eventDispatcher.d.ts +0 -1
  17. package/build/cli/frameworks/automationFramework.d.ts +0 -1
  18. package/build/cli/frameworks/constants/automationFrameworkConstants.d.ts +0 -1
  19. package/build/cli/frameworks/constants/testFrameworkConstants.d.ts +0 -1
  20. package/build/cli/frameworks/testFramework.d.ts +0 -1
  21. package/build/cli/frameworks/wdioAutomationFramework.d.ts +0 -1
  22. package/build/cli/frameworks/wdioMochaTestFramework.d.ts +0 -1
  23. package/build/cli/grpcClient.d.ts +2 -3
  24. package/build/cli/index.d.ts +2 -2
  25. package/build/cli/instances/automationFrameworkInstance.d.ts +0 -1
  26. package/build/cli/instances/testFrameworkInstance.d.ts +0 -1
  27. package/build/cli/instances/trackedContext.d.ts +0 -1
  28. package/build/cli/instances/trackedInstance.d.ts +0 -1
  29. package/build/cli/modules/accessibilityModule.d.ts +2 -2
  30. package/build/cli/modules/automateModule.d.ts +0 -1
  31. package/build/cli/modules/baseModule.d.ts +1 -2
  32. package/build/cli/modules/customTagsModule.d.ts +0 -1
  33. package/build/cli/modules/observabilityModule.d.ts +0 -1
  34. package/build/cli/modules/percyModule.d.ts +0 -1
  35. package/build/cli/modules/testHubModule.d.ts +0 -1
  36. package/build/cli/modules/webdriverIOModule.d.ts +0 -1
  37. package/build/cli/states/automationFrameworkState.d.ts +0 -1
  38. package/build/cli/states/hookState.d.ts +0 -1
  39. package/build/cli/states/testFrameworkState.d.ts +0 -1
  40. package/build/config.d.ts +2 -3
  41. package/build/constants.d.ts +2 -12
  42. package/build/crash-reporter.d.ts +0 -1
  43. package/build/cucumber-types.d.ts +0 -1
  44. package/build/custom-tags-handler.d.ts +0 -1
  45. package/build/customTags.d.ts +0 -1
  46. package/build/data-store.d.ts +0 -1
  47. package/build/exitHandler.d.ts +0 -1
  48. package/build/fetchWrapper.d.ts +2 -19
  49. package/build/fileStream.d.ts +0 -1
  50. package/build/grpc/generated/sdk-messages-accessibility.d.ts +75 -0
  51. package/build/grpc/generated/sdk-messages-ai.d.ts +51 -0
  52. package/build/grpc/generated/sdk-messages-observability.d.ts +43 -0
  53. package/build/grpc/generated/sdk-messages-percy.d.ts +15 -0
  54. package/build/grpc/generated/sdk-messages-testhub.d.ts +15 -0
  55. package/build/grpc/generated/sdk-messages.d.ts +287 -0
  56. package/build/grpc/generated/sdk.d.ts +281 -0
  57. package/build/grpc/index.d.ts +42 -0
  58. package/build/index.d.ts +7 -1
  59. package/build/index.js +7106 -995
  60. package/build/insights-handler.d.ts +2 -1
  61. package/build/instrumentation/funnelInstrumentation.d.ts +0 -1
  62. package/build/instrumentation/performance/constants.d.ts +0 -1
  63. package/build/instrumentation/performance/performance-tester.d.ts +0 -1
  64. package/build/launcher.d.ts +0 -1
  65. package/build/log4jsAppender.d.ts +0 -1
  66. package/build/logPatcher.d.ts +0 -1
  67. package/build/logReportingAPI.d.ts +0 -1
  68. package/build/module-hook-tracker.d.ts +0 -1
  69. package/build/reporter.d.ts +0 -1
  70. package/build/request-handler.d.ts +0 -1
  71. package/build/scripts/accessibility-scripts.d.ts +0 -1
  72. package/build/service.d.ts +0 -1
  73. package/build/testHub/utils.d.ts +0 -1
  74. package/build/testOps/featureStats.d.ts +0 -1
  75. package/build/testOps/featureUsage.d.ts +0 -1
  76. package/build/testOps/listener.d.ts +0 -1
  77. package/build/testOps/openRunsJournal.d.ts +6 -0
  78. package/build/testOps/requestUtils.d.ts +0 -1
  79. package/build/testOps/testOpsConfig.d.ts +0 -1
  80. package/build/testOps/usageStats.d.ts +0 -1
  81. package/build/testorchestration/apply-orchestration.d.ts +0 -1
  82. package/build/testorchestration/helpers.d.ts +0 -1
  83. package/build/testorchestration/request-utils.d.ts +0 -1
  84. package/build/testorchestration/test-ordering-server.d.ts +0 -1
  85. package/build/testorchestration/testorcherstrationhandler.d.ts +0 -1
  86. package/build/testorchestration/testorcherstrationutils.d.ts +0 -1
  87. package/build/types.d.ts +0 -8
  88. package/build/util.d.ts +11 -2
  89. package/package.json +43 -15
  90. package/src/proto/browserstack/sdk/v1/sdk-messages-accessibility.proto +71 -0
  91. package/src/proto/browserstack/sdk/v1/sdk-messages-ai.proto +48 -0
  92. package/src/proto/browserstack/sdk/v1/sdk-messages-observability.proto +39 -0
  93. package/src/proto/browserstack/sdk/v1/sdk-messages-percy.proto +10 -0
  94. package/src/proto/browserstack/sdk/v1/sdk-messages-testhub.proto +10 -0
  95. package/src/proto/browserstack/sdk/v1/sdk-messages.proto +276 -0
  96. package/src/proto/browserstack/sdk/v1/sdk.proto +41 -0
  97. package/build/Percy/Percy-Handler.d.ts.map +0 -1
  98. package/build/Percy/Percy.d.ts.map +0 -1
  99. package/build/Percy/PercyBinary.d.ts.map +0 -1
  100. package/build/Percy/PercyCaptureMap.d.ts.map +0 -1
  101. package/build/Percy/PercyHelper.d.ts.map +0 -1
  102. package/build/Percy/PercyLogger.d.ts.map +0 -1
  103. package/build/Percy/PercySDK.d.ts.map +0 -1
  104. package/build/accessibility-handler.d.ts.map +0 -1
  105. package/build/ai-handler.d.ts.map +0 -1
  106. package/build/bstackLogger.d.ts.map +0 -1
  107. package/build/caCert.d.ts +0 -7
  108. package/build/caCert.d.ts.map +0 -1
  109. package/build/cleanup.d.ts.map +0 -1
  110. package/build/cli/apiUtils.d.ts.map +0 -1
  111. package/build/cli/cliLogger.d.ts.map +0 -1
  112. package/build/cli/cliUtils.d.ts.map +0 -1
  113. package/build/cli/eventDispatcher.d.ts.map +0 -1
  114. package/build/cli/frameworks/automationFramework.d.ts.map +0 -1
  115. package/build/cli/frameworks/constants/automationFrameworkConstants.d.ts.map +0 -1
  116. package/build/cli/frameworks/constants/testFrameworkConstants.d.ts.map +0 -1
  117. package/build/cli/frameworks/testFramework.d.ts.map +0 -1
  118. package/build/cli/frameworks/wdioAutomationFramework.d.ts.map +0 -1
  119. package/build/cli/frameworks/wdioMochaTestFramework.d.ts.map +0 -1
  120. package/build/cli/grpcClient.d.ts.map +0 -1
  121. package/build/cli/index.d.ts.map +0 -1
  122. package/build/cli/instances/automationFrameworkInstance.d.ts.map +0 -1
  123. package/build/cli/instances/testFrameworkInstance.d.ts.map +0 -1
  124. package/build/cli/instances/trackedContext.d.ts.map +0 -1
  125. package/build/cli/instances/trackedInstance.d.ts.map +0 -1
  126. package/build/cli/modules/accessibilityModule.d.ts.map +0 -1
  127. package/build/cli/modules/automateModule.d.ts.map +0 -1
  128. package/build/cli/modules/baseModule.d.ts.map +0 -1
  129. package/build/cli/modules/customTagsModule.d.ts.map +0 -1
  130. package/build/cli/modules/observabilityModule.d.ts.map +0 -1
  131. package/build/cli/modules/percyModule.d.ts.map +0 -1
  132. package/build/cli/modules/testHubModule.d.ts.map +0 -1
  133. package/build/cli/modules/webdriverIOModule.d.ts.map +0 -1
  134. package/build/cli/states/automationFrameworkState.d.ts.map +0 -1
  135. package/build/cli/states/hookState.d.ts.map +0 -1
  136. package/build/cli/states/testFrameworkState.d.ts.map +0 -1
  137. package/build/config.d.ts.map +0 -1
  138. package/build/constants.d.ts.map +0 -1
  139. package/build/crash-reporter.d.ts.map +0 -1
  140. package/build/cucumber-types.d.ts.map +0 -1
  141. package/build/custom-tags-handler.d.ts.map +0 -1
  142. package/build/customTags.d.ts.map +0 -1
  143. package/build/data-store.d.ts.map +0 -1
  144. package/build/exitHandler.d.ts.map +0 -1
  145. package/build/fetchWrapper.d.ts.map +0 -1
  146. package/build/fileStream.d.ts.map +0 -1
  147. package/build/index.d.ts.map +0 -1
  148. package/build/insights-handler.d.ts.map +0 -1
  149. package/build/instrumentation/funnelInstrumentation.d.ts.map +0 -1
  150. package/build/instrumentation/performance/constants.d.ts.map +0 -1
  151. package/build/instrumentation/performance/performance-tester.d.ts.map +0 -1
  152. package/build/launcher.d.ts.map +0 -1
  153. package/build/log4jsAppender.d.ts.map +0 -1
  154. package/build/logPatcher.d.ts.map +0 -1
  155. package/build/logReportingAPI.d.ts.map +0 -1
  156. package/build/module-hook-tracker.d.ts.map +0 -1
  157. package/build/reporter.d.ts.map +0 -1
  158. package/build/request-handler.d.ts.map +0 -1
  159. package/build/scripts/accessibility-scripts.d.ts.map +0 -1
  160. package/build/service.d.ts.map +0 -1
  161. package/build/testHub/utils.d.ts.map +0 -1
  162. package/build/testOps/featureStats.d.ts.map +0 -1
  163. package/build/testOps/featureUsage.d.ts.map +0 -1
  164. package/build/testOps/listener.d.ts.map +0 -1
  165. package/build/testOps/requestUtils.d.ts.map +0 -1
  166. package/build/testOps/testOpsConfig.d.ts.map +0 -1
  167. package/build/testOps/usageStats.d.ts.map +0 -1
  168. package/build/testorchestration/apply-orchestration.d.ts.map +0 -1
  169. package/build/testorchestration/helpers.d.ts.map +0 -1
  170. package/build/testorchestration/request-utils.d.ts.map +0 -1
  171. package/build/testorchestration/test-ordering-server.d.ts.map +0 -1
  172. package/build/testorchestration/testorcherstrationhandler.d.ts.map +0 -1
  173. package/build/testorchestration/testorcherstrationutils.d.ts.map +0 -1
  174. package/build/types.d.ts.map +0 -1
  175. package/build/util.d.ts.map +0 -1
@@ -21,6 +21,8 @@ declare class _InsightsHandler {
21
21
  private listener;
22
22
  currentTestId: string | undefined;
23
23
  cbtQueue: Array<CBTData>;
24
+ private readonly _ltsActive;
25
+ private readonly _ltsSessionId;
24
26
  constructor(_browser: WebdriverIO.Browser | WebdriverIO.MultiRemoteBrowser, _framework?: string | undefined, _userCaps?: Capabilities.ResolvedTestrunnerCapabilities, _options?: BrowserstackConfig & BrowserstackOptions);
25
27
  _isAppAutomate(): boolean;
26
28
  registerListeners(): void;
@@ -94,4 +96,3 @@ declare class _InsightsHandler {
94
96
  declare const InsightsHandler: typeof _InsightsHandler;
95
97
  type InsightsHandler = _InsightsHandler;
96
98
  export default InsightsHandler;
97
- //# sourceMappingURL=insights-handler.d.ts.map
@@ -14,4 +14,3 @@ interface AuthResult {
14
14
  }
15
15
  export declare function handleHealingInstrumentation(authResult: AuthResult, config: BrowserStackConfig, isSelfHealEnabled: boolean | undefined): void;
16
16
  export {};
17
- //# sourceMappingURL=funnelInstrumentation.d.ts.map
@@ -148,4 +148,3 @@ export declare const DISPATCHER_EVENTS: {
148
148
  LOG_CREATED: string;
149
149
  ENQUEUE_TEST: string;
150
150
  };
151
- //# sourceMappingURL=constants.d.ts.map
@@ -55,4 +55,3 @@ export default class PerformanceTester {
55
55
  static uploadEventsData(): Promise<void>;
56
56
  }
57
57
  export {};
58
- //# sourceMappingURL=performance-tester.d.ts.map
@@ -46,4 +46,3 @@ export default class BrowserstackLauncherService implements Services.ServiceInst
46
46
  _getClientBuildUuid(): string;
47
47
  }
48
48
  export {};
49
- //# sourceMappingURL=launcher.d.ts.map
@@ -4,4 +4,3 @@ export declare const configure: (config: {
4
4
  type: string;
5
5
  };
6
6
  }, layouts: any) => Function;
7
- //# sourceMappingURL=log4jsAppender.d.ts.map
@@ -9,4 +9,3 @@ declare class logPatcher extends Transport {
9
9
  log: (...message: unknown[]) => void;
10
10
  }
11
11
  export default logPatcher;
12
- //# sourceMappingURL=logPatcher.d.ts.map
@@ -12,4 +12,3 @@ declare class logReportingAPI extends Transport {
12
12
  error: (message: string | null) => void;
13
13
  }
14
14
  export default logReportingAPI;
15
- //# sourceMappingURL=logReportingAPI.d.ts.map
@@ -44,4 +44,3 @@ export declare class ModuleHookTracker {
44
44
  * Global instance export for convenience
45
45
  */
46
46
  export declare const moduleHookTracker: ModuleHookTracker;
47
- //# sourceMappingURL=module-hook-tracker.d.ts.map
@@ -38,4 +38,3 @@ declare class _TestReporter extends WDIOReporter {
38
38
  declare const TestReporter: typeof _TestReporter;
39
39
  type TestReporter = _TestReporter;
40
40
  export default TestReporter;
41
- //# sourceMappingURL=reporter.d.ts.map
@@ -16,4 +16,3 @@ export default class RequestQueueHandler {
16
16
  removeEventBatchPolling(tag: string): void;
17
17
  shouldProceed(): boolean;
18
18
  }
19
- //# sourceMappingURL=request-handler.d.ts.map
@@ -34,4 +34,3 @@ declare class AccessibilityScripts {
34
34
  declare const _default: AccessibilityScripts;
35
35
  export default _default;
36
36
  export { Command };
37
- //# sourceMappingURL=accessibility-scripts.d.ts.map
@@ -83,4 +83,3 @@ export default class BrowserstackService implements Services.ServiceInstance {
83
83
  private _executeCommand;
84
84
  private saveWorkerData;
85
85
  }
86
- //# sourceMappingURL=service.d.ts.map
@@ -17,4 +17,3 @@ export declare const getProductMapForBuildStartCall: (config: BrowserStackConfig
17
17
  [key: string]: boolean;
18
18
  };
19
19
  export {};
20
- //# sourceMappingURL=utils.d.ts.map
@@ -48,4 +48,3 @@ declare class FeatureStats {
48
48
  static fromJSON(json: Feature): FeatureStats;
49
49
  }
50
50
  export default FeatureStats;
51
- //# sourceMappingURL=featureStats.d.ts.map
@@ -19,4 +19,3 @@ declare class FeatureUsage {
19
19
  };
20
20
  }
21
21
  export default FeatureUsage;
22
- //# sourceMappingURL=featureUsage.d.ts.map
@@ -37,4 +37,3 @@ declare class Listener {
37
37
  private getEventForHook;
38
38
  }
39
39
  export default Listener;
40
- //# sourceMappingURL=listener.d.ts.map
@@ -0,0 +1,6 @@
1
+ import type { TestData } from '../types.js';
2
+ export declare const ORPHAN_FAILURE_REASON = "Test run did not complete: the process was interrupted or terminated before the test finished (finalized by BrowserStack SDK exit cleanup)";
3
+ export declare function recordOpenRun(testData: TestData): void;
4
+ export declare function clearOpenRun(uuid?: string): void;
5
+ export declare function collectOrphanedRuns(): TestData[];
6
+ export declare function finalizeOrphanedRuns(): Promise<number>;
@@ -1,4 +1,3 @@
1
1
  import type { UploadType } from '../types.js';
2
2
  export declare function uploadEventData(eventData: UploadType | Array<UploadType>, eventUrl?: string): Promise<void>;
3
3
  export declare function sendScreenshots(eventData: Array<UploadType>): Promise<void>;
4
- //# sourceMappingURL=requestUtils.d.ts.map
@@ -8,4 +8,3 @@ declare class TestOpsConfig {
8
8
  constructor(enabled?: boolean, manuallySet?: boolean);
9
9
  }
10
10
  export default TestOpsConfig;
11
- //# sourceMappingURL=testOpsConfig.d.ts.map
@@ -418,4 +418,3 @@ declare class UsageStats {
418
418
  static fromJSON(data: UsageStat): UsageStats;
419
419
  }
420
420
  export default UsageStats;
421
- //# sourceMappingURL=usageStats.d.ts.map
@@ -4,4 +4,3 @@
4
4
  */
5
5
  export declare function applyOrchestrationIfEnabled(specs: string[], config: Record<string, any>): Promise<string[]>;
6
6
  export default applyOrchestrationIfEnabled;
7
- //# sourceMappingURL=apply-orchestration.d.ts.map
@@ -50,4 +50,3 @@ export declare function getHostInfo(): {
50
50
  */
51
51
  export declare function getGitMetadataForAISelection(folders?: string[] | null): GitAISelectionResult[];
52
52
  export {};
53
- //# sourceMappingURL=helpers.d.ts.map
@@ -20,4 +20,3 @@ export declare class RequestUtils {
20
20
  }): Promise<Record<string, unknown> | string | null>;
21
21
  }
22
22
  export default RequestUtils;
23
- //# sourceMappingURL=request-utils.d.ts.map
@@ -31,4 +31,3 @@ export declare class TestOrderingServer {
31
31
  getSplitTestsApiCallCount(): number;
32
32
  }
33
33
  export default TestOrderingServer;
34
- //# sourceMappingURL=test-ordering-server.d.ts.map
@@ -53,4 +53,3 @@ export declare class TestOrchestrationHandler {
53
53
  getOrderingInstrumentationData(): Record<string, OrderingInstrumentationValue>;
54
54
  }
55
55
  export default TestOrchestrationHandler;
56
- //# sourceMappingURL=testorcherstrationhandler.d.ts.map
@@ -98,4 +98,3 @@ export declare class OrchestrationUtils {
98
98
  getBuildStartData(): Record<string, unknown>;
99
99
  }
100
100
  export default OrchestrationUtils;
101
- //# sourceMappingURL=testorcherstrationutils.d.ts.map
package/build/types.d.ts CHANGED
@@ -53,13 +53,6 @@ export interface BrowserstackOptions extends Options.Testrunner {
53
53
  selfHeal?: boolean;
54
54
  }
55
55
  export interface BrowserstackConfig {
56
- /**
57
- * Absolute path to a CA certificate (PEM, single cert or bundle) to trust for outbound
58
- * HTTPS when behind an SSL-inspecting corporate proxy (Zscaler/Netskope/Forcepoint).
59
- * Overridable via the `BROWSERSTACK_EXTRA_CA_CERTS` env var. Merged with the system
60
- * trust store (never replaces it).
61
- */
62
- proxyCaCertificate?: string;
63
56
  /**
64
57
  *`buildIdentifier` is a unique id to differentiate every execution that gets appended to
65
58
  * buildName. Choose your buildIdentifier format from the available expressions:
@@ -452,4 +445,3 @@ export interface FunnelData {
452
445
  event_properties: EventProperties;
453
446
  }
454
447
  export {};
455
- //# sourceMappingURL=types.d.ts.map
package/build/util.d.ts CHANGED
@@ -3,7 +3,7 @@ import type { BeforeCommandArgs, AfterCommandArgs } from '@wdio/reporter';
3
3
  import type { ColorName } from 'chalk';
4
4
  import type { UploadType, BrowserstackConfig, BrowserstackOptions, LaunchResponse } from './types.js';
5
5
  import type { ITestCaseHookParameter } from './cucumber-types.js';
6
- import type { StartBinSessionResponse } from '@browserstack/wdio-browserstack-service';
6
+ import type { StartBinSessionResponse } from './grpc/index.js';
7
7
  export type GitMetaData = {
8
8
  name: string;
9
9
  sha: string;
@@ -131,6 +131,8 @@ export declare function getCiInfo(): {
131
131
  export declare function getGitMetaData(): Promise<GitMetaData | undefined>;
132
132
  export declare function getUniqueIdentifier(test: Frameworks.Test, framework?: string): string;
133
133
  export declare function getUniqueIdentifierForCucumber(world: ITestCaseHookParameter): string;
134
+ export declare function isLoadTestingSession(): boolean;
135
+ export declare function getLtsSessionId(): string;
134
136
  export declare function getCloudProvider(browser: WebdriverIO.Browser | WebdriverIO.MultiRemoteBrowser): string;
135
137
  export declare function isBrowserstackSession(browser?: WebdriverIO.Browser | WebdriverIO.MultiRemoteBrowser): boolean | undefined;
136
138
  export declare function getScenarioExamples(world: ITestCaseHookParameter): string[] | undefined;
@@ -213,6 +215,14 @@ export declare function pollApi(url: string, params: Record<string, any>, header
213
215
  export declare function executeAccessibilityScript<ReturnType>(browser: any, fnBody: string, arg?: unknown): Promise<ReturnType>;
214
216
  export declare function generateHashCodeFromFields(fields: Array<string | object>): string;
215
217
  export declare function getBooleanValueFromString(value: string | undefined): boolean;
218
+ /**
219
+ * SDK-3737: Coerce stringified booleans ('true'/'false', any case) in a flat
220
+ * options object to real booleans, leaving every other value untouched. Boolean-
221
+ * typed accessibility options (e.g. autoScanning) are commonly supplied as
222
+ * strings from JS config / env; without coercion they fail W3C caps validation
223
+ * and are silently dropped. Only the exact strings 'true'/'false' are converted.
224
+ */
225
+ export declare function coerceStringBooleans<T extends Record<string, unknown>>(obj: T): T;
216
226
  /**
217
227
  * Validate boolean value from mixed types (boolean or string)
218
228
  * Only accepts true boolean or string "true" (case insensitive)
@@ -246,4 +256,3 @@ export declare const performO11ySync: (browser: WebdriverIO.Browser) => Promise<
246
256
  */
247
257
  export declare function isMultiRemoteCaps(capabilities: Capabilities.TestrunnerCapabilities): boolean;
248
258
  export {};
249
- //# sourceMappingURL=util.d.ts.map
package/package.json CHANGED
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "@wdio/browserstack-service",
3
- "version": "9.29.1",
3
+ "version": "9.30.0",
4
4
  "description": "WebdriverIO service for better Browserstack integration",
5
- "author": "Adam Bjerstedt <abjerstedt@gmail.com>",
6
- "homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-browserstack-service",
5
+ "author": "BrowserStack <support@browserstack.com>",
6
+ "homepage": "https://github.com/browserstack/wdio-browserstack-service",
7
7
  "license": "MIT",
8
8
  "engines": {
9
9
  "node": ">=18.20.0"
10
10
  },
11
11
  "repository": {
12
12
  "type": "git",
13
- "url": "git+https://github.com/webdriverio/webdriverio.git",
14
- "directory": "packages/wdio-browserstack-service"
13
+ "url": "git+https://github.com/browserstack/wdio-browserstack-service.git",
14
+ "directory": "packages/browserstack-service"
15
15
  },
16
16
  "keywords": [
17
17
  "webdriverio",
@@ -20,7 +20,7 @@
20
20
  "wdio-service"
21
21
  ],
22
22
  "bugs": {
23
- "url": "https://github.com/webdriverio/webdriverio/issues"
23
+ "url": "https://github.com/browserstack/wdio-browserstack-service/issues"
24
24
  },
25
25
  "type": "module",
26
26
  "types": "./build/index.d.ts",
@@ -30,20 +30,35 @@
30
30
  "import": "./build/index.js"
31
31
  },
32
32
  "./cleanup": {
33
+ "types": "./build/cleanup.d.ts",
33
34
  "import": "./build/cleanup.js",
34
35
  "source": "./src/cleanup.ts"
35
36
  }
36
37
  },
37
38
  "typeScriptVersion": "3.8.3",
39
+ "files": [
40
+ "build",
41
+ "src/proto/**/*.proto",
42
+ "browserstack-service.d.ts",
43
+ "README.md",
44
+ "LICENSE"
45
+ ],
46
+ "scripts": {
47
+ "clean": "rimraf ./build src/grpc/generated",
48
+ "generate": "buf generate",
49
+ "build": "rimraf ./build src/grpc/generated && buf generate && node ./scripts/build.mjs && tsc -p tsconfig.prod.json",
50
+ "build:watch": "node ./scripts/build.mjs --watch",
51
+ "test": "vitest --run",
52
+ "test:watch": "vitest",
53
+ "prepack": "npm run build"
54
+ },
38
55
  "dependencies": {
39
56
  "@browserstack/ai-sdk-node": "1.5.17",
40
- "@browserstack/wdio-browserstack-service": "^2.0.2",
57
+ "@bufbuild/protobuf": "^2.5.2",
58
+ "@grpc/grpc-js": "1.13.3",
41
59
  "@percy/appium-app": "^2.0.9",
42
60
  "@percy/selenium-webdriver": "^2.2.2",
43
61
  "@types/gitconfiglocal": "^2.0.1",
44
- "@wdio/logger": "9.29.1",
45
- "@wdio/reporter": "9.29.1",
46
- "@wdio/types": "9.29.1",
47
62
  "browserstack-local": "^1.5.1",
48
63
  "chalk": "^5.3.0",
49
64
  "csv-writer": "^1.6.0",
@@ -53,21 +68,34 @@
53
68
  "tar": "^7.5.11",
54
69
  "undici": "^6.24.0",
55
70
  "uuid": "^11.1.0",
56
- "webdriverio": "9.29.1",
57
71
  "winston-transport": "^4.5.0",
58
- "yauzl": "^3.0.0"
72
+ "yauzl": "^3.4.0",
73
+ "@wdio/logger": "^9.0.0",
74
+ "@wdio/reporter": "^9.0.0",
75
+ "@wdio/types": "^9.0.0",
76
+ "webdriverio": "^9.0.0"
59
77
  },
60
78
  "peerDependencies": {
61
79
  "@wdio/cli": "^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0 || ^9.0.0"
62
80
  },
63
81
  "devDependencies": {
82
+ "@bufbuild/buf": "^1.55.1",
83
+ "@changesets/cli": "^2.27.9",
64
84
  "@types/node": "^20.1.0",
65
85
  "@types/tar": "^7.0.87",
66
86
  "@types/yauzl": "^2.10.3",
67
- "@wdio/globals": "9.29.1"
87
+ "@wdio/globals": "^9.0.0",
88
+ "@wdio/logger": "^9.0.0",
89
+ "@wdio/reporter": "^9.0.0",
90
+ "@wdio/types": "^9.0.0",
91
+ "esbuild": "^0.27.2",
92
+ "rimraf": "^6.0.1",
93
+ "ts-proto": "^2.7.5",
94
+ "typescript": "^5.8.3",
95
+ "vitest": "^3.2.4",
96
+ "webdriverio": "^9.0.0"
68
97
  },
69
98
  "publishConfig": {
70
99
  "access": "public"
71
- },
72
- "gitHead": "cea4a759f7e78c798e7dd1a0794ae4aeec5acdbf"
100
+ }
73
101
  }
@@ -0,0 +1,71 @@
1
+ syntax = "proto3";
2
+
3
+ package browserstack.sdk.v1;
4
+
5
+ import "sdk-messages-observability.proto";
6
+ import "sdk-messages-testhub.proto";
7
+
8
+ message Accessibility {
9
+ bool success = 1;
10
+ optional AccessibilityOptions options = 2;
11
+ optional string error_trace_id = 3;
12
+ optional string code = 4;
13
+ repeated KeyMessage errors = 5;
14
+ optional bool is_app_accessibility = 6;
15
+
16
+ message AccessibilityOptions {
17
+ optional string status = 1;
18
+ repeated AccessibilityCapability capabilities = 2;
19
+ repeated AccessibilityScript scripts = 3;
20
+ optional AccessibilityCommandsToWrap commands_to_wrap = 4;
21
+
22
+ message AccessibilityCommandsToWrap {
23
+ repeated string scripts_to_run = 1;
24
+ repeated AccessibilityCommand commands = 2;
25
+ }
26
+
27
+ message AccessibilityCommand {
28
+ string name = 1;
29
+ string library = 2;
30
+ string module = 3;
31
+ string class = 4;
32
+ string method = 5;
33
+ }
34
+
35
+ message AccessibilityScript {
36
+ string name = 1;
37
+ string command = 2;
38
+ }
39
+
40
+ message AccessibilityCapability {
41
+ string name = 1;
42
+ string value = 2;
43
+ }
44
+ }
45
+ }
46
+
47
+ message AccessibilityConfigRequest {
48
+ string bin_session_id = 1;
49
+ uint32 platform_index = 2;
50
+ string framework_name = 3;
51
+ string framework_version = 4;
52
+ string hub_url = 5;
53
+ }
54
+
55
+ message AccessibilityConfigResponse {
56
+ bool success = 1;
57
+ optional TestHub testhub = 2;
58
+ optional Accessibility accessibility = 3;
59
+ }
60
+
61
+ message AccessibilityResultRequest {
62
+ string bin_session_id = 1;
63
+ string test_run_id = 2;
64
+ string session_id = 3;
65
+ string result_type = 4;
66
+ }
67
+
68
+ message AccessibilityResultResponse {
69
+ bool success = 1;
70
+ bytes result_response = 2;
71
+ }
@@ -0,0 +1,48 @@
1
+ syntax = "proto3";
2
+
3
+ package browserstack.sdk.v1;
4
+
5
+ message AIBrowserExtensionRequest {
6
+ string bin_session_id = 1;
7
+ string browser_name = 2;
8
+ string browser_version = 3;
9
+ }
10
+
11
+ message AIBrowserExtensionResponse {
12
+ bool success = 1;
13
+ optional string extension = 2;
14
+ optional string error = 3;
15
+ }
16
+
17
+ message AISelfHealGetRequest {
18
+ string bin_session_id = 1;
19
+ optional string platform_index = 2;
20
+
21
+ string framework_session_id = 3;
22
+ string locator_type = 4;
23
+ }
24
+
25
+ message AISelfHealGetResponse {
26
+ bool success = 1;
27
+ string framework_session_id = 2;
28
+ optional string locator_type = 3;
29
+ optional string locator_value = 4;
30
+ optional bool ai_healing = 5;
31
+ optional string error = 6;
32
+ }
33
+
34
+ message AISelfHealStepRequest {
35
+ string bin_session_id = 1;
36
+ optional string platform_index = 2;
37
+
38
+ string framework_session_id = 3;
39
+ bool is_success = 4;
40
+ string locator_type = 5;
41
+ string locator_value = 6;
42
+ string test_name = 7;
43
+ }
44
+
45
+ message AISelfHealStepResponse {
46
+ string framework_session_id = 1;
47
+ string execute_script = 2;
48
+ }
@@ -0,0 +1,39 @@
1
+ syntax = "proto3";
2
+
3
+ package browserstack.sdk.v1;
4
+
5
+ import "sdk-messages-testhub.proto";
6
+
7
+ message KeyMessage {
8
+ string key = 1;
9
+ string message = 2;
10
+ }
11
+
12
+ message Observability {
13
+ bool success = 1;
14
+ optional ObservabilityOptions options = 2;
15
+ optional string error_trace_id = 3;
16
+ optional string code = 4;
17
+ repeated KeyMessage errors = 5;
18
+ optional bytes options_as_bytes = 6;
19
+
20
+ message ObservabilityOptions {
21
+ optional string allow_screenshots = 1;
22
+ }
23
+ }
24
+
25
+ message ObservabilityConfigRequest {
26
+ string bin_session_id = 1;
27
+ uint32 platform_index = 2;
28
+ string test_framework_name = 3;
29
+ string test_framework_version = 4;
30
+ optional string hub_url = 5;
31
+ optional string capabilities = 6;
32
+ }
33
+
34
+ message ObservabilityConfigResponse {
35
+ bool success = 1;
36
+ optional TestHub testhub = 2;
37
+ optional Observability observability = 3;
38
+ optional string capabilities = 4;
39
+ }
@@ -0,0 +1,10 @@
1
+ syntax = "proto3";
2
+
3
+ package browserstack.sdk.v1;
4
+
5
+ message Percy {
6
+ bool success = 1;
7
+ string percy_capture_mode = 2;
8
+ string percy_build_id = 3;
9
+ bool is_percy_auto_enabled = 4;
10
+ }
@@ -0,0 +1,10 @@
1
+ syntax = "proto3";
2
+
3
+ package browserstack.sdk.v1;
4
+
5
+ message TestHub {
6
+ string jwt = 1;
7
+ string build_hashed_id = 2;
8
+ bool testhub_events = 3;
9
+ bytes errors = 4;
10
+ }