@izak0s/spacebring-api 5.6.0 → 6.0.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.cjs +12 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1707 -648
- package/dist/index.d.ts +1707 -648
- package/dist/index.js +12 -12
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1989,11 +1989,11 @@ function createResources(client, defaults) {
|
|
|
1989
1989
|
*
|
|
1990
1990
|
* Get a certain resource.
|
|
1991
1991
|
*
|
|
1992
|
-
* @param
|
|
1992
|
+
* @param resourceId The id of the resource.
|
|
1993
1993
|
* @param options Request options (abort signal).
|
|
1994
1994
|
*/
|
|
1995
|
-
async get(
|
|
1996
|
-
return unwrapProp(await client.GET("/resources/v1/{
|
|
1995
|
+
async get(resourceId, options) {
|
|
1996
|
+
return unwrapProp(await client.GET("/resources/v1/{resourceId}", { params: { path: { resourceId } }, signal: options?.signal }), "resource", "GET /resources/v1/{resourceId}");
|
|
1997
1997
|
},
|
|
1998
1998
|
/**
|
|
1999
1999
|
* Create a resource
|
|
@@ -2008,12 +2008,12 @@ function createResources(client, defaults) {
|
|
|
2008
2008
|
*
|
|
2009
2009
|
* Patch a certain resource.
|
|
2010
2010
|
*
|
|
2011
|
-
* @param
|
|
2011
|
+
* @param resourceId The id of the resource.
|
|
2012
2012
|
* @param resource The `resource` payload.
|
|
2013
2013
|
* @param options Request options (abort signal).
|
|
2014
2014
|
*/
|
|
2015
|
-
async update(
|
|
2016
|
-
return unwrap(await client.PATCH("/resources/v1/{
|
|
2015
|
+
async update(resourceId, resource, options) {
|
|
2016
|
+
return unwrap(await client.PATCH("/resources/v1/{resourceId}", { params: { path: { resourceId } }, body: { resource }, signal: options?.signal }), "PATCH /resources/v1/{resourceId}");
|
|
2017
2017
|
},
|
|
2018
2018
|
/**
|
|
2019
2019
|
* Retrieve resource assignments
|
|
@@ -2046,11 +2046,11 @@ function createResources(client, defaults) {
|
|
|
2046
2046
|
/**
|
|
2047
2047
|
* Get a booking
|
|
2048
2048
|
*
|
|
2049
|
-
* @param
|
|
2049
|
+
* @param bookingId ID of the booking. For a single occurrence of a repeating booking, append the occurrence date: `_`.
|
|
2050
2050
|
* @param options Request options (abort signal).
|
|
2051
2051
|
*/
|
|
2052
|
-
async get(
|
|
2053
|
-
return unwrapProp(await client.GET("/resources/bookings/v1/{
|
|
2052
|
+
async get(bookingId, options) {
|
|
2053
|
+
return unwrapProp(await client.GET("/resources/bookings/v1/{bookingId}", { params: { path: { bookingId } }, signal: options?.signal }), "booking", "GET /resources/bookings/v1/{bookingId}");
|
|
2054
2054
|
},
|
|
2055
2055
|
/** Create a booking */
|
|
2056
2056
|
async create(booking, options) {
|
|
@@ -2059,11 +2059,11 @@ function createResources(client, defaults) {
|
|
|
2059
2059
|
/**
|
|
2060
2060
|
* Delete a booking
|
|
2061
2061
|
*
|
|
2062
|
-
* @param
|
|
2062
|
+
* @param bookingId ID of the booking. For a single occurrence of a repeating booking, append the occurrence date: `_`.
|
|
2063
2063
|
* @param options Request options (abort signal).
|
|
2064
2064
|
*/
|
|
2065
|
-
async delete(
|
|
2066
|
-
return unwrap(await client.DELETE("/resources/bookings/v1/{
|
|
2065
|
+
async delete(bookingId, options) {
|
|
2066
|
+
return unwrap(await client.DELETE("/resources/bookings/v1/{bookingId}", { params: { path: { bookingId } }, signal: options?.signal }), "DELETE /resources/bookings/v1/{bookingId}");
|
|
2067
2067
|
}
|
|
2068
2068
|
}
|
|
2069
2069
|
};
|