academe-kit 0.3.8 → 0.3.9

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.esm.js CHANGED
@@ -5200,6 +5200,52 @@ function createSeatCodeService(apiClient) {
5200
5200
  };
5201
5201
  }
5202
5202
 
5203
+ function createProductService(apiClient) {
5204
+ return {
5205
+ /**
5206
+ * List all products with optional filters
5207
+ */
5208
+ getProducts(params) {
5209
+ return apiClient.GET("/products", {
5210
+ params: { query: params },
5211
+ });
5212
+ },
5213
+ /**
5214
+ * Get product by ID
5215
+ */
5216
+ getProductById(id) {
5217
+ return apiClient.GET("/products/{id}", {
5218
+ params: { path: { id } },
5219
+ });
5220
+ },
5221
+ /**
5222
+ * Create a new product
5223
+ */
5224
+ createProduct(body) {
5225
+ return apiClient.POST("/products", {
5226
+ body,
5227
+ });
5228
+ },
5229
+ /**
5230
+ * Update product information
5231
+ */
5232
+ updateProduct(id, body) {
5233
+ return apiClient.PATCH("/products/{id}", {
5234
+ params: { path: { id } },
5235
+ body,
5236
+ });
5237
+ },
5238
+ /**
5239
+ * Delete product
5240
+ */
5241
+ deleteProduct(id) {
5242
+ return apiClient.DELETE("/products/{id}", {
5243
+ params: { path: { id } },
5244
+ });
5245
+ },
5246
+ };
5247
+ }
5248
+
5203
5249
  function createAcademeApiClient(baseUrl) {
5204
5250
  return createClient({ baseUrl });
5205
5251
  }
@@ -5218,6 +5264,7 @@ function createAcademeServices(apiClient) {
5218
5264
  quiz: createQuizService(apiClient),
5219
5265
  certificate: createCertificateService(apiClient),
5220
5266
  seatCode: createSeatCodeService(apiClient),
5267
+ product: createProductService(apiClient),
5221
5268
  };
5222
5269
  }
5223
5270