@brightoutcome/guidistry-client 0.15.0 → 0.16.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 (2) hide show
  1. package/dist/schema.d.ts +441 -6
  2. package/package.json +1 -1
package/dist/schema.d.ts CHANGED
@@ -3084,6 +3084,46 @@ export interface paths {
3084
3084
  patch: operations["update_study_v1_studies__study_id__patch"];
3085
3085
  trace?: never;
3086
3086
  };
3087
+ "/v1/studies/{study_id}/allocation": {
3088
+ parameters: {
3089
+ query?: never;
3090
+ header?: never;
3091
+ path?: never;
3092
+ cookie?: never;
3093
+ };
3094
+ /**
3095
+ * Allocation set-up and counts
3096
+ * @description The study's mode and method, the uploaded lists, and per site the number assigned by the server and sealed-list rows left. Never which arm comes next.
3097
+ */
3098
+ get: operations["allocation_state_v1_studies__study_id__allocation_get"];
3099
+ put?: never;
3100
+ post?: never;
3101
+ delete?: never;
3102
+ options?: never;
3103
+ head?: never;
3104
+ patch?: never;
3105
+ trace?: never;
3106
+ };
3107
+ "/v1/studies/{study_id}/allocation-lists": {
3108
+ parameters: {
3109
+ query?: never;
3110
+ header?: never;
3111
+ path?: never;
3112
+ cookie?: never;
3113
+ };
3114
+ get?: never;
3115
+ put?: never;
3116
+ /**
3117
+ * Upload a sealed randomization list
3118
+ * @description CSV with the header `sequence,site,arm` (site code; arm name or ID). Lists are added, never replaced or edited; the rows are encrypted and never shown again: the answer has counts only.
3119
+ */
3120
+ post: operations["upload_list_v1_studies__study_id__allocation_lists_post"];
3121
+ delete?: never;
3122
+ options?: never;
3123
+ head?: never;
3124
+ patch?: never;
3125
+ trace?: never;
3126
+ };
3087
3127
  "/v1/studies/{study_id}/arms": {
3088
3128
  parameters: {
3089
3129
  query?: never;
@@ -3385,6 +3425,26 @@ export interface paths {
3385
3425
  patch?: never;
3386
3426
  trace?: never;
3387
3427
  };
3428
+ "/v1/study-participants/{participant_id}/allocate": {
3429
+ parameters: {
3430
+ query?: never;
3431
+ header?: never;
3432
+ path?: never;
3433
+ cookie?: never;
3434
+ };
3435
+ get?: never;
3436
+ put?: never;
3437
+ /**
3438
+ * Assign an arm (server allocation)
3439
+ * @description Only with `allocation.mode` = `staff` or `on_consent` (409 allocation_recorded with `recorded`: use Record arm). Needs a complete consent (409 consent_required) and no arm yet (409 already_allocated). The arm comes from the site's next block or sealed-list row; nobody sees it beforehand.
3440
+ */
3441
+ post: operations["allocate_v1_study_participants__participant_id__allocate_post"];
3442
+ delete?: never;
3443
+ options?: never;
3444
+ head?: never;
3445
+ patch?: never;
3446
+ trace?: never;
3447
+ };
3388
3448
  "/v1/study-participants/{participant_id}/anchors": {
3389
3449
  parameters: {
3390
3450
  query?: never;
@@ -3445,6 +3505,26 @@ export interface paths {
3445
3505
  patch?: never;
3446
3506
  trace?: never;
3447
3507
  };
3508
+ "/v1/study-participants/{participant_id}/crossover": {
3509
+ parameters: {
3510
+ query?: never;
3511
+ header?: never;
3512
+ path?: never;
3513
+ cookie?: never;
3514
+ };
3515
+ get?: never;
3516
+ put?: never;
3517
+ /**
3518
+ * Open a waitlist arm's course for a participant
3519
+ * @description For an arm whose waitlist opens by staff (409 not_waitlisted otherwise, 409 already_open when done). The participant can then join the arm's cohort.
3520
+ */
3521
+ post: operations["crossover_v1_study_participants__participant_id__crossover_post"];
3522
+ delete?: never;
3523
+ options?: never;
3524
+ head?: never;
3525
+ patch?: never;
3526
+ trace?: never;
3527
+ };
3448
3528
  "/v1/study-participants/{participant_id}/questionnaire-responses": {
3449
3529
  parameters: {
3450
3530
  query?: never;
@@ -3502,6 +3582,26 @@ export interface paths {
3502
3582
  patch?: never;
3503
3583
  trace?: never;
3504
3584
  };
3585
+ "/v1/study-participants/{participant_id}/unblind": {
3586
+ parameters: {
3587
+ query?: never;
3588
+ header?: never;
3589
+ path?: never;
3590
+ cookie?: never;
3591
+ };
3592
+ get?: never;
3593
+ put?: never;
3594
+ /**
3595
+ * Reveal one participant's arm (unblinding officer)
3596
+ * @description Needs `allocation.unblind` and a reason. Every reveal is an `unblind` event in the participant's history (the arm itself hidden from blinded roles) and an audit row.
3597
+ */
3598
+ post: operations["unblind_v1_study_participants__participant_id__unblind_post"];
3599
+ delete?: never;
3600
+ options?: never;
3601
+ head?: never;
3602
+ patch?: never;
3603
+ trace?: never;
3604
+ };
3505
3605
  "/v1/study-sites/{site_id}": {
3506
3606
  parameters: {
3507
3607
  query?: never;
@@ -4609,6 +4709,77 @@ export interface components {
4609
4709
  /** Items */
4610
4710
  items: components["schemas"]["AlertOut"][];
4611
4711
  };
4712
+ /** AllocationListIn */
4713
+ AllocationListIn: {
4714
+ /**
4715
+ * Csv
4716
+ * @description Header `sequence,site,arm`; site code; arm name or ID
4717
+ */
4718
+ csv: string;
4719
+ /** Name */
4720
+ name: string;
4721
+ };
4722
+ /** AllocationListOut */
4723
+ AllocationListOut: {
4724
+ /**
4725
+ * At
4726
+ * Format: date-time
4727
+ */
4728
+ at: string;
4729
+ /**
4730
+ * Id
4731
+ * Format: uuid
4732
+ */
4733
+ id: string;
4734
+ /** Name */
4735
+ name: string;
4736
+ /** Rows */
4737
+ rows: number;
4738
+ /**
4739
+ * Rows By Site
4740
+ * @description Rows per site (in the upload answer only)
4741
+ */
4742
+ rows_by_site: {
4743
+ [key: string]: number;
4744
+ } | null;
4745
+ /**
4746
+ * Uploaded By Person Id
4747
+ * Format: uuid
4748
+ */
4749
+ uploaded_by_person_id: string;
4750
+ };
4751
+ /** AllocationOut */
4752
+ AllocationOut: {
4753
+ /** Lists */
4754
+ lists: components["schemas"]["AllocationListOut"][];
4755
+ /**
4756
+ * Method
4757
+ * @enum {string}
4758
+ */
4759
+ method: "blocks" | "sealed_list";
4760
+ /**
4761
+ * Mode
4762
+ * @enum {string}
4763
+ */
4764
+ mode: "recorded" | "on_consent" | "staff";
4765
+ /** Sites */
4766
+ sites: components["schemas"]["AllocationSiteCount"][];
4767
+ };
4768
+ /** AllocationSiteCount */
4769
+ AllocationSiteCount: {
4770
+ /**
4771
+ * Assigned
4772
+ * @description Arms assigned by the server at this site
4773
+ */
4774
+ assigned: number;
4775
+ /** List Rows Left */
4776
+ list_rows_left: number;
4777
+ /**
4778
+ * Site Id
4779
+ * Format: uuid
4780
+ */
4781
+ site_id: string;
4782
+ };
4612
4783
  /** AnchorIn */
4613
4784
  AnchorIn: {
4614
4785
  /**
@@ -4762,8 +4933,11 @@ export interface components {
4762
4933
  name: string;
4763
4934
  /** Order */
4764
4935
  order: number;
4765
- /** Participants */
4766
- participants: number;
4936
+ /**
4937
+ * Participants
4938
+ * @description null for roles blinded to arms
4939
+ */
4940
+ participants: number | null;
4767
4941
  /**
4768
4942
  * Program Id
4769
4943
  * @description Backs the arm's cohorts (A1)
@@ -4783,6 +4957,7 @@ export interface components {
4783
4957
  study_id: string;
4784
4958
  /** Target N */
4785
4959
  target_n: number | null;
4960
+ waitlist?: components["schemas"]["Waitlist"] | null;
4786
4961
  };
4787
4962
  /** ArmRecordIn */
4788
4963
  ArmRecordIn: {
@@ -4806,16 +4981,26 @@ export interface components {
4806
4981
  };
4807
4982
  /** ArmUpdate */
4808
4983
  ArmUpdate: {
4984
+ /**
4985
+ * Clear Waitlist
4986
+ * @default false
4987
+ */
4988
+ clear_waitlist: boolean;
4809
4989
  /** Label */
4810
4990
  label?: string | null;
4811
4991
  /** Name */
4812
4992
  name?: string | null;
4813
4993
  /** Order */
4814
4994
  order?: number | null;
4815
- /** Status */
4995
+ /**
4996
+ * Status
4997
+ * @description A closed arm takes no new participants (allocation passes it over)
4998
+ */
4816
4999
  status?: ("active" | "closed") | null;
4817
5000
  /** Target N */
4818
5001
  target_n?: number | null;
5002
+ /** @description Make the arm a waitlist arm (questionnaires only until it opens); `clear_waitlist` removes it. Not after the protocol lock (409 protocol_locked) */
5003
+ waitlist?: components["schemas"]["Waitlist"] | null;
4819
5004
  };
4820
5005
  /** AttachmentOut */
4821
5006
  AttachmentOut: {
@@ -5650,6 +5835,11 @@ export interface components {
5650
5835
  /** Source */
5651
5836
  source: string;
5652
5837
  };
5838
+ /** CrossoverIn */
5839
+ CrossoverIn: {
5840
+ /** Reason */
5841
+ reason?: string | null;
5842
+ };
5653
5843
  /** DeliveryOut */
5654
5844
  DeliveryOut: {
5655
5845
  /** Actor Person Id */
@@ -6069,7 +6259,7 @@ export interface components {
6069
6259
  * Kind
6070
6260
  * @enum {string}
6071
6261
  */
6072
- kind: "status" | "consent" | "arm" | "anchor" | "code" | "site";
6262
+ kind: "status" | "consent" | "arm" | "anchor" | "code" | "site" | "consent_confirmed" | "withdrawal_request" | "crossover" | "unblind";
6073
6263
  /** Reason */
6074
6264
  reason: string | null;
6075
6265
  };
@@ -8192,6 +8382,12 @@ export interface components {
8192
8382
  cohort_id: string | null;
8193
8383
  /** Consent Version */
8194
8384
  consent_version: string | null;
8385
+ /**
8386
+ * Course Open
8387
+ * @description False while the participant's waitlist arm hasn't opened (null for roles blinded to arms)
8388
+ * @default true
8389
+ */
8390
+ course_open: boolean | null;
8195
8391
  /**
8196
8392
  * Created At
8197
8393
  * Format: date-time
@@ -8252,6 +8448,12 @@ export interface components {
8252
8448
  cohort_id: string | null;
8253
8449
  /** Consent Version */
8254
8450
  consent_version: string | null;
8451
+ /**
8452
+ * Course Open
8453
+ * @description False while the participant's waitlist arm hasn't opened (null for roles blinded to arms)
8454
+ * @default true
8455
+ */
8456
+ course_open: boolean | null;
8255
8457
  /**
8256
8458
  * Created At
8257
8459
  * Format: date-time
@@ -10720,7 +10922,7 @@ export interface components {
10720
10922
  * Role
10721
10923
  * @enum {string}
10722
10924
  */
10723
- role: "study_admin" | "principal_investigator" | "research_coordinator" | "facilitator";
10925
+ role: "study_admin" | "principal_investigator" | "co_principal_investigator" | "research_coordinator" | "facilitator" | "statistician" | "unblinding_officer";
10724
10926
  /**
10725
10927
  * Site Id
10726
10928
  * @description None = every site
@@ -11040,6 +11242,33 @@ export interface components {
11040
11242
  /** Total */
11041
11243
  total: number | null;
11042
11244
  };
11245
+ /** UnblindIn */
11246
+ UnblindIn: {
11247
+ /** Reason */
11248
+ reason: string;
11249
+ };
11250
+ /** UnblindOut */
11251
+ UnblindOut: {
11252
+ /**
11253
+ * Arm Id
11254
+ * Format: uuid
11255
+ */
11256
+ arm_id: string;
11257
+ /** Arm Name */
11258
+ arm_name: string;
11259
+ /**
11260
+ * At
11261
+ * Format: date-time
11262
+ */
11263
+ at: string;
11264
+ /**
11265
+ * Participant Id
11266
+ * Format: uuid
11267
+ */
11268
+ participant_id: string;
11269
+ /** Study Code */
11270
+ study_code: string;
11271
+ };
11043
11272
  /** UploadFormOut */
11044
11273
  UploadFormOut: {
11045
11274
  /** Fields */
@@ -11250,6 +11479,20 @@ export interface components {
11250
11479
  /** Name */
11251
11480
  name: string;
11252
11481
  };
11482
+ /** Waitlist */
11483
+ Waitlist: {
11484
+ /**
11485
+ * Opens
11486
+ * @description How the course opens: staff open it per participant (crossover), or on a date
11487
+ * @enum {string}
11488
+ */
11489
+ opens: "staff" | "date";
11490
+ /**
11491
+ * Opens On
11492
+ * @description Required with opens = date
11493
+ */
11494
+ opens_on?: string | null;
11495
+ };
11253
11496
  /** WritingIn */
11254
11497
  WritingIn: {
11255
11498
  /** Attachment Ids */
@@ -11554,7 +11797,7 @@ export interface components {
11554
11797
  * Role
11555
11798
  * @enum {string}
11556
11799
  */
11557
- role: "study_admin" | "principal_investigator" | "research_coordinator" | "facilitator";
11800
+ role: "study_admin" | "principal_investigator" | "co_principal_investigator" | "research_coordinator" | "facilitator" | "statistician" | "unblinding_officer";
11558
11801
  /** Site Id */
11559
11802
  site_id: string | null;
11560
11803
  /**
@@ -19182,6 +19425,82 @@ export interface operations {
19182
19425
  };
19183
19426
  };
19184
19427
  };
19428
+ allocation_state_v1_studies__study_id__allocation_get: {
19429
+ parameters: {
19430
+ query?: never;
19431
+ header?: {
19432
+ /** @description Membership the caller is acting through (from GET /v1/me) */
19433
+ "X-Guidistry-Context"?: string | null;
19434
+ /** @description BrightOutcome only: an open support session (POST /v1/platform/access-sessions) to reach one customer's patient data */
19435
+ "X-Guidistry-Support-Session"?: string | null;
19436
+ };
19437
+ path: {
19438
+ study_id: string;
19439
+ };
19440
+ cookie?: never;
19441
+ };
19442
+ requestBody?: never;
19443
+ responses: {
19444
+ /** @description Successful Response */
19445
+ 200: {
19446
+ headers: {
19447
+ [name: string]: unknown;
19448
+ };
19449
+ content: {
19450
+ "application/json": components["schemas"]["AllocationOut"];
19451
+ };
19452
+ };
19453
+ /** @description Validation Error */
19454
+ 422: {
19455
+ headers: {
19456
+ [name: string]: unknown;
19457
+ };
19458
+ content: {
19459
+ "application/json": components["schemas"]["HTTPValidationError"];
19460
+ };
19461
+ };
19462
+ };
19463
+ };
19464
+ upload_list_v1_studies__study_id__allocation_lists_post: {
19465
+ parameters: {
19466
+ query?: never;
19467
+ header?: {
19468
+ /** @description Membership the caller is acting through (from GET /v1/me) */
19469
+ "X-Guidistry-Context"?: string | null;
19470
+ /** @description BrightOutcome only: an open support session (POST /v1/platform/access-sessions) to reach one customer's patient data */
19471
+ "X-Guidistry-Support-Session"?: string | null;
19472
+ };
19473
+ path: {
19474
+ study_id: string;
19475
+ };
19476
+ cookie?: never;
19477
+ };
19478
+ requestBody: {
19479
+ content: {
19480
+ "application/json": components["schemas"]["AllocationListIn"];
19481
+ };
19482
+ };
19483
+ responses: {
19484
+ /** @description Successful Response */
19485
+ 201: {
19486
+ headers: {
19487
+ [name: string]: unknown;
19488
+ };
19489
+ content: {
19490
+ "application/json": components["schemas"]["AllocationListOut"];
19491
+ };
19492
+ };
19493
+ /** @description Validation Error */
19494
+ 422: {
19495
+ headers: {
19496
+ [name: string]: unknown;
19497
+ };
19498
+ content: {
19499
+ "application/json": components["schemas"]["HTTPValidationError"];
19500
+ };
19501
+ };
19502
+ };
19503
+ };
19185
19504
  list_arms_v1_studies__study_id__arms_get: {
19186
19505
  parameters: {
19187
19506
  query?: never;
@@ -19985,6 +20304,42 @@ export interface operations {
19985
20304
  };
19986
20305
  };
19987
20306
  };
20307
+ allocate_v1_study_participants__participant_id__allocate_post: {
20308
+ parameters: {
20309
+ query?: never;
20310
+ header?: {
20311
+ /** @description Membership the caller is acting through (from GET /v1/me) */
20312
+ "X-Guidistry-Context"?: string | null;
20313
+ /** @description BrightOutcome only: an open support session (POST /v1/platform/access-sessions) to reach one customer's patient data */
20314
+ "X-Guidistry-Support-Session"?: string | null;
20315
+ };
20316
+ path: {
20317
+ participant_id: string;
20318
+ };
20319
+ cookie?: never;
20320
+ };
20321
+ requestBody?: never;
20322
+ responses: {
20323
+ /** @description Successful Response */
20324
+ 200: {
20325
+ headers: {
20326
+ [name: string]: unknown;
20327
+ };
20328
+ content: {
20329
+ "application/json": components["schemas"]["ParticipantDetail"];
20330
+ };
20331
+ };
20332
+ /** @description Validation Error */
20333
+ 422: {
20334
+ headers: {
20335
+ [name: string]: unknown;
20336
+ };
20337
+ content: {
20338
+ "application/json": components["schemas"]["HTTPValidationError"];
20339
+ };
20340
+ };
20341
+ };
20342
+ };
19988
20343
  set_anchor_v1_study_participants__participant_id__anchors_post: {
19989
20344
  parameters: {
19990
20345
  query?: never;
@@ -20105,6 +20460,46 @@ export interface operations {
20105
20460
  };
20106
20461
  };
20107
20462
  };
20463
+ crossover_v1_study_participants__participant_id__crossover_post: {
20464
+ parameters: {
20465
+ query?: never;
20466
+ header?: {
20467
+ /** @description Membership the caller is acting through (from GET /v1/me) */
20468
+ "X-Guidistry-Context"?: string | null;
20469
+ /** @description BrightOutcome only: an open support session (POST /v1/platform/access-sessions) to reach one customer's patient data */
20470
+ "X-Guidistry-Support-Session"?: string | null;
20471
+ };
20472
+ path: {
20473
+ participant_id: string;
20474
+ };
20475
+ cookie?: never;
20476
+ };
20477
+ requestBody: {
20478
+ content: {
20479
+ "application/json": components["schemas"]["CrossoverIn"];
20480
+ };
20481
+ };
20482
+ responses: {
20483
+ /** @description Successful Response */
20484
+ 200: {
20485
+ headers: {
20486
+ [name: string]: unknown;
20487
+ };
20488
+ content: {
20489
+ "application/json": components["schemas"]["ParticipantDetail"];
20490
+ };
20491
+ };
20492
+ /** @description Validation Error */
20493
+ 422: {
20494
+ headers: {
20495
+ [name: string]: unknown;
20496
+ };
20497
+ content: {
20498
+ "application/json": components["schemas"]["HTTPValidationError"];
20499
+ };
20500
+ };
20501
+ };
20502
+ };
20108
20503
  enter_answers_v1_study_participants__participant_id__questionnaire_responses_post: {
20109
20504
  parameters: {
20110
20505
  query?: never;
@@ -20225,6 +20620,46 @@ export interface operations {
20225
20620
  };
20226
20621
  };
20227
20622
  };
20623
+ unblind_v1_study_participants__participant_id__unblind_post: {
20624
+ parameters: {
20625
+ query?: never;
20626
+ header?: {
20627
+ /** @description Membership the caller is acting through (from GET /v1/me) */
20628
+ "X-Guidistry-Context"?: string | null;
20629
+ /** @description BrightOutcome only: an open support session (POST /v1/platform/access-sessions) to reach one customer's patient data */
20630
+ "X-Guidistry-Support-Session"?: string | null;
20631
+ };
20632
+ path: {
20633
+ participant_id: string;
20634
+ };
20635
+ cookie?: never;
20636
+ };
20637
+ requestBody: {
20638
+ content: {
20639
+ "application/json": components["schemas"]["UnblindIn"];
20640
+ };
20641
+ };
20642
+ responses: {
20643
+ /** @description Successful Response */
20644
+ 200: {
20645
+ headers: {
20646
+ [name: string]: unknown;
20647
+ };
20648
+ content: {
20649
+ "application/json": components["schemas"]["UnblindOut"];
20650
+ };
20651
+ };
20652
+ /** @description Validation Error */
20653
+ 422: {
20654
+ headers: {
20655
+ [name: string]: unknown;
20656
+ };
20657
+ content: {
20658
+ "application/json": components["schemas"]["HTTPValidationError"];
20659
+ };
20660
+ };
20661
+ };
20662
+ };
20228
20663
  update_site_v1_study_sites__site_id__patch: {
20229
20664
  parameters: {
20230
20665
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightoutcome/guidistry-client",
3
- "version": "0.15.0",
3
+ "version": "0.16.0",
4
4
  "description": "Typed client and sign-in helpers for the Guidistry API",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",