@opencals/storefront-sdk is the official TypeScript client for the Storefront
API — generated from the OpenAPI spec, fully typed, with Zod runtime validation
and formatting helpers for prices, durations, and timezones. MIT licensed.
Version history
Custom Attributes
Custom attributes on appointments. Ships support for the new
custom attributes feature.
CreateAppointmentaccepts an optionalcustomAttributesmap (string keys → string values) to attach arbitrary data at booking time- Appointment responses now echo
customAttributes
DiscountsAuth
Discounts & passwordless auth. Ships support for the new
discounts feature and magic-link sign-in.
CartService.applyDiscountCode()andCartService.removeDiscountCode()- New discount types:
AppliedDiscount,ApplyCode,CartItemAppliedDiscount,OrderLineItemDiscount,OrderLineItemDiscountWritable - Passwordless / magic-link auth:
AuthService.requestLoginCode(),AuthService.verifyLoginCode(),AuthService.resolveLink(), withRequestLoginCode,VerifyLoginCode,ResolveLinkResponsetypes
Fix
- Fixed the
AppointmentAddOntype, which was missing fields due to a backend OpenAPI schema name collision (the DTO was renamed toCreateAppointmentAddOnDto)
Add-Ons
Add-ons support. First version with the Add-Ons
feature.
AddonService, withCartAddOnItem,AppointmentAddOn, andOrderAddOnLineItemtypesStoreService.getStorePublicSettings()for storefront currency and public store settings
API change
Service classes. Released alongside the public
Storefront API v1.
- Grouped SDK methods into
*Serviceclasses by tag (e.g.ProductService,AuthService,CartService) - Stripped the controller prefix from operation IDs (e.g.
ProductService.list()instead ofproductList()) - Fixed
Authoperations missing from the spec (tag collision with the admin controller) - Rewrote the README with updated examples and a service table
Initial
Initial releases of the auto-generated TypeScript client.
- v0.1.0 — auto-generated client, Zod validation schemas,
setupOpencals()one-line init, API-key/error/logging interceptors, and helpers (formatPrice,formatDuration, timezone conversion). Full support for products, cart, checkout, customer auth, appointments, orders, and feedback. - v0.1.1 — renamed
external_domain→externalDomainonStorePublicSettings. - v0.1.2 — renamed
client_secret→clientSecretonCheckoutStartResponse.