snowflake-sdk
Version:
Node.js driver for Snowflake
29 lines (28 loc) • 1.18 kB
TypeScript
/**
* Build the wire payload for the `client_connection_identifier_shape`
* in-band telemetry event from the raw user-supplied options.
*
* Must be called on the raw options object before any normalization
* (dotted-account split, `.global` org-prefix strip, host inference)
* runs, so the shape reflects user intent rather than the post-
* normalization state of `ConnectionConfig`.
*
* No hostname or account value is included in the payload, only five
* stringified-boolean flags describing which connection-identifier
* fields the user supplied.
*
* TODO(SNOW-3548350): remove this module along with the emission site
* in `lib/services/sf.js` once the data collection wraps up
* (target: 2026-11-30).
*/
import { WIP_ConnectionOptions } from '../connection/types';
type BoolAsString = 'true' | 'false';
export interface ConnectionShapePayload {
account_provided: BoolAsString;
account_with_region: BoolAsString;
account_org_provided: BoolAsString;
region_provided: BoolAsString;
host_provided: BoolAsString;
}
export declare function buildConnectionShapePayload(options: Partial<WIP_ConnectionOptions>): ConnectionShapePayload;
export {};