@parra/parra-js-sdk 0.3.498 → 0.3.502

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.
@@ -1099,13 +1099,8 @@ export interface UserPurchase {
1099
1099
  entitlements?: Array<UserEntitlement> | null;
1100
1100
  }
1101
1101
  export declare enum BillingSourceType {
1102
- stripe = "stripe",
1103
- paypal = "paypal",
1104
1102
  apple = "apple",
1105
- google = "google",
1106
- amazon = "amazon",
1107
- microsoft = "microsoft",
1108
- other = "other"
1103
+ parra = "parra"
1109
1104
  }
1110
1105
  export interface CreateBillingSourceAppleData {
1111
1106
  app_store_connect_api_connection_id: string;
@@ -1407,6 +1402,41 @@ export interface CreateCourseRequestBody {
1407
1402
  icon_asset_id?: string | null;
1408
1403
  header_image_asset_id?: string | null;
1409
1404
  }
1405
+ export interface MarketingContentHeaderSection {
1406
+ id: string;
1407
+ title: string;
1408
+ type: string;
1409
+ description?: string | null;
1410
+ icon?: ImageAssetStub | null;
1411
+ }
1412
+ export interface MarketingContentOffering {
1413
+ id: string;
1414
+ title: string;
1415
+ }
1416
+ export interface MarketingContentOfferingSection {
1417
+ id: string;
1418
+ type: string;
1419
+ offerings: Array<MarketingContentOffering>;
1420
+ }
1421
+ export interface PricingTableItem {
1422
+ id: string;
1423
+ }
1424
+ export interface PricingTable {
1425
+ id: string;
1426
+ title?: string | null;
1427
+ description?: string | null;
1428
+ items: Array<PricingTableItem>;
1429
+ }
1430
+ export interface MarketingContentPricingTableSection {
1431
+ id: string;
1432
+ type: string;
1433
+ pricing_table: PricingTable;
1434
+ }
1435
+ export type MarketingContentPage = MarketingContentHeaderSection | MarketingContentOfferingSection | MarketingContentPricingTableSection;
1436
+ export interface MarketingContent {
1437
+ id: string;
1438
+ sections: Array<MarketingContentPage>;
1439
+ }
1410
1440
  export declare enum LessonType {
1411
1441
  youtubeVideo = "youtube_video"
1412
1442
  }
@@ -1471,6 +1501,7 @@ export interface Course {
1471
1501
  title: string;
1472
1502
  description?: string | null;
1473
1503
  is_enrolled?: boolean | null;
1504
+ marketing_content?: MarketingContent | null;
1474
1505
  header_image?: ImageAssetStub | null;
1475
1506
  modules?: Array<CourseModule>;
1476
1507
  }
@@ -1532,6 +1563,7 @@ export interface AppCourse {
1532
1563
  tenant_id: string;
1533
1564
  title: string;
1534
1565
  description?: string | null;
1566
+ marketing_content?: MarketingContent | null;
1535
1567
  modules: Array<AppCourseModule>;
1536
1568
  instructors: Array<CourseInstructor>;
1537
1569
  is_enrolled?: boolean | null;
@@ -5135,10 +5167,14 @@ declare class ParraAPI {
5135
5167
  removeReactionFromChatMessage: (tenant_id: string, message_id: string, reaction_id: string, options?: Options) => Promise<Response>;
5136
5168
  createCourse: (tenant_id: string, body: CreateCourseRequestBody, options?: Options) => Promise<Course>;
5137
5169
  listCourses: (tenant_id: string, options?: Options) => Promise<Array<Course>>;
5138
- getCourseById: (tenant_id: string, course_id: string, options?: Options) => Promise<Course>;
5170
+ getCourseById: (tenant_id: string, course_id: string, query?: {
5171
+ include?: string;
5172
+ }, options?: Options) => Promise<Course>;
5139
5173
  updateCourseById: (tenant_id: string, course_id: string, body?: UpdateCourseRequestBody, options?: Options) => Promise<Course>;
5140
5174
  deleteCourseById: (tenant_id: string, course_id: string, options?: Options) => Promise<Response>;
5141
- getAppCourseById: (tenant_id: string, application_id: string, course_id: string, options?: Options) => Promise<AppCourse>;
5175
+ getAppCourseById: (tenant_id: string, course_id: string, query?: {
5176
+ include?: string;
5177
+ }, options?: Options) => Promise<AppCourse>;
5142
5178
  enrollInCourse: (tenant_id: string, course_id: string, options?: Options) => Promise<Course>;
5143
5179
  createModuleForCourse: (tenant_id: string, course_id: string, body: CreateCourseRequestBody, options?: Options) => Promise<CourseModule>;
5144
5180
  updateModuleForCourseById: (tenant_id: string, course_id: string, course_module_id: string, body?: UpdateCourseModuleRequestBody, options?: Options) => Promise<CourseModule>;
package/dist/ParraAPI.js CHANGED
@@ -172,13 +172,8 @@ var ApplePurchaseType;
172
172
  })(ApplePurchaseType || (exports.ApplePurchaseType = ApplePurchaseType = {}));
173
173
  var BillingSourceType;
174
174
  (function (BillingSourceType) {
175
- BillingSourceType["stripe"] = "stripe";
176
- BillingSourceType["paypal"] = "paypal";
177
175
  BillingSourceType["apple"] = "apple";
178
- BillingSourceType["google"] = "google";
179
- BillingSourceType["amazon"] = "amazon";
180
- BillingSourceType["microsoft"] = "microsoft";
181
- BillingSourceType["other"] = "other";
176
+ BillingSourceType["parra"] = "parra";
182
177
  })(BillingSourceType || (exports.BillingSourceType = BillingSourceType = {}));
183
178
  var ChatChannelType;
184
179
  (function (ChatChannelType) {
@@ -1025,9 +1020,9 @@ var ParraAPI = /** @class */ (function () {
1025
1020
  if (options === void 0) { options = {}; }
1026
1021
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/courses"), __assign({ method: "get" }, options));
1027
1022
  };
1028
- this.getCourseById = function (tenant_id, course_id, options) {
1023
+ this.getCourseById = function (tenant_id, course_id, query, options) {
1029
1024
  if (options === void 0) { options = {}; }
1030
- return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/courses/").concat(course_id), __assign({ method: "get" }, options));
1025
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/courses/").concat(course_id), __assign({ method: "get", query: query }, options));
1031
1026
  };
1032
1027
  this.updateCourseById = function (tenant_id, course_id, body, options) {
1033
1028
  if (options === void 0) { options = {}; }
@@ -1039,9 +1034,9 @@ var ParraAPI = /** @class */ (function () {
1039
1034
  if (options === void 0) { options = {}; }
1040
1035
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/courses/").concat(course_id), __assign({ method: "delete" }, options));
1041
1036
  };
1042
- this.getAppCourseById = function (tenant_id, application_id, course_id, options) {
1037
+ this.getAppCourseById = function (tenant_id, course_id, query, options) {
1043
1038
  if (options === void 0) { options = {}; }
1044
- return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/applications/").concat(application_id, "/courses/").concat(course_id), __assign({ method: "get" }, options));
1039
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/app/courses/").concat(course_id), __assign({ method: "get", query: query }, options));
1045
1040
  };
1046
1041
  this.enrollInCourse = function (tenant_id, course_id, options) {
1047
1042
  if (options === void 0) { options = {}; }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parra/parra-js-sdk",
3
- "version": "0.3.498",
3
+ "version": "0.3.502",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",