guidewhale 1.0.1 → 1.0.3

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.
Files changed (2) hide show
  1. package/README.md +23 -21
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -18,32 +18,34 @@ Make sure to replace placeholder values with your actual environment token and u
18
18
  import gwhale from 'guidewhale';
19
19
 
20
20
  gwhale.init("<guidewhale_environment_code>", { // REQUIRED - string - make sure to use the correct environment code for desired application environment (e.g. 'prod-1234abcd')
21
- gdpr: true, // OPTIONAL - true | false - enable GDPR mode to require user consent before tracking data under their user_id
22
- gdprConsent: true, // OPTIONAL - true | false - Whether user has given consent to track their data
21
+ gdpr: true, // OPTIONAL - true | false - enable GDPR mode to require user consent before tracking data under their user_id
22
+ gdprConsent: true, // OPTIONAL - true | false - Whether user has given consent to track their data
23
23
  user: {
24
- user_id: <user_id>, // REQUIRED - string - unique user identifier (e.g. '100000356', '6099047b-660b-4f2e-a878-fb66a12c1840', 'john.smith@example.com')
24
+ user_id: <user_id>, // REQUIRED - string - unique user identifier (e.g. '100000356', '6099047b-660b-4f2e-a878-fb66a12c1840', 'john.smith@example.com')
25
25
  email: <user_email>, // RECOMMENDED - string - email is used as the key to map user data for most integrations (e.g. 'john.smith@example.com')
26
- first_name: <user_first_name>, // RECOMMENDED - string - can be used to personalize GuideWhale content (e.g. 'John')
27
- last_name: <user_last_name>, // RECOMMENDED - string - can be used to personalize GuideWhale content (e.g. 'Smith')
28
- date_signed_up: <user_signup_date>, // RECOMMENDED - date - can be used to selectively show content to new users (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
29
- ... // OPTIONAL - string | number | date - custom user properties (e.g. gender: 'female')
26
+ image_url: <profile_image_url>, // RECOMMENDED - string - used to display user's profile image inside GuideWhale dashboard (e.g. 'https://cdn.guidewhale.com/users/1234abcd/profile.png')
27
+ first_name: <user_first_name>, // RECOMMENDED - string - can be used to personalize GuideWhale content (e.g. 'John')
28
+ last_name: <user_last_name>, // RECOMMENDED - string - can be used to personalize GuideWhale content (e.g. 'Smith')
29
+ date_signed_up: <user_signup_date>, // RECOMMENDED - date - can be used to selectively show content to new users (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
30
+ ... // OPTIONAL - string | number | date - custom user properties (e.g. gender: 'female')
30
31
  },
31
- company: {
32
- company_id: <company_id>, // REQUIRED - string - unique company identifier (e.g. '100000356', '6099047b-660b-4f2e-a878-fb66a12c1840')
32
+ company: {
33
+ company_id: <company_id>, // REQUIRED - string - unique company identifier (e.g. '100000356', '6099047b-660b-4f2e-a878-fb66a12c1840')
33
34
  name: <company_name>, // RECOMMENDED - string - can be used to personalize GuideWhale content (e.g. 'GuideWhale Inc.')
34
- plan: <company_subscription_plan>, // RECOMMENDED - string - can be used to target users for upselling, discounts, and promotions (e.g. 'free', 'basic', 'pro')
35
- date_signed_up: <company_signup_date>, // RECOMMENDED - date - can be used to selectively show content to new companies (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
36
- date_renewal: <company_renewal_date>, // RECOMMENDED - date - can be used to encourage companies to renew their contract (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
37
- mrr: <company_mrr>, // RECOMMENDED - number - can be used to target companies spending more or less (e.g. 100.0, 500.0, 1000.0)
38
- license_count: <company_license_count>, // RECOMMENDED - number - can be used to target bigger customers (e.g. 1, 5, 10, 50)
39
- industry: <company_industry>, // RECOMMENDED - string - can be used to segment companies by industries (e.g. 'Medical', 'Financial Services')
40
- size: <company_size>, // RECOMMENDED - number - can be used to segment companies by their size (e.g. 100, 250, 1000)
41
- ... // OPTIONAL - string | number | date - custom company properties (e.g. location: 'United States')
35
+ image_url: <logo_image_url>, // RECOMMENDED - string - used to display logo image inside GuideWhale dashboard (e.g. 'https://cdn.guidewhale.com/companies/1234abcd/logo.png')
36
+ plan: <company_subscription_plan>, // RECOMMENDED - string - can be used to target users for upselling, discounts, and promotions (e.g. 'free', 'basic', 'pro')
37
+ date_signed_up: <company_signup_date>, // RECOMMENDED - date - can be used to selectively show content to new companies (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
38
+ date_renewal: <company_renewal_date>, // RECOMMENDED - date - can be used to encourage companies to renew their contract (Must be ISO8601 string - e.g. "2024-01-01T12:00:00Z")
39
+ mrr: <company_mrr>, // RECOMMENDED - number - can be used to target companies spending more or less (e.g. 100.0, 500.0, 1000.0)
40
+ license_count: <company_license_count>, // RECOMMENDED - number - can be used to target bigger customers (e.g. 1, 5, 10, 50)
41
+ industry: <company_industry>, // RECOMMENDED - string - can be used to segment companies by industries (e.g. 'Medical', 'Financial Services')
42
+ size: <company_size>, // RECOMMENDED - number - can be used to segment companies by their size (e.g. 100, 250, 1000)
43
+ ... // OPTIONAL - string | number | date - custom company properties (e.g. location: 'United States')
42
44
  },
43
45
  membership: {
44
- is_primary: <user_is_primary_contact>, // RECOMMENDED - boolean - whether user is the primary contact for the company (e.g. true, false)
45
- role: <user_company_role>, // RECOMMENDED - string - you can target users based on their role in the company (e.g. 'admin', 'user', 'guest')
46
- ... // OPTIONAL - string | number | date - custom user company membership properties (e.g. employee_number: 12345)
46
+ is_primary: <user_is_primary_contact>, // RECOMMENDED - boolean - whether user is the primary contact for the company (e.g. true, false)
47
+ role: <user_company_role>, // RECOMMENDED - string - you can target users based on their role in the company (e.g. 'admin', 'user', 'guest')
48
+ ... // OPTIONAL - string | number | date - custom user company membership properties (e.g. employee_number: 12345)
47
49
  }
48
50
  });
49
51
  ```
@@ -53,7 +55,7 @@ By default, GuideWhale client uses `window.location.assign` to redirect users be
53
55
 
54
56
  ```typescript
55
57
  gwhale.onRedirect((url: string) => {
56
- //Your custom redirect logic
58
+ //Your custom redirect logic
57
59
  });
58
60
  ```
59
61
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "guidewhale",
3
- "version": "1.0.1",
3
+ "version": "1.0.3",
4
4
  "description": "GuideWhale SDK client script loader",
5
5
  "type": "module",
6
6
  "main": "dist/guidewhale.js",