TypeScript SDK
Guides and resource documentation for the Requiply TypeScript SDK.
The @requiply/api-sdk package exports RequiplyClient, RequiplyError, and all public TypeScript types from its root entry point.
Get started
Resources
- Inventory and Categories, including bundles
- Availability and Pricing
- Bookings
- Clients
- Sales and Goods for Sale
- Organization
- Reports
All requests are sent below:
https://api.requiply.com/api/public/v1
Upgrading from older versions
Version 0.2.0 brings the SDK in line with the public API. These changes can break code written for 0.1.x:
| Change | What to do |
|---|---|
RequiplyError.code is removed. It was never set. | Read error.reason for the machine-readable reason, and error.data for the fields that come with it. See Error Handling. |
The idempotencyKey request option is removed. The API never deduplicated requests. | Do not retry bookings.create() or sales.create() blindly: a retry can create a second booking or sale. See Request Options. |
bookings.create() returns either a created booking or a refused one. | Check result.success before reading reservationId. See Bookings. |
paymentType is required unless asRequest is true. | Pass a paymentType for regular bookings. The API already refused them without one. |
Version 0.2.0 also adds the Sales resources, saleLines and adjustment on quotes and bookings, workingHours in org.info(), saleItems on booking details, excludeFromDiscounts on services, and stillOutUnits on overdue report entries. The full list is in the package CHANGELOG.
Version 0.2.1 adds bundles: bundles.list() and bundles.get(), bundles on pricing.quote() and bookings.create(), bundleDiscountAmount and lineBundles in quotes, and bundles on item group details. Nothing breaks.