@unisonlabs/sixminute-admin 0.1.1351 → 0.1.1352-next
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/sixminute-admin.mjs +97 -1
- package/package.json +1 -1
package/dist/sixminute-admin.mjs
CHANGED
|
@@ -21,7 +21,7 @@ import { homedir } from "node:os";
|
|
|
21
21
|
import { fileURLToPath } from "node:url";
|
|
22
22
|
|
|
23
23
|
// tools/admin/src/build-info.ts
|
|
24
|
-
var BUILT = { version: "0.1.
|
|
24
|
+
var BUILT = { version: "0.1.1352-next", commit: "7721b4ad701aa1bf0e6c5ceff2da6617f1efa553", surface: "20ea8005a02a0df9" };
|
|
25
25
|
|
|
26
26
|
// tools/admin/src/run.ts
|
|
27
27
|
import { readFileSync as readFileSync4, writeFileSync as writeFileSync2 } from "node:fs";
|
|
@@ -5414,6 +5414,22 @@ var CATALOGUE = {
|
|
|
5414
5414
|
question: "Are calendars read, and do they change?",
|
|
5415
5415
|
properties: { provider: oneOf(["microsoft", "google"]), outcome: oneOf(["synced", "failed"]), events_read: count(), events_written: count() }
|
|
5416
5416
|
}),
|
|
5417
|
+
phoneConnected: spec({
|
|
5418
|
+
name: "phone connected",
|
|
5419
|
+
owner: "cloud",
|
|
5420
|
+
expect: "rare",
|
|
5421
|
+
trigger: "a phone synced for the first time under its device id",
|
|
5422
|
+
question: "Do people put Sixminute on their phone?",
|
|
5423
|
+
properties: { platform: oneOf(["ios", "android"]) }
|
|
5424
|
+
}),
|
|
5425
|
+
phoneSynced: spec({
|
|
5426
|
+
name: "phone synced",
|
|
5427
|
+
owner: "cloud",
|
|
5428
|
+
expect: "rare",
|
|
5429
|
+
trigger: "a phone's sync took or refused at least one call (a sync with no calls says nothing)",
|
|
5430
|
+
question: "Do calls reach the server, and are any refused?",
|
|
5431
|
+
properties: { calls_taken: count(), calls_refused: count() }
|
|
5432
|
+
}),
|
|
5417
5433
|
sourceHealthChanged: spec({
|
|
5418
5434
|
name: "source health changed",
|
|
5419
5435
|
owner: "cloud",
|
|
@@ -6912,6 +6928,26 @@ var CaptureMarkBatchSchema = exports_external.object({
|
|
|
6912
6928
|
// packages/contracts/src/device.ts
|
|
6913
6929
|
var DEVICE_CREDENTIAL_PREFIX = "smd_";
|
|
6914
6930
|
var ENROLLMENT_CODE_PREFIX = "sme_";
|
|
6931
|
+
var DESKTOP_PLATFORMS = ["macos", "windows"];
|
|
6932
|
+
var PHONE_PLATFORMS = ["ios", "android"];
|
|
6933
|
+
var DEVICE_ROUTES = [
|
|
6934
|
+
{ method: "POST", path: "/v1/devices/enroll", platforms: [...DESKTOP_PLATFORMS, ...PHONE_PLATFORMS] },
|
|
6935
|
+
{ method: "DELETE", path: "/v1/devices/credential", platforms: [...DESKTOP_PLATFORMS, ...PHONE_PLATFORMS] },
|
|
6936
|
+
{ method: "POST", path: "/v1/intervals/{from}/context", platforms: DESKTOP_PLATFORMS },
|
|
6937
|
+
{ method: "POST", path: "/v1/device/signals", platforms: DESKTOP_PLATFORMS },
|
|
6938
|
+
{ method: "POST", path: "/v1/device/clock", platforms: DESKTOP_PLATFORMS },
|
|
6939
|
+
{ method: "POST", path: "/v1/recordings/{id}/stop", platforms: DESKTOP_PLATFORMS },
|
|
6940
|
+
{ method: "POST", path: "/v1/recordings/{id}/clock", platforms: DESKTOP_PLATFORMS },
|
|
6941
|
+
{ method: "POST", path: "/v1/recordings/{id}/skip", platforms: DESKTOP_PLATFORMS },
|
|
6942
|
+
{ method: "POST", path: "/v1/recordings/{id}/signals", platforms: DESKTOP_PLATFORMS },
|
|
6943
|
+
{ method: "POST", path: "/v1/coverage", platforms: DESKTOP_PLATFORMS },
|
|
6944
|
+
{ method: "POST", path: "/v1/telemetry", platforms: DESKTOP_PLATFORMS },
|
|
6945
|
+
{ method: "GET", path: "/v1/device/policy", platforms: DESKTOP_PLATFORMS },
|
|
6946
|
+
{ method: "POST", path: "/v1/device/check-in", platforms: DESKTOP_PLATFORMS },
|
|
6947
|
+
{ method: "POST", path: "/v1/devices/session-handoff", platforms: DESKTOP_PLATFORMS },
|
|
6948
|
+
{ method: "POST", path: "/v1/phone/sync", platforms: PHONE_PLATFORMS },
|
|
6949
|
+
{ method: "POST", path: "/v1/phone/calls/forget", platforms: PHONE_PLATFORMS }
|
|
6950
|
+
];
|
|
6915
6951
|
var EnrollmentCodeSchema = exports_external.object({
|
|
6916
6952
|
code: exports_external.string().startsWith(ENROLLMENT_CODE_PREFIX),
|
|
6917
6953
|
expires_at: TimestampSchema
|
|
@@ -7836,6 +7872,66 @@ var AdminDemoStatusSchema = exports_external.object({
|
|
|
7836
7872
|
caps: exports_external.object({ calls_per_day: exports_external.number().int(), cost_usd_per_day: exports_external.number() }),
|
|
7837
7873
|
days: exports_external.array(exports_external.object({ day: LocalDaySchema, mode: exports_external.enum(["live", "replay"]), recordings: exports_external.number().int(), entries: exports_external.number().int() }))
|
|
7838
7874
|
});
|
|
7875
|
+
// packages/contracts/src/phone/index.ts
|
|
7876
|
+
var PHONE_SYNC_MAX_CALLS = 500;
|
|
7877
|
+
var PHONE_FORGET_MAX = 500;
|
|
7878
|
+
var PhoneCallDirectionSchema = exports_external.enum(["incoming", "outgoing"]);
|
|
7879
|
+
var PhoneCallStatusSchema = exports_external.enum(["connected", "missed", "declined", "cancelled", "unknown"]);
|
|
7880
|
+
var PhoneCallSchema = exports_external.object({
|
|
7881
|
+
record_id: exports_external.string().min(1).max(200),
|
|
7882
|
+
number: exports_external.string().min(1).max(32).nullable(),
|
|
7883
|
+
contact_name: exports_external.string().min(1).max(200).nullable(),
|
|
7884
|
+
started_at: TimestampSchema,
|
|
7885
|
+
ended_at: TimestampSchema,
|
|
7886
|
+
direction: PhoneCallDirectionSchema,
|
|
7887
|
+
status: PhoneCallStatusSchema,
|
|
7888
|
+
line: exports_external.string().min(1).max(200).nullable()
|
|
7889
|
+
}).refine((call) => Date.parse(call.ended_at) >= Date.parse(call.started_at), { message: "a call ends at or after it starts", path: ["ended_at"] });
|
|
7890
|
+
var PhoneCaptureSchema = exports_external.enum(["ok", "not_default"]);
|
|
7891
|
+
var PhonePushEnvSchema = exports_external.enum(["production", "sandbox"]);
|
|
7892
|
+
var PhoneBackgroundRefreshSchema = exports_external.enum(["available", "denied", "restricted"]);
|
|
7893
|
+
var PhoneNotificationsSchema = exports_external.enum(["allowed", "denied", "not_asked"]);
|
|
7894
|
+
var PhoneSyncSchema = exports_external.object({
|
|
7895
|
+
calls: exports_external.array(PhoneCallSchema).max(PHONE_SYNC_MAX_CALLS),
|
|
7896
|
+
capture: PhoneCaptureSchema,
|
|
7897
|
+
excluded_count: exports_external.number().int().nonnegative(),
|
|
7898
|
+
push_token: exports_external.string().min(1).max(400).nullable(),
|
|
7899
|
+
push_env: PhonePushEnvSchema,
|
|
7900
|
+
background_refresh: PhoneBackgroundRefreshSchema,
|
|
7901
|
+
notifications: PhoneNotificationsSchema,
|
|
7902
|
+
time_zone: exports_external.string().min(1).max(64),
|
|
7903
|
+
region: exports_external.string().regex(/^[A-Z]{2}$/).nullable(),
|
|
7904
|
+
app_version: exports_external.string().min(1).max(64),
|
|
7905
|
+
os_version: exports_external.string().min(1).max(64)
|
|
7906
|
+
});
|
|
7907
|
+
var PhoneSyncBodySchema = PhoneSyncSchema.extend({ calls: exports_external.array(exports_external.unknown()).max(PHONE_SYNC_MAX_CALLS) });
|
|
7908
|
+
var PhoneRefusalReasonSchema = exports_external.enum(["malformed", "too_long", "bad_time"]);
|
|
7909
|
+
var PhoneRefusedCallSchema = exports_external.object({
|
|
7910
|
+
index: exports_external.number().int().nonnegative(),
|
|
7911
|
+
record_id: exports_external.string().min(1).max(200).nullable(),
|
|
7912
|
+
reason: PhoneRefusalReasonSchema
|
|
7913
|
+
});
|
|
7914
|
+
var PhoneSyncAnswerSchema = exports_external.object({
|
|
7915
|
+
taken: exports_external.array(exports_external.string()),
|
|
7916
|
+
refused: exports_external.array(PhoneRefusedCallSchema)
|
|
7917
|
+
});
|
|
7918
|
+
var PhoneForgetSchema = exports_external.object({
|
|
7919
|
+
record_ids: exports_external.array(exports_external.string().min(1).max(200)).max(PHONE_FORGET_MAX)
|
|
7920
|
+
});
|
|
7921
|
+
var PhoneStateSchema = exports_external.enum(["ok", "not_default", "no_wake", "quiet"]);
|
|
7922
|
+
var PhoneStatusSchema = exports_external.object({
|
|
7923
|
+
device_id: DeviceIdSchema,
|
|
7924
|
+
name: exports_external.string(),
|
|
7925
|
+
connected_at: TimestampSchema,
|
|
7926
|
+
last_sync_at: TimestampSchema.nullable(),
|
|
7927
|
+
calls_synced: exports_external.number().int().nonnegative(),
|
|
7928
|
+
state: PhoneStateSchema,
|
|
7929
|
+
excluded_count: exports_external.number().int().nonnegative()
|
|
7930
|
+
});
|
|
7931
|
+
var PhoneListSchema = exports_external.object({
|
|
7932
|
+
enabled: exports_external.boolean(),
|
|
7933
|
+
phones: exports_external.array(PhoneStatusSchema)
|
|
7934
|
+
});
|
|
7839
7935
|
// packages/contracts/src/pipeline-runs.ts
|
|
7840
7936
|
var LocalSpanSchema = exports_external.object({
|
|
7841
7937
|
from: TimestampSchema,
|
package/package.json
CHANGED