@izak0s/spacebring-api 16.1.0 → 16.3.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.
package/dist/index.d.ts CHANGED
@@ -905,7 +905,11 @@ interface paths {
905
905
  delete?: never;
906
906
  options?: never;
907
907
  head?: never;
908
- patch?: never;
908
+ /**
909
+ * Update a check-in
910
+ * @description Change when a customer arrived, or when they left on a check-in that is checked out. Fields left out keep their values. The booking, event ticket, or visit behind the check-in gets the new dates too. The customer and administrators are not notified. With bearer token authentication, the user must be an administrator of the check-in's location. <h3>OAuth</h3>Required scopes: <code>checkIns</code>
911
+ */
912
+ patch: operations["patchCheckIn"];
909
913
  trace?: never;
910
914
  };
911
915
  "/check_ins/v1/checkin": {
@@ -919,7 +923,7 @@ interface paths {
919
923
  put?: never;
920
924
  /**
921
925
  * Check in
922
- * @description Record an arrival for a booking, an event ticket, a visit, or a member's subscription. Identify what to check in with its check-in id, with the location and a six-digit code, or with the location and a customer ref to check a member in without a code. With bearer token authentication, the user must be an administrator of the location. <h3>OAuth</h3>Required scopes: <code>checkIns</code>
926
+ * @description Record an arrival for a booking, an event ticket, a visit, or a member's subscription. Identify what to check in with its check-in id, with the location and a six-digit code, or with the location and a customer ref to check a member in without a code. Add a past check-in date to a customer ref to record an arrival nobody checked the member in for: the member stays checked in until they check out, or, with a check-out date too, the check-in is created as checked out, without the events and webhooks of a live arrival. With bearer token authentication, the user must be an administrator of the location. <h3>OAuth</h3>Required scopes: <code>checkIns</code>
923
927
  */
924
928
  post: operations["checkIn"];
925
929
  delete?: never;
@@ -4216,7 +4220,13 @@ interface components {
4216
4220
  /** @description Payment method used. */
4217
4221
  method: {
4218
4222
  /** @description Present when type is external. */
4219
- external?: Record<string, never>;
4223
+ external?: {
4224
+ /**
4225
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
4226
+ * @enum {string}
4227
+ */
4228
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
4229
+ };
4220
4230
  /** @description Present when type is paymentGateway. */
4221
4231
  paymentGateway?: {
4222
4232
  /** @description Payment gateway identifier. */
@@ -4618,7 +4628,13 @@ interface components {
4618
4628
  /** @description Payment method used. */
4619
4629
  method: {
4620
4630
  /** @description Present when type is external. */
4621
- external?: Record<string, never>;
4631
+ external?: {
4632
+ /**
4633
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
4634
+ * @enum {string}
4635
+ */
4636
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
4637
+ };
4622
4638
  /** @description Present when type is paymentGateway. */
4623
4639
  paymentGateway?: {
4624
4640
  /** @description Payment gateway identifier. */
@@ -5017,7 +5033,13 @@ interface components {
5017
5033
  /** @description Payment method used. */
5018
5034
  method: {
5019
5035
  /** @description Present when type is external. */
5020
- external?: Record<string, never>;
5036
+ external?: {
5037
+ /**
5038
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
5039
+ * @enum {string}
5040
+ */
5041
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
5042
+ };
5021
5043
  /** @description Present when type is paymentGateway. */
5022
5044
  paymentGateway?: {
5023
5045
  /** @description Payment gateway identifier. */
@@ -5528,7 +5550,13 @@ interface components {
5528
5550
  /** @description Payment method used. */
5529
5551
  method: {
5530
5552
  /** @description Present when type is external. */
5531
- external?: Record<string, never>;
5553
+ external?: {
5554
+ /**
5555
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
5556
+ * @enum {string}
5557
+ */
5558
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
5559
+ };
5532
5560
  /** @description Present when type is paymentGateway. */
5533
5561
  paymentGateway?: {
5534
5562
  /** @description Payment gateway identifier. */
@@ -6610,6 +6638,11 @@ interface components {
6610
6638
  * @description ISO timestamp of when the user checked in.
6611
6639
  */
6612
6640
  checkInDate?: string;
6641
+ /**
6642
+ * @description How the customer was checked in: 'reception' with their code on the Reception app, 'manual' by an administrator, 'backdated' by an administrator adding a past check-in from the admin app, 'agent' by the AI agent, and 'api' through the API. Absent on check-ins made before methods were recorded.
6643
+ * @enum {string}
6644
+ */
6645
+ checkInMethod?: "agent" | "api" | "backdated" | "manual" | "reception";
6613
6646
  /**
6614
6647
  * Format: uuid
6615
6648
  * @description ID of the schedule this check-in was opened under. Absent on check-ins created before schedules were introduced.
@@ -6620,6 +6653,11 @@ interface components {
6620
6653
  * @description ISO timestamp of when the user checked out.
6621
6654
  */
6622
6655
  checkOutDate?: string;
6656
+ /**
6657
+ * @description How the customer was checked out: 'reception' with their code on the Reception app, 'manual' by an administrator, 'backdated' by an administrator adding a past check-in with its check-out date from the admin app, 'automatic' by the automatic check-out, 'agent' by the AI agent, and 'api' through the API. Absent while the customer is checked in, and on check-ins made before methods were recorded.
6658
+ * @enum {string}
6659
+ */
6660
+ checkOutMethod?: "agent" | "api" | "backdated" | "manual" | "reception" | "automatic";
6623
6661
  /** @description Confirmation code of the check-in. */
6624
6662
  code?: string;
6625
6663
  /**
@@ -6740,6 +6778,11 @@ interface components {
6740
6778
  * @description ISO timestamp of when the user checked in.
6741
6779
  */
6742
6780
  checkInDate?: string;
6781
+ /**
6782
+ * @description How the customer was checked in: 'reception' with their code on the Reception app, 'manual' by an administrator, 'backdated' by an administrator adding a past check-in from the admin app, 'agent' by the AI agent, and 'api' through the API. Absent on check-ins made before methods were recorded.
6783
+ * @enum {string}
6784
+ */
6785
+ checkInMethod?: "agent" | "api" | "backdated" | "manual" | "reception";
6743
6786
  /**
6744
6787
  * Format: uuid
6745
6788
  * @description ID of the schedule this check-in was opened under. Absent on check-ins created before schedules were introduced.
@@ -6750,6 +6793,11 @@ interface components {
6750
6793
  * @description ISO timestamp of when the user checked out.
6751
6794
  */
6752
6795
  checkOutDate?: string;
6796
+ /**
6797
+ * @description How the customer was checked out: 'reception' with their code on the Reception app, 'manual' by an administrator, 'backdated' by an administrator adding a past check-in with its check-out date from the admin app, 'automatic' by the automatic check-out, 'agent' by the AI agent, and 'api' through the API. Absent while the customer is checked in, and on check-ins made before methods were recorded.
6798
+ * @enum {string}
6799
+ */
6800
+ checkOutMethod?: "agent" | "api" | "backdated" | "manual" | "reception" | "automatic";
6753
6801
  /** @description Confirmation code of the check-in. */
6754
6802
  code?: string;
6755
6803
  /**
@@ -20713,7 +20761,13 @@ interface components {
20713
20761
  /** @description Payment method used. */
20714
20762
  method: {
20715
20763
  /** @description Present when type is external. */
20716
- external?: Record<string, never>;
20764
+ external?: {
20765
+ /**
20766
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
20767
+ * @enum {string}
20768
+ */
20769
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
20770
+ };
20717
20771
  /** @description Present when type is paymentGateway. */
20718
20772
  paymentGateway?: {
20719
20773
  /** @description Payment gateway identifier. */
@@ -21427,7 +21481,13 @@ interface components {
21427
21481
  /** @description Payment method used. */
21428
21482
  method: {
21429
21483
  /** @description Present when type is external. */
21430
- external?: Record<string, never>;
21484
+ external?: {
21485
+ /**
21486
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
21487
+ * @enum {string}
21488
+ */
21489
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
21490
+ };
21431
21491
  /** @description Present when type is paymentGateway. */
21432
21492
  paymentGateway?: {
21433
21493
  /** @description Payment gateway identifier. */
@@ -22141,7 +22201,13 @@ interface components {
22141
22201
  /** @description Payment method used. */
22142
22202
  method: {
22143
22203
  /** @description Present when type is external. */
22144
- external?: Record<string, never>;
22204
+ external?: {
22205
+ /**
22206
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Absent when the administrator did not record it.
22207
+ * @enum {string}
22208
+ */
22209
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
22210
+ };
22145
22211
  /** @description Present when type is paymentGateway. */
22146
22212
  paymentGateway?: {
22147
22213
  /** @description Payment gateway identifier. */
@@ -22772,12 +22838,12 @@ interface components {
22772
22838
  */
22773
22839
  locationRef: string;
22774
22840
  /** @description Exchange rate relative to the location main currency. Pass either exchangeRate or provider, never both. */
22775
- exchangeRate?: number;
22841
+ exchangeRate?: number | null;
22776
22842
  /**
22777
22843
  * @description Exchange rate provider when auto-update is enabled. Pass either provider or exchangeRate, never both.
22778
- * @enum {string}
22844
+ * @enum {string|null}
22779
22845
  */
22780
- provider?: "nbu" | "bcra" | "nbg" | "bcch" | "ecb";
22846
+ provider?: "nbu" | "bcra" | "nbg" | "bcch" | "ecb" | null;
22781
22847
  };
22782
22848
  };
22783
22849
  };
@@ -22788,12 +22854,12 @@ interface components {
22788
22854
  /** @description Alt currency fields to update */
22789
22855
  altCurrency: {
22790
22856
  /** @description Exchange rate relative to the location main currency. Pass either exchangeRate or provider, never both. */
22791
- exchangeRate?: number;
22857
+ exchangeRate?: number | null;
22792
22858
  /**
22793
22859
  * @description Exchange rate provider when auto-update is enabled. Pass either provider or exchangeRate, never both.
22794
- * @enum {string}
22860
+ * @enum {string|null}
22795
22861
  */
22796
- provider?: "nbu" | "bcra" | "nbg" | "bcch" | "ecb";
22862
+ provider?: "nbu" | "bcra" | "nbg" | "bcch" | "ecb" | null;
22797
22863
  };
22798
22864
  };
22799
22865
  };
@@ -23237,6 +23303,11 @@ interface components {
23237
23303
  * @description ISO timestamp of when the money was received. Defaults to now. Must not be in the future.
23238
23304
  */
23239
23305
  paymentDate?: string;
23306
+ /**
23307
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Omit it when unknown.
23308
+ * @enum {string}
23309
+ */
23310
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
23240
23311
  };
23241
23312
  /** @description Payment gateway (card) payment method. */
23242
23313
  paymentGateway?: {
@@ -23484,6 +23555,25 @@ interface components {
23484
23555
  };
23485
23556
  };
23486
23557
  };
23558
+ patchCheckIn: {
23559
+ content: {
23560
+ "application/json": {
23561
+ /** @description Check-in dates to change. Fields left out keep their values. */
23562
+ checkIn: {
23563
+ /**
23564
+ * Format: date-time
23565
+ * @description ISO timestamp of when the customer arrived. Must be in the past.
23566
+ */
23567
+ checkInDate?: string;
23568
+ /**
23569
+ * Format: date-time
23570
+ * @description ISO timestamp of when the customer left. Must be in the past and after the check-in date. Accepted only for a check-in that is checked out.
23571
+ */
23572
+ checkOutDate?: string;
23573
+ };
23574
+ };
23575
+ };
23576
+ };
23487
23577
  checkIn: {
23488
23578
  content: {
23489
23579
  "application/json": {
@@ -23499,6 +23589,16 @@ interface components {
23499
23589
  * @description UUID of the location the code was issued in. Required when the check-in is resolved by its code or a customer ref.
23500
23590
  */
23501
23591
  locationRef?: string;
23592
+ /**
23593
+ * Format: date-time
23594
+ * @description ISO timestamp of a past arrival to record for the member in customerRef, such as a visit nobody checked them in for. Without checkOutDate the member stays checked in until they check out.
23595
+ */
23596
+ checkInDate?: string;
23597
+ /**
23598
+ * Format: date-time
23599
+ * @description ISO timestamp of when the member left, which creates the check-in as checked out. Requires checkInDate and must be in the past.
23600
+ */
23601
+ checkOutDate?: string;
23502
23602
  /**
23503
23603
  * Format: uuid
23504
23604
  * @description ID of a member to check in on their subscription without a code. Only administrators of the location can check a member in this way.
@@ -25038,7 +25138,7 @@ interface components {
25038
25138
  tiers: {
25039
25139
  /** @description Fixed fee added once to bookings in this tier. */
25040
25140
  flatAmount: number;
25041
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25141
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25042
25142
  from: number;
25043
25143
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25044
25144
  unitAmount: number;
@@ -25102,7 +25202,7 @@ interface components {
25102
25202
  tiers: {
25103
25203
  /** @description Fixed fee added once to bookings in this tier. */
25104
25204
  flatAmount: number;
25105
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25205
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25106
25206
  from: number;
25107
25207
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25108
25208
  unitAmount: number;
@@ -25230,7 +25330,7 @@ interface components {
25230
25330
  tiers: {
25231
25331
  /** @description Fixed fee added once to bookings in this tier. */
25232
25332
  flatAmount: number;
25233
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25333
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25234
25334
  from: number;
25235
25335
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25236
25336
  unitAmount: number;
@@ -25259,7 +25359,7 @@ interface components {
25259
25359
  tiers: {
25260
25360
  /** @description Fixed fee added once to bookings in this tier. */
25261
25361
  flatAmount: number;
25262
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25362
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25263
25363
  from: number;
25264
25364
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25265
25365
  unitAmount: number;
@@ -25545,7 +25645,7 @@ interface components {
25545
25645
  tiers: {
25546
25646
  /** @description Fixed fee added once to bookings in this tier. */
25547
25647
  flatAmount: number;
25548
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25648
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25549
25649
  from: number;
25550
25650
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25551
25651
  unitAmount: number;
@@ -25604,7 +25704,7 @@ interface components {
25604
25704
  tiers: {
25605
25705
  /** @description Fixed fee added once to bookings in this tier. */
25606
25706
  flatAmount: number;
25607
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25707
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25608
25708
  from: number;
25609
25709
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25610
25710
  unitAmount: number;
@@ -25732,7 +25832,7 @@ interface components {
25732
25832
  tiers: {
25733
25833
  /** @description Fixed fee added once to bookings in this tier. */
25734
25834
  flatAmount: number;
25735
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25835
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25736
25836
  from: number;
25737
25837
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25738
25838
  unitAmount: number;
@@ -25761,7 +25861,7 @@ interface components {
25761
25861
  tiers: {
25762
25862
  /** @description Fixed fee added once to bookings in this tier. */
25763
25863
  flatAmount: number;
25764
- /** @description Booking length in minutes at which this tier starts, for example 480 for 8 hours. */
25864
+ /** @description Booking length in minutes at which this tier starts, 0 for the first tier and for example 480 for 8 hours. */
25765
25865
  from: number;
25766
25866
  /** @description Price per hour of booking within this tier, not per minute, for example 40 for 40 per hour. */
25767
25867
  unitAmount: number;
@@ -27467,6 +27567,11 @@ interface components {
27467
27567
  * @description ISO timestamp of when the money was received. Defaults to now. Must not be in the future.
27468
27568
  */
27469
27569
  paymentDate?: string;
27570
+ /**
27571
+ * @description How the money was collected outside Spacebring: `bankTransfer`, `card` for a card charged on the location's own terminal, `cash`, `check`, or `paymentLink`. Omit it when unknown.
27572
+ * @enum {string}
27573
+ */
27574
+ paidBy?: "bankTransfer" | "card" | "cash" | "check" | "paymentLink";
27470
27575
  };
27471
27576
  /** @description Payment gateway (card) payment method. */
27472
27577
  paymentGateway?: {
@@ -29499,6 +29604,66 @@ interface operations {
29499
29604
  };
29500
29605
  };
29501
29606
  };
29607
+ patchCheckIn: {
29608
+ parameters: {
29609
+ query?: never;
29610
+ header?: {
29611
+ /** @description The id of the network. Required when using bearer token authentication */
29612
+ "spacebring-network-id"?: string;
29613
+ };
29614
+ path: {
29615
+ /** @description The ID of the check-in. */
29616
+ checkInId: string;
29617
+ };
29618
+ cookie?: never;
29619
+ };
29620
+ requestBody: components["requestBodies"]["patchCheckIn"];
29621
+ responses: {
29622
+ /** @description No Content */
29623
+ 204: {
29624
+ headers: {
29625
+ [name: string]: unknown;
29626
+ };
29627
+ content?: never;
29628
+ };
29629
+ /** @description Bad Request */
29630
+ 400: {
29631
+ headers: {
29632
+ [name: string]: unknown;
29633
+ };
29634
+ content: {
29635
+ "application/json": components["schemas"]["responseError"];
29636
+ };
29637
+ };
29638
+ /** @description Forbidden */
29639
+ 403: {
29640
+ headers: {
29641
+ [name: string]: unknown;
29642
+ };
29643
+ content: {
29644
+ "application/json": components["schemas"]["responseError"];
29645
+ };
29646
+ };
29647
+ /** @description Not Found */
29648
+ 404: {
29649
+ headers: {
29650
+ [name: string]: unknown;
29651
+ };
29652
+ content: {
29653
+ "application/json": components["schemas"]["responseError"];
29654
+ };
29655
+ };
29656
+ /** @description Conflict */
29657
+ 409: {
29658
+ headers: {
29659
+ [name: string]: unknown;
29660
+ };
29661
+ content: {
29662
+ "application/json": components["schemas"]["responseError"];
29663
+ };
29664
+ };
29665
+ };
29666
+ };
29502
29667
  checkIn: {
29503
29668
  parameters: {
29504
29669
  query?: never;
@@ -37093,6 +37258,8 @@ interface GetCheckInsQuery {
37093
37258
  type CheckInBody = NonNullable<operations["checkIn"]["requestBody"]>["content"]["application/json"];
37094
37259
  /** Request body for `sb.checkIns.checkOut()`. */
37095
37260
  type CheckOutBody = NonNullable<operations["checkOut"]["requestBody"]>["content"]["application/json"];
37261
+ /** Request body for `sb.checkIns.update()`. */
37262
+ type PatchCheckInBody = NonNullable<NonNullable<operations["patchCheckIn"]["requestBody"]>["content"]["application/json"]["checkIn"]>;
37096
37263
 
37097
37264
  /** A CreditNote entity as returned by the Spacebring API. */
37098
37265
  type CreditNote = NonNullable<components["schemas"]["creditNote"]>;
@@ -37395,6 +37562,7 @@ declare function createResources(client: Client<paths>, defaults: SpacebringDefa
37395
37562
  }>;
37396
37563
  iterate(query?: Omit<GetCheckInsQuery, "nextPageToken">, options?: SpacebringRequestOptions): AsyncGenerator<CheckIn, void, undefined>;
37397
37564
  get(checkInId: string, options?: SpacebringRequestOptions): Promise<CheckIn>;
37565
+ update(checkInId: string, checkIn: PatchCheckInBody, options?: SpacebringRequestOptions): Promise<undefined>;
37398
37566
  checkIn(body: CheckInBody, options?: SpacebringRequestOptions): Promise<CheckIn>;
37399
37567
  checkOut(body: CheckOutBody, options?: SpacebringRequestOptions): Promise<CheckIn>;
37400
37568
  };
@@ -37864,4 +38032,4 @@ declare class SpacebringError extends Error {
37864
38032
  }
37865
38033
 
37866
38034
  export { Spacebring, SpacebringError };
37867
- export type { Activity, AddEventHostsBody, AltCurrency, Application, ApplyBenefitBody, Assignment, Attachment, Balance, Benefit, BenefitCategory, BenefitMedia, Booking, CheckIn, CheckInBody, CheckInVisitBody, CheckOutBody, CheckOutVisitBody, Comment, Company, CompanyMedia, Contact, Contract, Coupon, CreateAltCurrencyBody, CreateAssignmentBody, CreateBenefitBody, CreateBenefitCategoryBody, CreateBenefitMediaBody, CreateBookingBody, CreateCompanyBody, CreateCompanyMediaBody, CreateContactBody, CreateContractBody, CreateCouponBody, CreateCreditNoteBody, CreateCreditsTransactionBody, CreateDayPassesTransactionBody, CreateEventBody, CreateEventMediaBody, CreateFeedPostBody, CreateFeedPostCommentBody, CreateFeedPostMediaBody, CreateGuideAttachmentBody, CreateGuideBody, CreateGuideMediaBody, CreateInvoiceBody, CreateInvoiceItemBody, CreateMembershipBody, CreateMoneyTransactionBody, CreatePackageBody, CreatePlanBody, CreatePlanMediaBody, CreateProductBody, CreateProductMediaBody, CreatePromocodeBody, CreateRequestBody, CreateResourceBody, CreateResourceMediaBody, CreateShopCategoryBody, CreateSubscriptionBody, CreateSubscriptionItemBody, CreateSupportTicketBody, CreateSupportTicketCommentBody, CreateSupportTicketMediaBody, CreateTemplateBody, CreateTemplateMediaBody, CreateVisitBody, CreditNote, CreditScheduledTransaction, CreditTransaction, DayPassScheduledTransaction, DayPassTransaction, Event, EventMedia, EventTicket, FeedMedia, GetAltCurrenciesQuery, GetAssignmentsQuery, GetBenefitApplicationsQuery, GetBenefitCategoriesQuery, GetBenefitsQuery, GetBookingsQuery, GetCheckInsQuery, GetCompaniesQuery, GetContactsQuery, GetContractsQuery, GetCouponsQuery, GetCreditNotesQuery, GetCreditsTransactionsQuery, GetDayPassesTransactionsQuery, GetDiscountRedemptionsQuery, GetEventTicketsQuery, GetEventsByOrganizationQuery, GetFeedPostsQuery, GetFloorsQuery, GetGuidesQuery, GetInvoicesQuery, GetMembershipsDeletedQuery, GetMembershipsQuery, GetMoneyTransactionsQuery, GetOrdersQuery, GetPackagesQuery, GetPlansQuery, GetProductsQuery, GetPromocodesQuery, GetRegistrationsQuery, GetRequestsQuery, GetResourceAvailability, GetResourceAvailabilityBody, GetResourcesQuery, GetScheduledCreditsTransactionsQuery, GetScheduledDayPassesTransactionsQuery, GetShopCategoriesQuery, GetSubscriptionsQuery, GetSupportTicketsQuery, GetTemplatesQuery, GetUpcomingInvoiceItemsQuery, GetUpcomingInvoiceQuery, GetVisitsQuery, Guide, GuideMedia, Invoice, InvoiceItem, IssueContractBody, IssueInvoiceBody, Like, ListInvoiceItemsQuery, Location, Membership, MoneyTransaction, Network, Order, Package, PatchAssignmentBody, PatchBenefitBody, PatchBookingBody, PatchEventBody, PatchFeedPostBody, PatchGuideBody, PatchMoneyTransactionBody, PatchPackageBody, PatchProductBody, PatchResourceBody, PayInvoiceBody, Payment, Plan, PlanMedia, Post, PreviewCreditNoteBody, Product, ProductMedia, Promocode, Redemption, Refund, RefundMoneyTransactionBody, Registration, Request$1 as Request, Resource, ResourceMedia, ShopCategory, SpacebringConfig, SpacebringErrorBody, SpacebringRequestOptions, SpacebringResources, Subscription, SupportTicket, Template, TemplateMedia, TerminateContractBody, TicketMedia, UpcomingItem, UpdateAltCurrencyBody, UpdateBenefitBody, UpdateBenefitCategoryBody, UpdateCompanyBody, UpdateContractBody, UpdateCouponBody, UpdateCreditNoteBody, UpdateEventBody, UpdateEventTicketBody, UpdateFeedPostBody, UpdateInvoiceBody, UpdateInvoiceItemBody, UpdateMembershipBody, UpdatePlanBody, UpdateProductBody, UpdateShopCategoryBody, UpdateSubscriptionBody, UpdateSubscriptionItemBody, UpdateSupportTicketAssigneeBody, UpdateSupportTicketCommentBody, UpdateSupportTicketStatusBody, UpdateSupportTicketTypeBody, UpdateTemplateBody, UpdateVisitBody, Visit, components, operations, paths };
38035
+ export type { Activity, AddEventHostsBody, AltCurrency, Application, ApplyBenefitBody, Assignment, Attachment, Balance, Benefit, BenefitCategory, BenefitMedia, Booking, CheckIn, CheckInBody, CheckInVisitBody, CheckOutBody, CheckOutVisitBody, Comment, Company, CompanyMedia, Contact, Contract, Coupon, CreateAltCurrencyBody, CreateAssignmentBody, CreateBenefitBody, CreateBenefitCategoryBody, CreateBenefitMediaBody, CreateBookingBody, CreateCompanyBody, CreateCompanyMediaBody, CreateContactBody, CreateContractBody, CreateCouponBody, CreateCreditNoteBody, CreateCreditsTransactionBody, CreateDayPassesTransactionBody, CreateEventBody, CreateEventMediaBody, CreateFeedPostBody, CreateFeedPostCommentBody, CreateFeedPostMediaBody, CreateGuideAttachmentBody, CreateGuideBody, CreateGuideMediaBody, CreateInvoiceBody, CreateInvoiceItemBody, CreateMembershipBody, CreateMoneyTransactionBody, CreatePackageBody, CreatePlanBody, CreatePlanMediaBody, CreateProductBody, CreateProductMediaBody, CreatePromocodeBody, CreateRequestBody, CreateResourceBody, CreateResourceMediaBody, CreateShopCategoryBody, CreateSubscriptionBody, CreateSubscriptionItemBody, CreateSupportTicketBody, CreateSupportTicketCommentBody, CreateSupportTicketMediaBody, CreateTemplateBody, CreateTemplateMediaBody, CreateVisitBody, CreditNote, CreditScheduledTransaction, CreditTransaction, DayPassScheduledTransaction, DayPassTransaction, Event, EventMedia, EventTicket, FeedMedia, GetAltCurrenciesQuery, GetAssignmentsQuery, GetBenefitApplicationsQuery, GetBenefitCategoriesQuery, GetBenefitsQuery, GetBookingsQuery, GetCheckInsQuery, GetCompaniesQuery, GetContactsQuery, GetContractsQuery, GetCouponsQuery, GetCreditNotesQuery, GetCreditsTransactionsQuery, GetDayPassesTransactionsQuery, GetDiscountRedemptionsQuery, GetEventTicketsQuery, GetEventsByOrganizationQuery, GetFeedPostsQuery, GetFloorsQuery, GetGuidesQuery, GetInvoicesQuery, GetMembershipsDeletedQuery, GetMembershipsQuery, GetMoneyTransactionsQuery, GetOrdersQuery, GetPackagesQuery, GetPlansQuery, GetProductsQuery, GetPromocodesQuery, GetRegistrationsQuery, GetRequestsQuery, GetResourceAvailability, GetResourceAvailabilityBody, GetResourcesQuery, GetScheduledCreditsTransactionsQuery, GetScheduledDayPassesTransactionsQuery, GetShopCategoriesQuery, GetSubscriptionsQuery, GetSupportTicketsQuery, GetTemplatesQuery, GetUpcomingInvoiceItemsQuery, GetUpcomingInvoiceQuery, GetVisitsQuery, Guide, GuideMedia, Invoice, InvoiceItem, IssueContractBody, IssueInvoiceBody, Like, ListInvoiceItemsQuery, Location, Membership, MoneyTransaction, Network, Order, Package, PatchAssignmentBody, PatchBenefitBody, PatchBookingBody, PatchCheckInBody, PatchEventBody, PatchFeedPostBody, PatchGuideBody, PatchMoneyTransactionBody, PatchPackageBody, PatchProductBody, PatchResourceBody, PayInvoiceBody, Payment, Plan, PlanMedia, Post, PreviewCreditNoteBody, Product, ProductMedia, Promocode, Redemption, Refund, RefundMoneyTransactionBody, Registration, Request$1 as Request, Resource, ResourceMedia, ShopCategory, SpacebringConfig, SpacebringErrorBody, SpacebringRequestOptions, SpacebringResources, Subscription, SupportTicket, Template, TemplateMedia, TerminateContractBody, TicketMedia, UpcomingItem, UpdateAltCurrencyBody, UpdateBenefitBody, UpdateBenefitCategoryBody, UpdateCompanyBody, UpdateContractBody, UpdateCouponBody, UpdateCreditNoteBody, UpdateEventBody, UpdateEventTicketBody, UpdateFeedPostBody, UpdateInvoiceBody, UpdateInvoiceItemBody, UpdateMembershipBody, UpdatePlanBody, UpdateProductBody, UpdateShopCategoryBody, UpdateSubscriptionBody, UpdateSubscriptionItemBody, UpdateSupportTicketAssigneeBody, UpdateSupportTicketCommentBody, UpdateSupportTicketStatusBody, UpdateSupportTicketTypeBody, UpdateTemplateBody, UpdateVisitBody, Visit, components, operations, paths };
package/dist/index.js CHANGED
@@ -1091,10 +1091,22 @@ function createCheckins(client, defaults) {
1091
1091
  async get(checkInId, options) {
1092
1092
  return unwrapProp(await client.GET("/check_ins/v1/{checkInId}", { params: { path: { checkInId } }, signal: options?.signal }), "checkIn", "GET /check_ins/v1/{checkInId}");
1093
1093
  },
1094
+ /**
1095
+ * Update a check-in
1096
+ *
1097
+ * Change when a customer arrived, or when they left on a check-in that is checked out. Fields left out keep their values. The booking, event ticket, or visit behind the check-in gets the new dates too. The customer and administrators are not notified. With bearer token authentication, the user must be an administrator of the check-in's location.
1098
+ *
1099
+ * @param checkInId The ID of the check-in.
1100
+ * @param checkIn The `checkIn` payload.
1101
+ * @param options Request options (abort signal).
1102
+ */
1103
+ async update(checkInId, checkIn, options) {
1104
+ return unwrap(await client.PATCH("/check_ins/v1/{checkInId}", { params: { path: { checkInId } }, body: { checkIn }, signal: options?.signal }), "PATCH /check_ins/v1/{checkInId}");
1105
+ },
1094
1106
  /**
1095
1107
  * Check in
1096
1108
  *
1097
- * Record an arrival for a booking, an event ticket, a visit, or a member's subscription. Identify what to check in with its check-in id, with the location and a six-digit code, or with the location and a customer ref to check a member in without a code. With bearer token authentication, the user must be an administrator of the location.
1109
+ * Record an arrival for a booking, an event ticket, a visit, or a member's subscription. Identify what to check in with its check-in id, with the location and a six-digit code, or with the location and a customer ref to check a member in without a code. Add a past check-in date to a customer ref to record an arrival nobody checked the member in for: the member stays checked in until they check out, or, with a check-out date too, the check-in is created as checked out, without the events and webhooks of a live arrival. With bearer token authentication, the user must be an administrator of the location.
1098
1110
  */
1099
1111
  async checkIn(body, options) {
1100
1112
  return unwrapProp(await client.POST("/check_ins/v1/checkin", { body, signal: options?.signal }), "checkIn", "POST /check_ins/v1/checkin");