@gethydra/sdk 0.1.34 → 0.1.36

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
@@ -108,6 +108,8 @@ interface components {
108
108
  exclude_services: boolean;
109
109
  /** @example 0 */
110
110
  min_order_total: number;
111
+ /** @example 12 */
112
+ pending_hours: number;
111
113
  };
112
114
  pricing_config: {
113
115
  /** @example 2 */
@@ -3450,6 +3452,126 @@ interface components {
3450
3452
  valid: boolean;
3451
3453
  staff?: components["schemas"]["PosStaff"];
3452
3454
  };
3455
+ PosAnalyticsDashboard: {
3456
+ period: {
3457
+ /** @example 2026-11-17 */
3458
+ from: string;
3459
+ /** @example 2026-11-17 */
3460
+ to: string;
3461
+ };
3462
+ /** @description Comparison date range, or null when compare=none. */
3463
+ comparison_period: {
3464
+ from: string;
3465
+ to: string;
3466
+ } | null;
3467
+ /**
3468
+ * @description Store base currency.
3469
+ * @example gbp
3470
+ */
3471
+ currency: string;
3472
+ takings: {
3473
+ /** @description Total collected via cash payments (cents). */
3474
+ cash_collected: number;
3475
+ /** @description Total collected via card payments (cents). */
3476
+ card_collected: number;
3477
+ /** @description Total amount paid via gift cards (cents). */
3478
+ gift_card_payments: number;
3479
+ /** @description Total amount paid via store credit (cents). */
3480
+ store_credit_payments: number;
3481
+ /** @description Total discount amount applied (cents). */
3482
+ discounts_given: number;
3483
+ /** @description Cash + card actually received at the till (cents). */
3484
+ net_collected: number;
3485
+ };
3486
+ /** @description Takings for the comparison period, or null. */
3487
+ previous_takings: {
3488
+ /** @description Total collected via cash payments (cents). */
3489
+ cash_collected: number;
3490
+ /** @description Total collected via card payments (cents). */
3491
+ card_collected: number;
3492
+ /** @description Total amount paid via gift cards (cents). */
3493
+ gift_card_payments: number;
3494
+ /** @description Total amount paid via store credit (cents). */
3495
+ store_credit_payments: number;
3496
+ /** @description Total discount amount applied (cents). */
3497
+ discounts_given: number;
3498
+ /** @description Cash + card actually received at the till (cents). */
3499
+ net_collected: number;
3500
+ } | null;
3501
+ summary: {
3502
+ /** @description Sum of order subtotals (cents). */
3503
+ gross_revenue: {
3504
+ /** @description Metric value for the current period. */
3505
+ value: number;
3506
+ /** @description Metric value for the comparison period, or null. */
3507
+ previous: number | null;
3508
+ /** @description Percentage change vs comparison period (2dp), or null. */
3509
+ change: number | null;
3510
+ };
3511
+ /** @description Sum of order totals — actual cash/card received (cents). */
3512
+ net_collected: {
3513
+ /** @description Metric value for the current period. */
3514
+ value: number;
3515
+ /** @description Metric value for the comparison period, or null. */
3516
+ previous: number | null;
3517
+ /** @description Percentage change vs comparison period (2dp), or null. */
3518
+ change: number | null;
3519
+ };
3520
+ /** @description Number of non-cancelled orders. */
3521
+ order_count: {
3522
+ /** @description Metric value for the current period. */
3523
+ value: number;
3524
+ /** @description Metric value for the comparison period, or null. */
3525
+ previous: number | null;
3526
+ /** @description Percentage change vs comparison period (2dp), or null. */
3527
+ change: number | null;
3528
+ };
3529
+ /** @description Gross revenue per order (cents). */
3530
+ average_order_value: {
3531
+ /** @description Metric value for the current period. */
3532
+ value: number;
3533
+ /** @description Metric value for the comparison period, or null. */
3534
+ previous: number | null;
3535
+ /** @description Percentage change vs comparison period (2dp), or null. */
3536
+ change: number | null;
3537
+ };
3538
+ /** @description Total quantity of line items sold. */
3539
+ items_sold: {
3540
+ /** @description Metric value for the current period. */
3541
+ value: number;
3542
+ /** @description Metric value for the comparison period, or null. */
3543
+ previous: number | null;
3544
+ /** @description Percentage change vs comparison period (2dp), or null. */
3545
+ change: number | null;
3546
+ };
3547
+ };
3548
+ top_products: {
3549
+ /** @description Product ID. */
3550
+ product_id: string | null;
3551
+ /** @description Product title. */
3552
+ title: string;
3553
+ /** @description Product image URL. */
3554
+ image_src: string | null;
3555
+ /** @description Total line-item revenue (cents). */
3556
+ revenue: number;
3557
+ /** @description Total quantity sold. */
3558
+ quantity_sold: number;
3559
+ /** @description Number of distinct orders containing this product. */
3560
+ orders: number;
3561
+ }[];
3562
+ staff: {
3563
+ /** @description Staff member ID. */
3564
+ staff_id: string;
3565
+ /** @description Staff member name. */
3566
+ staff_name: string;
3567
+ /** @description Number of orders processed. */
3568
+ order_count: number;
3569
+ /** @description Commissionable amount — actual cash/card collected (cents). */
3570
+ total_collected: number;
3571
+ /** @description Sum of subtotals for orders by this staff (cents). */
3572
+ gross_revenue: number;
3573
+ }[];
3574
+ };
3453
3575
  DayAvailability: {
3454
3576
  /** @example 2026-11-20 */
3455
3577
  date: string;
@@ -3664,6 +3786,28 @@ interface components {
3664
3786
  status: "active" | "deactivated";
3665
3787
  expires_at: string | null;
3666
3788
  };
3789
+ GiftCardConvert: {
3790
+ gift_card: components["schemas"]["GiftCard"];
3791
+ credit_transaction: {
3792
+ id: string;
3793
+ customer_id: string;
3794
+ /** @enum {string} */
3795
+ type: "credit" | "debit" | "expiry";
3796
+ amount: number;
3797
+ balance_after: number;
3798
+ reason: string;
3799
+ note: string | null;
3800
+ related_order_id: string | null;
3801
+ related_refund_id: string | null;
3802
+ expires_at: string | null;
3803
+ metadata: {
3804
+ [key: string]: string | number;
3805
+ };
3806
+ created_at: string;
3807
+ updated_at: string;
3808
+ };
3809
+ customer_balance: number;
3810
+ };
3667
3811
  GiftCardTransaction: {
3668
3812
  id: string;
3669
3813
  gift_card_id: string;
@@ -4537,6 +4681,8 @@ interface operations {
4537
4681
  exclude_services?: boolean;
4538
4682
  /** @example 0 */
4539
4683
  min_order_total?: number;
4684
+ /** @example 12 */
4685
+ pending_hours?: number;
4540
4686
  };
4541
4687
  gift_card_config?: {
4542
4688
  default_expiry_days?: number | null;
@@ -10119,6 +10265,8 @@ interface operations {
10119
10265
  "application/json": {
10120
10266
  data: {
10121
10267
  balance: number;
10268
+ available_balance: number;
10269
+ pending_balance: number;
10122
10270
  currency: string;
10123
10271
  };
10124
10272
  };
@@ -10169,6 +10317,7 @@ interface operations {
10169
10317
  related_order_id: string | null;
10170
10318
  related_refund_id: string | null;
10171
10319
  expires_at: string | null;
10320
+ usable_after: string | null;
10172
10321
  metadata: {
10173
10322
  [key: string]: string | number;
10174
10323
  };
@@ -10217,6 +10366,7 @@ interface operations {
10217
10366
  related_order_id: string | null;
10218
10367
  related_refund_id: string | null;
10219
10368
  expires_at: string | null;
10369
+ usable_after: string | null;
10220
10370
  metadata: {
10221
10371
  [key: string]: string | number;
10222
10372
  };
@@ -13316,7 +13466,7 @@ interface operations {
13316
13466
  * "order.paid"
13317
13467
  * ]
13318
13468
  */
13319
- events: ("product.created" | "product.updated" | "product.deleted" | "order.created" | "order.paid" | "order.fulfilled" | "order.cancelled" | "order.refunded" | "channel.created" | "channel.updated" | "channel.archived" | "collection.created" | "collection.updated" | "collection.deleted" | "company.created" | "company.updated" | "company.deleted" | "customer.created" | "customer.updated" | "customer_photo.submitted" | "customer_photo.approved" | "customer_photo.rejected" | "discount.created" | "discount.updated" | "discount.deleted" | "draft_order.created" | "draft_order.updated" | "draft_order.completed" | "draft_order.deleted" | "filter_attribute.created" | "filter_attribute.updated" | "filter_attribute.deleted" | "fulfillment.created" | "fulfillment.updated" | "fulfillment.cancelled" | "fulfillment_order.created" | "inventory.low" | "location.created" | "location.updated" | "location.deleted" | "navigation.created" | "navigation.updated" | "navigation.deleted" | "shipping.zone.created" | "shipping.zone.updated" | "shipping.zone.deleted" | "post.created" | "post.updated" | "post.deleted" | "post.published" | "post.unpublished" | "promotion.created" | "promotion.updated" | "promotion.deleted" | "purchase_order.created" | "purchase_order.updated" | "purchase_order.received" | "purchase_order.cancelled" | "refund.created" | "refund.succeeded" | "refund.failed" | "return.requested" | "return.approved" | "return.received" | "return.rejected" | "return.cancelled" | "return.closed" | "store.published" | "store_credit.issued" | "store_credit.used" | "store_credit.expired" | "loyalty.earned" | "loyalty.clawed_back" | "gift_card.created" | "gift_card.updated" | "gift_card.deactivated" | "gift_card.redeemed" | "gift_card.credited" | "membership.created" | "membership.updated" | "membership.cancelled" | "membership.expired" | "usage.warning" | "booking.created" | "booking.confirmed" | "booking.cancelled" | "booking.completed" | "lookbook.created" | "lookbook.updated" | "lookbook.deleted")[];
13469
+ events: ("product.created" | "product.updated" | "product.deleted" | "order.created" | "order.paid" | "order.fulfilled" | "order.cancelled" | "order.refunded" | "channel.created" | "channel.updated" | "channel.archived" | "collection.created" | "collection.updated" | "collection.deleted" | "company.created" | "company.updated" | "company.deleted" | "customer.created" | "customer.updated" | "customer_photo.submitted" | "customer_photo.approved" | "customer_photo.rejected" | "discount.created" | "discount.updated" | "discount.deleted" | "draft_order.created" | "draft_order.updated" | "draft_order.completed" | "draft_order.deleted" | "filter_attribute.created" | "filter_attribute.updated" | "filter_attribute.deleted" | "fulfillment.created" | "fulfillment.updated" | "fulfillment.cancelled" | "fulfillment_order.created" | "inventory.low" | "location.created" | "location.updated" | "location.deleted" | "navigation.created" | "navigation.updated" | "navigation.deleted" | "shipping.zone.created" | "shipping.zone.updated" | "shipping.zone.deleted" | "post.created" | "post.updated" | "post.deleted" | "post.published" | "post.unpublished" | "promotion.created" | "promotion.updated" | "promotion.deleted" | "purchase_order.created" | "purchase_order.updated" | "purchase_order.received" | "purchase_order.cancelled" | "refund.created" | "refund.succeeded" | "refund.failed" | "return.requested" | "return.approved" | "return.received" | "return.rejected" | "return.cancelled" | "return.closed" | "store.published" | "store_credit.issued" | "store_credit.used" | "store_credit.expired" | "loyalty.earned" | "loyalty.clawed_back" | "gift_card.created" | "gift_card.updated" | "gift_card.deactivated" | "gift_card.redeemed" | "gift_card.credited" | "gift_card.converted" | "membership.created" | "membership.updated" | "membership.cancelled" | "membership.expired" | "usage.warning" | "booking.created" | "booking.confirmed" | "booking.cancelled" | "booking.completed" | "lookbook.created" | "lookbook.updated" | "lookbook.deleted")[];
13320
13470
  /**
13321
13471
  * @default active
13322
13472
  * @example active
@@ -13410,7 +13560,7 @@ interface operations {
13410
13560
  * "product.updated"
13411
13561
  * ]
13412
13562
  */
13413
- events?: ("product.created" | "product.updated" | "product.deleted" | "order.created" | "order.paid" | "order.fulfilled" | "order.cancelled" | "order.refunded" | "channel.created" | "channel.updated" | "channel.archived" | "collection.created" | "collection.updated" | "collection.deleted" | "company.created" | "company.updated" | "company.deleted" | "customer.created" | "customer.updated" | "customer_photo.submitted" | "customer_photo.approved" | "customer_photo.rejected" | "discount.created" | "discount.updated" | "discount.deleted" | "draft_order.created" | "draft_order.updated" | "draft_order.completed" | "draft_order.deleted" | "filter_attribute.created" | "filter_attribute.updated" | "filter_attribute.deleted" | "fulfillment.created" | "fulfillment.updated" | "fulfillment.cancelled" | "fulfillment_order.created" | "inventory.low" | "location.created" | "location.updated" | "location.deleted" | "navigation.created" | "navigation.updated" | "navigation.deleted" | "shipping.zone.created" | "shipping.zone.updated" | "shipping.zone.deleted" | "post.created" | "post.updated" | "post.deleted" | "post.published" | "post.unpublished" | "promotion.created" | "promotion.updated" | "promotion.deleted" | "purchase_order.created" | "purchase_order.updated" | "purchase_order.received" | "purchase_order.cancelled" | "refund.created" | "refund.succeeded" | "refund.failed" | "return.requested" | "return.approved" | "return.received" | "return.rejected" | "return.cancelled" | "return.closed" | "store.published" | "store_credit.issued" | "store_credit.used" | "store_credit.expired" | "loyalty.earned" | "loyalty.clawed_back" | "gift_card.created" | "gift_card.updated" | "gift_card.deactivated" | "gift_card.redeemed" | "gift_card.credited" | "membership.created" | "membership.updated" | "membership.cancelled" | "membership.expired" | "usage.warning" | "booking.created" | "booking.confirmed" | "booking.cancelled" | "booking.completed" | "lookbook.created" | "lookbook.updated" | "lookbook.deleted")[];
13563
+ events?: ("product.created" | "product.updated" | "product.deleted" | "order.created" | "order.paid" | "order.fulfilled" | "order.cancelled" | "order.refunded" | "channel.created" | "channel.updated" | "channel.archived" | "collection.created" | "collection.updated" | "collection.deleted" | "company.created" | "company.updated" | "company.deleted" | "customer.created" | "customer.updated" | "customer_photo.submitted" | "customer_photo.approved" | "customer_photo.rejected" | "discount.created" | "discount.updated" | "discount.deleted" | "draft_order.created" | "draft_order.updated" | "draft_order.completed" | "draft_order.deleted" | "filter_attribute.created" | "filter_attribute.updated" | "filter_attribute.deleted" | "fulfillment.created" | "fulfillment.updated" | "fulfillment.cancelled" | "fulfillment_order.created" | "inventory.low" | "location.created" | "location.updated" | "location.deleted" | "navigation.created" | "navigation.updated" | "navigation.deleted" | "shipping.zone.created" | "shipping.zone.updated" | "shipping.zone.deleted" | "post.created" | "post.updated" | "post.deleted" | "post.published" | "post.unpublished" | "promotion.created" | "promotion.updated" | "promotion.deleted" | "purchase_order.created" | "purchase_order.updated" | "purchase_order.received" | "purchase_order.cancelled" | "refund.created" | "refund.succeeded" | "refund.failed" | "return.requested" | "return.approved" | "return.received" | "return.rejected" | "return.cancelled" | "return.closed" | "store.published" | "store_credit.issued" | "store_credit.used" | "store_credit.expired" | "loyalty.earned" | "loyalty.clawed_back" | "gift_card.created" | "gift_card.updated" | "gift_card.deactivated" | "gift_card.redeemed" | "gift_card.credited" | "gift_card.converted" | "membership.created" | "membership.updated" | "membership.cancelled" | "membership.expired" | "usage.warning" | "booking.created" | "booking.confirmed" | "booking.cancelled" | "booking.completed" | "lookbook.created" | "lookbook.updated" | "lookbook.deleted")[];
13414
13564
  /**
13415
13565
  * @example active
13416
13566
  * @enum {string}
@@ -16699,6 +16849,41 @@ interface operations {
16699
16849
  };
16700
16850
  };
16701
16851
  };
16852
+ getPosAnalyticsDashboard: {
16853
+ parameters: {
16854
+ query: {
16855
+ /** @description Location ID to scope analytics to. */
16856
+ location_id: string;
16857
+ /** @description Start date (YYYY-MM-DD). */
16858
+ from: string;
16859
+ /** @description End date (YYYY-MM-DD). */
16860
+ to: string;
16861
+ /** @description Comparison mode. */
16862
+ compare?: "previous_period" | "none";
16863
+ /** @description Number of top products to return (1-20). */
16864
+ top_products_limit?: number;
16865
+ /** @description Sort top products by revenue or quantity sold. */
16866
+ top_products_sort?: "revenue" | "quantity";
16867
+ };
16868
+ header?: never;
16869
+ path?: never;
16870
+ cookie?: never;
16871
+ };
16872
+ requestBody?: never;
16873
+ responses: {
16874
+ /** @description POS analytics dashboard data */
16875
+ 200: {
16876
+ headers: {
16877
+ [name: string]: unknown;
16878
+ };
16879
+ content: {
16880
+ "application/json": {
16881
+ data: components["schemas"]["PosAnalyticsDashboard"];
16882
+ };
16883
+ };
16884
+ };
16885
+ };
16886
+ };
16702
16887
  listBookableLocations: {
16703
16888
  parameters: {
16704
16889
  query?: never;
@@ -17575,6 +17760,40 @@ interface operations {
17575
17760
  };
17576
17761
  };
17577
17762
  };
17763
+ convertGiftCardToStoreCredit: {
17764
+ parameters: {
17765
+ query?: never;
17766
+ header?: never;
17767
+ path: {
17768
+ id: string;
17769
+ };
17770
+ cookie?: never;
17771
+ };
17772
+ requestBody?: {
17773
+ content: {
17774
+ "application/json": {
17775
+ /**
17776
+ * @description Customer to receive the store credit.
17777
+ * @example cus_abc123
17778
+ */
17779
+ customer_id: string;
17780
+ };
17781
+ };
17782
+ };
17783
+ responses: {
17784
+ /** @description Gift card converted to store credit */
17785
+ 200: {
17786
+ headers: {
17787
+ [name: string]: unknown;
17788
+ };
17789
+ content: {
17790
+ "application/json": {
17791
+ data: components["schemas"]["GiftCardConvert"];
17792
+ };
17793
+ };
17794
+ };
17795
+ };
17796
+ };
17578
17797
  listGiftCardTransactions: {
17579
17798
  parameters: {
17580
17799
  query?: {
@@ -20931,6 +21150,8 @@ interface LoyaltySummary {
20931
21150
  active_loyalty_points?: number;
20932
21151
  clawed_back_credit?: number;
20933
21152
  expired_credit?: number;
21153
+ pending_credit?: number;
21154
+ pending_points?: number;
20934
21155
  display_multiplier?: number;
20935
21156
  earn_rate_bps?: number;
20936
21157
  }
@@ -21305,6 +21526,26 @@ interface CreditDebitBody {
21305
21526
  amount: number;
21306
21527
  note?: string;
21307
21528
  }
21529
+ /** Response from converting a gift card to store credit. */
21530
+ interface GiftCardConvertResult {
21531
+ gift_card: GiftCard;
21532
+ credit_transaction: {
21533
+ id: string;
21534
+ customer_id: string;
21535
+ type: 'credit' | 'debit' | 'expiry';
21536
+ amount: number;
21537
+ balance_after: number;
21538
+ reason: string;
21539
+ note: string | null;
21540
+ related_order_id: string | null;
21541
+ related_refund_id: string | null;
21542
+ expires_at: string | null;
21543
+ metadata: Record<string, string | number>;
21544
+ created_at: string;
21545
+ updated_at: string;
21546
+ };
21547
+ customer_balance: number;
21548
+ }
21308
21549
  declare class GiftCardsResource {
21309
21550
  private client;
21310
21551
  constructor(client: Hydra);
@@ -21324,6 +21565,10 @@ declare class GiftCardsResource {
21324
21565
  }): Promise<GiftCardTransaction[]>;
21325
21566
  credit(id: string, body: CreditDebitBody, options?: ResourceRequestOptions): Promise<DataResponse<GiftCard>>;
21326
21567
  debit(id: string, body: CreditDebitBody, options?: ResourceRequestOptions): Promise<DataResponse<GiftCard>>;
21568
+ /** Convert a gift card's remaining balance into store credit on a customer account. */
21569
+ convert(id: string, body: {
21570
+ customer_id: string;
21571
+ }): Promise<DataResponse<GiftCardConvertResult>>;
21327
21572
  /** Look up a gift card by code (publishable key OK). */
21328
21573
  lookup(code: string): Promise<DataResponse<GiftCardLookup>>;
21329
21574
  }
@@ -21493,4 +21738,4 @@ declare class HydraIdempotencyError extends HydraError {
21493
21738
  constructor(body: HydraErrorBody, headers: Headers);
21494
21739
  }
21495
21740
 
21496
- export { AddressesResource, type AnalyticsActionItems$1 as AnalyticsActionItems, type AnalyticsOrdersSeries$1 as AnalyticsOrdersSeries, AnalyticsResource, type AnalyticsSummary$1 as AnalyticsSummary, type AnalyticsTimeSeries$1 as AnalyticsTimeSeries, type AnalyticsTopProduct$1 as AnalyticsTopProduct, type AppInfo, type Appointment$1 as Appointment, type AvailabilityOverride$1 as AvailabilityOverride, BookingsResource, type Cart$1 as Cart, type CartItem, CartResource, type Channel$1 as Channel, ChannelsResource, type CheckoutCreate$1 as CheckoutCreate, type CheckoutGet$1 as CheckoutGet, type CheckoutListItem$1 as CheckoutListItem, CheckoutResource, CheckoutsResource, type Collection$1 as Collection, CollectionsResource, CompaniesResource, type Company$1 as Company, ContentCategoriesResource, type ContentCategory$1 as ContentCategory, type CreateGiftCardBody, type Customer$1 as Customer, type CustomerGroup$1 as CustomerGroup, CustomerGroupsResource, type CustomerMembership$1 as CustomerMembership, type CustomerPhoto$1 as CustomerPhoto, CustomerPhotosResource, CustomersResource, type DataResponse, type DayAvailability$1 as DayAvailability, type Discount$1 as Discount, DiscountsResource, type DraftOrder$1 as DraftOrder, DraftOrdersResource, type ExchangeRate$1 as ExchangeRate, ExchangeRatesResource, type Fulfillment$1 as Fulfillment, type FulfillmentOrder$2 as FulfillmentOrder, FulfillmentOrdersResource, FulfillmentsResource, type GenerateVariantsResult$1 as GenerateVariantsResult, type GiftCard, type CreditDebitBody as GiftCardCreditDebitBody, type GiftCardLookup, type GiftCardTransaction, GiftCardsResource, Hydra, HydraAuthenticationError, type HydraConfig, HydraConnectionError, HydraError, type HydraErrorBody, HydraIdempotencyError, HydraNotFoundError, HydraPermissionError, HydraRateLimitError, HydraValidationError, type Image$2 as Image, ImagesResource, IntegrationsResource, type InventoryLevel$1 as InventoryLevel, InventoryResource, type ListGiftCardTransactionsParams, type ListGiftCardsParams, type ListResponse, type Location$1 as Location, LocationsResource, type Lookbook$1 as Lookbook, type LookbookTag$1 as LookbookTag, LookbooksResource, type LoyaltySummary, type MembershipPlan$1 as MembershipPlan, MembershipPlansResource, MetafieldsResource, type NotificationLog$1 as NotificationLog, NotificationsResource, type Order$2 as Order, OrdersResource, type PaginateOptions, type Pagination, type PosAnalyticsDashboard, type Post$1 as Post, PostsResource, type Product$1 as Product, type ProductStats$1 as ProductStats, ProductsResource, type Promotion$1 as Promotion, PromotionsResource, type PurchaseOrder$1 as PurchaseOrder, PurchaseOrdersResource, type Redirect$1 as Redirect, RedirectsResource, type Refund$1 as Refund, RefundsResource, type RequestOptions, type ResourceRequestOptions, type Return$1 as Return, ReturnsResource, SearchResource, type ShippingRate$1 as ShippingRate, ShippingResource, type ShippingZone$1 as ShippingZone, type Slot, type Store$1 as Store, StoreCreditResource, StoreResource, type SuggestedSlot$1 as SuggestedSlot, type Tag$1 as Tag, TagsResource, type TaxExemption$1 as TaxExemption, type TaxGroup$1 as TaxGroup, type TaxRate$1 as TaxRate, TaxResource, type UpdateGiftCardBody, type Variant$2 as Variant, type VariantPrice$1 as VariantPrice, VariantsResource, type Webhook$1 as Webhook, WebhooksResource, paginate, toArray };
21741
+ export { AddressesResource, type AnalyticsActionItems$1 as AnalyticsActionItems, type AnalyticsOrdersSeries$1 as AnalyticsOrdersSeries, AnalyticsResource, type AnalyticsSummary$1 as AnalyticsSummary, type AnalyticsTimeSeries$1 as AnalyticsTimeSeries, type AnalyticsTopProduct$1 as AnalyticsTopProduct, type AppInfo, type Appointment$1 as Appointment, type AvailabilityOverride$1 as AvailabilityOverride, BookingsResource, type Cart$1 as Cart, type CartItem, CartResource, type Channel$1 as Channel, ChannelsResource, type CheckoutCreate$1 as CheckoutCreate, type CheckoutGet$1 as CheckoutGet, type CheckoutListItem$1 as CheckoutListItem, CheckoutResource, CheckoutsResource, type Collection$1 as Collection, CollectionsResource, CompaniesResource, type Company$1 as Company, ContentCategoriesResource, type ContentCategory$1 as ContentCategory, type CreateGiftCardBody, type Customer$1 as Customer, type CustomerGroup$1 as CustomerGroup, CustomerGroupsResource, type CustomerMembership$1 as CustomerMembership, type CustomerPhoto$1 as CustomerPhoto, CustomerPhotosResource, CustomersResource, type DataResponse, type DayAvailability$1 as DayAvailability, type Discount$1 as Discount, DiscountsResource, type DraftOrder$1 as DraftOrder, DraftOrdersResource, type ExchangeRate$1 as ExchangeRate, ExchangeRatesResource, type Fulfillment$1 as Fulfillment, type FulfillmentOrder$2 as FulfillmentOrder, FulfillmentOrdersResource, FulfillmentsResource, type GenerateVariantsResult$1 as GenerateVariantsResult, type GiftCard, type GiftCardConvertResult, type CreditDebitBody as GiftCardCreditDebitBody, type GiftCardLookup, type GiftCardTransaction, GiftCardsResource, Hydra, HydraAuthenticationError, type HydraConfig, HydraConnectionError, HydraError, type HydraErrorBody, HydraIdempotencyError, HydraNotFoundError, HydraPermissionError, HydraRateLimitError, HydraValidationError, type Image$2 as Image, ImagesResource, IntegrationsResource, type InventoryLevel$1 as InventoryLevel, InventoryResource, type ListGiftCardTransactionsParams, type ListGiftCardsParams, type ListResponse, type Location$1 as Location, LocationsResource, type Lookbook$1 as Lookbook, type LookbookTag$1 as LookbookTag, LookbooksResource, type LoyaltySummary, type MembershipPlan$1 as MembershipPlan, MembershipPlansResource, MetafieldsResource, type NotificationLog$1 as NotificationLog, NotificationsResource, type Order$2 as Order, OrdersResource, type PaginateOptions, type Pagination, type PosAnalyticsDashboard, type Post$1 as Post, PostsResource, type Product$1 as Product, type ProductStats$1 as ProductStats, ProductsResource, type Promotion$1 as Promotion, PromotionsResource, type PurchaseOrder$1 as PurchaseOrder, PurchaseOrdersResource, type Redirect$1 as Redirect, RedirectsResource, type Refund$1 as Refund, RefundsResource, type RequestOptions, type ResourceRequestOptions, type Return$1 as Return, ReturnsResource, SearchResource, type ShippingRate$1 as ShippingRate, ShippingResource, type ShippingZone$1 as ShippingZone, type Slot, type Store$1 as Store, StoreCreditResource, StoreResource, type SuggestedSlot$1 as SuggestedSlot, type Tag$1 as Tag, TagsResource, type TaxExemption$1 as TaxExemption, type TaxGroup$1 as TaxGroup, type TaxRate$1 as TaxRate, TaxResource, type UpdateGiftCardBody, type Variant$2 as Variant, type VariantPrice$1 as VariantPrice, VariantsResource, type Webhook$1 as Webhook, WebhooksResource, paginate, toArray };
package/dist/index.js CHANGED
@@ -1797,6 +1797,10 @@ var GiftCardsResource = class {
1797
1797
  async debit(id, body, options) {
1798
1798
  return this.client.request("POST", `/v1/gift-cards/${id}/debit`, { body, ...options });
1799
1799
  }
1800
+ /** Convert a gift card's remaining balance into store credit on a customer account. */
1801
+ async convert(id, body) {
1802
+ return this.client.request("POST", `/v1/gift-cards/${id}/convert`, { body });
1803
+ }
1800
1804
  /** Look up a gift card by code (publishable key OK). */
1801
1805
  async lookup(code) {
1802
1806
  return this.client.request("GET", "/v1/gift-cards/lookup", { params: { code } });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gethydra/sdk",
3
- "version": "0.1.34",
3
+ "version": "0.1.36",
4
4
  "description": "Official TypeScript SDK for the Hydra Commerce API",
5
5
  "license": "MIT",
6
6
  "author": "Grant Capital Group",