@izak0s/spacebring-api 3.2.0 → 3.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/README.md CHANGED
@@ -15,7 +15,7 @@ A fully-typed TypeScript client for the [Spacebring](https://www.spacebring.com)
15
15
 
16
16
  ## Features
17
17
 
18
- - **<!-- coverage -->184 operations across 21 resource groups<!-- /coverage -->** — the full Spacebring API surface
18
+ - **<!-- coverage -->185 operations across 21 resource groups<!-- /coverage -->** — the full Spacebring API surface
19
19
  - **Auto-generated** from the official OpenAPI spec — types and facade regenerate anytime the spec changes
20
20
  - **Nested, discoverable API** — `sb.billing.invoices.pay(id)`, `sb.visitors.visits.checkIn(body)`
21
21
  - **Auto-pagination** — every paginated list endpoint has an `iterate()` async generator that walks `nextPageToken` for you
package/dist/index.cjs CHANGED
@@ -2042,6 +2042,14 @@ function createResources(client, defaults) {
2042
2042
  async update(id, resource, options) {
2043
2043
  return unwrap(await client.PATCH("/resources/v1/{id}", { params: { path: { id } }, body: { resource }, signal: options?.signal }), "PATCH /resources/v1/{id}");
2044
2044
  },
2045
+ /**
2046
+ * Retrieve resource assignments
2047
+ *
2048
+ * Retrieve resource assignments in the location. An assignment links a resource, or a number of seats in it, to a company or a member for the duration of a subscription.
2049
+ */
2050
+ async getAssignments(query, options) {
2051
+ return unwrapProp(await client.GET("/resources/v1/assignments", { params: { query }, signal: options?.signal }), "assignments", "GET /resources/v1/assignments");
2052
+ },
2045
2053
  bookings: {
2046
2054
  /**
2047
2055
  * Retrieve bookings