@transcend-io/cli 4.55.0 → 4.57.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.
Files changed (45) hide show
  1. package/README.md +153 -32
  2. package/build/cli-request-approve.d.ts +3 -0
  3. package/build/cli-request-approve.d.ts.map +1 -0
  4. package/build/cli-request-approve.js +56 -0
  5. package/build/cli-request-approve.js.map +1 -0
  6. package/build/cli-upload-data-flows-from-csv.d.ts +3 -0
  7. package/build/cli-upload-data-flows-from-csv.d.ts.map +1 -0
  8. package/build/cli-upload-data-flows-from-csv.js +59 -0
  9. package/build/cli-upload-data-flows-from-csv.js.map +1 -0
  10. package/build/consent-manager/index.d.ts +1 -0
  11. package/build/consent-manager/index.d.ts.map +1 -1
  12. package/build/consent-manager/index.js +1 -0
  13. package/build/consent-manager/index.js.map +1 -1
  14. package/build/consent-manager/uploadDataFlowsFromCsv.d.ts +53 -0
  15. package/build/consent-manager/uploadDataFlowsFromCsv.d.ts.map +1 -0
  16. package/build/consent-manager/uploadDataFlowsFromCsv.js +122 -0
  17. package/build/consent-manager/uploadDataFlowsFromCsv.js.map +1 -0
  18. package/build/graphql/gqls/consentManager.d.ts.map +1 -1
  19. package/build/graphql/gqls/consentManager.js +6 -1
  20. package/build/graphql/gqls/consentManager.js.map +1 -1
  21. package/build/graphql/gqls/request.d.ts +2 -0
  22. package/build/graphql/gqls/request.d.ts.map +1 -1
  23. package/build/graphql/gqls/request.js +19 -1
  24. package/build/graphql/gqls/request.js.map +1 -1
  25. package/build/graphql/syncConfigurationToTranscend.d.ts.map +1 -1
  26. package/build/graphql/syncConfigurationToTranscend.js +2 -52
  27. package/build/graphql/syncConfigurationToTranscend.js.map +1 -1
  28. package/build/graphql/syncDataFlows.d.ts +9 -0
  29. package/build/graphql/syncDataFlows.d.ts.map +1 -1
  30. package/build/graphql/syncDataFlows.js +71 -2
  31. package/build/graphql/syncDataFlows.js.map +1 -1
  32. package/build/requests/approvePrivacyRequests.d.ts +20 -0
  33. package/build/requests/approvePrivacyRequests.d.ts.map +1 -0
  34. package/build/requests/approvePrivacyRequests.js +61 -0
  35. package/build/requests/approvePrivacyRequests.js.map +1 -0
  36. package/build/requests/index.d.ts +1 -0
  37. package/build/requests/index.d.ts.map +1 -1
  38. package/build/requests/index.js +1 -0
  39. package/build/requests/index.js.map +1 -1
  40. package/build/requests/splitCsvToList.d.ts +4 -0
  41. package/build/requests/splitCsvToList.d.ts.map +1 -1
  42. package/build/requests/splitCsvToList.js +4 -0
  43. package/build/requests/splitCsvToList.js.map +1 -1
  44. package/build/tsbuildinfo +1 -1
  45. package/package.json +4 -2
package/README.md CHANGED
@@ -21,50 +21,58 @@
21
21
  - [Authentication](#authentication-2)
22
22
  - [Usage](#usage-3)
23
23
  - [Arguments](#arguments-2)
24
- - [tr-request-upload](#tr-request-upload)
24
+ - [tr-request-approve](#tr-request-approve)
25
25
  - [Authentication](#authentication-3)
26
26
  - [Arguments](#arguments-3)
27
27
  - [Usage](#usage-4)
28
- - [tr-request-restart](#tr-request-restart)
28
+ - [tr-request-upload](#tr-request-upload)
29
29
  - [Authentication](#authentication-4)
30
30
  - [Arguments](#arguments-4)
31
31
  - [Usage](#usage-5)
32
- - [tr-request-export](#tr-request-export)
32
+ - [tr-request-restart](#tr-request-restart)
33
33
  - [Authentication](#authentication-5)
34
34
  - [Arguments](#arguments-5)
35
35
  - [Usage](#usage-6)
36
- - [tr-cron-pull-identifiers](#tr-cron-pull-identifiers)
36
+ - [tr-request-export](#tr-request-export)
37
37
  - [Authentication](#authentication-6)
38
38
  - [Arguments](#arguments-6)
39
39
  - [Usage](#usage-7)
40
- - [tr-cron-mark-identifiers-completed](#tr-cron-mark-identifiers-completed)
40
+ - [tr-cron-pull-identifiers](#tr-cron-pull-identifiers)
41
41
  - [Authentication](#authentication-7)
42
42
  - [Arguments](#arguments-7)
43
43
  - [Usage](#usage-8)
44
- - [tr-manual-enrichment-pull-identifiers](#tr-manual-enrichment-pull-identifiers)
44
+ - [tr-cron-mark-identifiers-completed](#tr-cron-mark-identifiers-completed)
45
45
  - [Authentication](#authentication-8)
46
46
  - [Arguments](#arguments-8)
47
47
  - [Usage](#usage-9)
48
- - [tr-manual-enrichment-push-identifiers](#tr-manual-enrichment-push-identifiers)
48
+ - [tr-manual-enrichment-pull-identifiers](#tr-manual-enrichment-pull-identifiers)
49
49
  - [Authentication](#authentication-9)
50
50
  - [Arguments](#arguments-9)
51
51
  - [Usage](#usage-10)
52
- - [tr-mark-request-data-silos-completed](#tr-mark-request-data-silos-completed)
52
+ - [tr-manual-enrichment-push-identifiers](#tr-manual-enrichment-push-identifiers)
53
53
  - [Authentication](#authentication-10)
54
54
  - [Arguments](#arguments-10)
55
55
  - [Usage](#usage-11)
56
- - [tr-retry-request-data-silos](#tr-retry-request-data-silos)
56
+ - [tr-mark-request-data-silos-completed](#tr-mark-request-data-silos-completed)
57
57
  - [Authentication](#authentication-11)
58
58
  - [Arguments](#arguments-11)
59
59
  - [Usage](#usage-12)
60
- - [tr-update-consent-manager](#tr-update-consent-manager)
60
+ - [tr-retry-request-data-silos](#tr-retry-request-data-silos)
61
61
  - [Authentication](#authentication-12)
62
62
  - [Arguments](#arguments-12)
63
63
  - [Usage](#usage-13)
64
- - [tr-generate-api-keys](#tr-generate-api-keys)
64
+ - [tr-update-consent-manager](#tr-update-consent-manager)
65
65
  - [Authentication](#authentication-13)
66
66
  - [Arguments](#arguments-13)
67
67
  - [Usage](#usage-14)
68
+ - [tr-upload-data-flows-from-csv](#tr-upload-data-flows-from-csv)
69
+ - [Authentication](#authentication-14)
70
+ - [Arguments](#arguments-14)
71
+ - [Usage](#usage-15)
72
+ - [tr-generate-api-keys](#tr-generate-api-keys)
73
+ - [Authentication](#authentication-15)
74
+ - [Arguments](#arguments-15)
75
+ - [Usage](#usage-16)
68
76
 
69
77
  <!-- END doctoc generated TOC please keep comment here to allow auto update -->
70
78
 
@@ -86,6 +94,7 @@ yarn add -D @transcend-io/cli
86
94
  yarn tr-pull --auth=$TRANSCEND_API_KEY
87
95
  yarn tr-push --auth=$TRANSCEND_API_KEY
88
96
  yarn tr-discover-silos --auth=$TRANSCEND_API_KEY
97
+ yarn tr-request-approve --auth=$TRANSCEND_API_KEY
89
98
  yarn tr-request-upload --auth=$TRANSCEND_API_KEY
90
99
  yarn tr-request-export --auth=$TRANSCEND_API_KEY
91
100
  yarn tr-request-restart --auth=$TRANSCEND_API_KEY
@@ -95,6 +104,7 @@ yarn tr-manual-enrichment-pull-identifiers --auth=$TRANSCEND_API_KEY
95
104
  yarn tr-mark-request-data-silos-completed --auth=$TRANSCEND_API_KEY
96
105
  yarn tr-retry-request-data-silos --auth=$TRANSCEND_API_KEY
97
106
  yarn tr-update-consent-manager --auth=$TRANSCEND_API_KEY
107
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY
98
108
  yarn tr-generate-api-keys --auth=$TRANSCEND_API_KEY
99
109
  ```
100
110
 
@@ -108,6 +118,7 @@ npm i -D @transcend-io/cli
108
118
  tr-pull --auth=$TRANSCEND_API_KEY
109
119
  tr-push --auth=$TRANSCEND_API_KEY
110
120
  tr-discover-silos --auth=$TRANSCEND_API_KEY
121
+ tr-request-approve --auth=$TRANSCEND_API_KEY
111
122
  tr-request-upload --auth=$TRANSCEND_API_KEY
112
123
  tr-request-export --auth=$TRANSCEND_API_KEY
113
124
  tr-request-restart --auth=$TRANSCEND_API_KEY
@@ -117,6 +128,7 @@ tr-manual-enrichment-pull-identifiers --auth=$TRANSCEND_API_KEY
117
128
  tr-mark-request-data-silos-completed --auth=$TRANSCEND_API_KEY
118
129
  tr-retry-request-data-silos --auth=$TRANSCEND_API_KEY
119
130
  tr-update-consent-manager --auth=$TRANSCEND_API_KEY
131
+ tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY
120
132
  tr-generate-api-keys --auth=$TRANSCEND_API_KEY
121
133
  ```
122
134
 
@@ -128,17 +140,12 @@ npm i -g @transcend-io/cli
128
140
 
129
141
  # cli commands available everywhere on machine
130
142
  tr-pull --auth=$TRANSCEND_API_KEY
131
- tr-push --auth=$TRANSCEND_API_KEY
132
- tr-discover-silos --auth=$TRANSCEND_API_KEY
133
- tr-request-upload --auth=$TRANSCEND_API_KEY
134
- tr-request-restart --auth=$TRANSCEND_API_KEY
135
- tr-cron-pull-identifiers --auth=$TRANSCEND_API_KEY
136
- tr-cron-mark-identifiers-completed --auth=$TRANSCEND_API_KEY
143
+ ...
137
144
  ```
138
145
 
139
146
  Note:
140
147
 
141
- _The cli-commands default to using the EU Transcend backend. To use these commands with the US backend, you will need to use the flag --transcendUrl=https://api.us.transend.io._
148
+ _The cli-commands default to using the EU Transcend backend. To use these commands with the US backend, you will need to use the flag --transcendUrl=https://api.us.transcend.io._
142
149
 
143
150
  ## transcend.yml
144
151
 
@@ -271,7 +278,7 @@ _Note: The scopes for tr-push are comprehensive of the scopes for tr-pull_
271
278
 
272
279
  | Argument | Description | Type | Default | Required |
273
280
  | ---------------- | ---------------------------------------------------------------------------------------- | ------------------------------------------------------------ | ------------------------------------- | -------- |
274
- | auth | The Transcend API capable of fetching the configuration | string (API key or path to tr-generate-api-keys JSON output) | N/A | true |
281
+ | auth | The Transcend API key with the scopes necessary for the command. | string (API key or path to tr-generate-api-keys JSON output) | N/A | true |
275
282
  | resources | The different resource types to pull in (see table above for breakdown of each resource) | string | apiKeys,templates,dataSilos,enrichers | false |
276
283
  | file | Path to the YAML file to pull into | string - file-path | ./transcend.yml | false |
277
284
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -418,12 +425,12 @@ The API key needs the following scopes when pushing the various resource types:
418
425
 
419
426
  | Argument | Description | Type | Default | Required |
420
427
  | --------------- | ----------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------ | ------------------------ | -------- |
421
- | auth | The Transcend API capable of pushing the configuration | string (API key or path to tr-generate-api-keys JSON output) | N/A | true |
428
+ | auth | The Transcend API key with the scopes necessary for the command. | string (API key or path to tr-generate-api-keys JSON output) | N/A | true |
422
429
  | file | Path to the YAML file to push from | string - file-path | ./transcend.yml | false |
423
430
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
424
431
  | pageSize | The page size to use when paginating over the API | number | 50 | false |
425
432
  | variables | The variables to template into the YAML file when pushing configuration. e.g. domain:acme.com,stage:staging | string | N/A | false |
426
- | classifyService | classify data flow service if missing | boolean | false | false |
433
+ | classifyService | When true, automatically assign the service for a data flow based on the domain that is specified | boolean | false | false |
427
434
 
428
435
  #### Usage
429
436
 
@@ -594,6 +601,56 @@ You can include additional arguments as well:
594
601
  | auth | Transcend API key. | string | N/A | true |
595
602
  | fileGlobs | You can pass a [glob syntax pattern(s)](https://github.com/mrmlnc/fast-glob) to specify additional file paths to scan in addition to the default (ex: package.json). | string | N/A | false |
596
603
 
604
+ ### tr-request-approve
605
+
606
+ Bulk approve a set of privacy requests from the [Privacy Requests -> Incoming Requests](https://app.transcend.io/privacy-requests/incoming-requests) tab.
607
+
608
+ #### Authentication
609
+
610
+ In order to use this cli, you will first need to generate an API key on the Transcend Admin Dashboard (https://app.transcend.io/infrastructure/api-keys).
611
+
612
+ The API key needs the following scopes:
613
+
614
+ - Request Approval and Communication
615
+ - View Incoming Requests
616
+ - Manage Request Compilation
617
+
618
+ #### Arguments
619
+
620
+ | Argument | Description | Type | Default | Required |
621
+ | ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | --------------- | ------------------------ | -------- |
622
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
623
+ | actions | The [request actions](https://docs.transcend.io/docs/privacy-requests/configuring-requests/data-subject-requests#data-actions) to approve. | RequestAction[] | N/A | true |
624
+ | silentModeBefore | Any requests made before this date should be marked as silent mode | Date | N/A | false |
625
+ | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
626
+ | concurrency | The concurrency to use when uploading requests in parallel. | number | 100 | false |
627
+
628
+ #### Usage
629
+
630
+ Bulk approve all SALE_OPT_OUT and ERASURE requests
631
+
632
+ ```sh
633
+ yarn tr-request-approve --auth=$TRANSCEND_API_KEY --actions=SALE_OPT_OUT,ERASURE
634
+ ```
635
+
636
+ Specifying the backend URL, needed for US hosted backend infrastructure.
637
+
638
+ ```sh
639
+ yarn tr-request-approve --auth=$TRANSCEND_API_KEY --actions=ERASURE --transcendUrl=https://api.us.transcend.io
640
+ ```
641
+
642
+ Approve all requests, but mark any request made before 05/03/2023 as silent mode to prevent emailing the individual.
643
+
644
+ ```sh
645
+ yarn tr-request-approve --auth=$TRANSCEND_API_KEY --actions=SALE_OPT_OUT --silentModeBefore=05/03/2023
646
+ ```
647
+
648
+ Increase the concurrency (defaults to 100)
649
+
650
+ ```sh
651
+ yarn tr-request-approve --auth=$TRANSCEND_API_KEY --actions=ERASURE --concurrency=500
652
+ ```
653
+
597
654
  ### tr-request-upload
598
655
 
599
656
  If you need to upload a set of requests from a CSV, you can run this command.
@@ -625,7 +682,7 @@ The API key needs the following scopes:
625
682
 
626
683
  | Argument | Description | Type | Default | Required |
627
684
  | ----------------------- | ----------------------------------------------------------------------------------------------------------------------- | ------------------ | --------------------------------------- | -------- |
628
- | auth | The Transcend API capable of submitting privacy requests. | string | N/A | true |
685
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
629
686
  | file | Path to the CSV file of requests to tupload. | string - file-path | ./requests.csv | false |
630
687
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
631
688
  | cacheFilepath | The path to the JSON file encoding the metadata used to map the CSV shape to Transcend API. | string | ./transcend-privacy-requests-cache.json | false |
@@ -733,7 +790,7 @@ The API key needs the following scopes:
733
790
 
734
791
  | Argument | Description | Type | Default | Required |
735
792
  | -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | --------------- | --------------------------------- | -------- |
736
- | auth | The Transcend API capable of submitting privacy requests. | string | N/A | true |
793
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
737
794
  | actions | The [request action](https://docs.transcend.io/docs/privacy-requests/configuring-requests/data-subject-requests#data-actions) to restart. | RequestAction[] | N/A | true |
738
795
  | statuses | The [request statuses](https://docs.transcend.io/docs/privacy-requests/overview#request-statuses) to restart. | RequestStatus[] | N/A | true |
739
796
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -832,7 +889,7 @@ The API key needs the following scopes:
832
889
 
833
890
  | Argument | Description | Type | Default | Required |
834
891
  | --------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ------------------ | ------------------------------ | -------- |
835
- | auth | The Transcend API capable of pulling privacy requests. | string | N/A | true |
892
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
836
893
  | actions | The [request action](https://docs.transcend.io/docs/privacy-requests/configuring-requests/data-subject-requests#data-actions) to restart. | RequestAction[] | N/A | false |
837
894
  | statuses | The [request statuses](https://docs.transcend.io/docs/privacy-requests/overview#request-statuses) to restart. | RequestStatus[] | N/A | false |
838
895
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -905,7 +962,7 @@ The API key must be associated to the ID of the integration/data silo that is be
905
962
 
906
963
  | Argument | Description | Type | Default | Required |
907
964
  | ------------ | --------------------------------------------------------------------------------------------------------------------------------------- | ---------------------- | ------------------------ | -------- |
908
- | auth | The Transcend API capable of pulling the cron identifiers. | string | N/A | true |
965
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
909
966
  | dataSiloId | The ID of the data silo to pull in. | string - UUID | N/A | true |
910
967
  | requestType | The [request action](https://docs.transcend.io/docs/privacy-requests/configuring-requests/data-subject-requests#data-actions) to fetch. | string - RequestAction | N/A | true |
911
968
  | file | Path to the CSV file where identifiers will be written to. | string - file-path | ./cron-identifiers.csv | false |
@@ -970,7 +1027,7 @@ The API key must be associated to the ID of the integration/data silo that is be
970
1027
 
971
1028
  | Argument | Description | Type | Default | Required |
972
1029
  | ------------ | ------------------------------------------------------------------------------------ | ------------------ | ------------------------ | -------- |
973
- | auth | The Transcend API capable of pulling the cron identifiers. | string | N/A | true |
1030
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
974
1031
  | dataSiloId | The ID of the data silo to pull in. | string - UUID | N/A | true |
975
1032
  | file | Path to the CSV file where identifiers will be written to. | string - file-path | ./cron-identifiers.csv | false |
976
1033
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -1028,7 +1085,7 @@ The API key must have the following scopes:
1028
1085
 
1029
1086
  | Argument | Description | Type | Default | Required |
1030
1087
  | ------------ | ----------------------------------------------------------------------------- | ------------------ | ----------------------------------- | -------- |
1031
- | auth | The Transcend API capable of pull request information. | string | N/A | true |
1088
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1032
1089
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
1033
1090
  | file | Path to the CSV file where requests will be written to. | string - file-path | ./manual-enrichment-identifiers.csv | false |
1034
1091
  | actions | The set of request actions to pull requests for. | RequestAction[] | [] | false |
@@ -1088,7 +1145,7 @@ The API key must have the following scopes:
1088
1145
 
1089
1146
  | Argument | Description | Type | Default | Required |
1090
1147
  | ------------ | ------------------------------------------------------------------------------------ | ------------------ | ----------------------------------- | -------- |
1091
- | auth | The Transcend API capable of pull request information. | string | N/A | true |
1148
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1092
1149
  | enricherId | The ID of the Request Enricher to upload to | string - UUID | N/A | true |
1093
1150
  | sombraAuth | The sombra internal key, use for additional authentication when self-hosting sombra. | string | N/A | false |
1094
1151
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -1142,7 +1199,7 @@ The API key must have the following scopes:
1142
1199
 
1143
1200
  | Argument | Description | Type | Default | Required |
1144
1201
  | ------------ | ----------------------------------------------------------------------------- | ------------------ | ------------------------- | -------- |
1145
- | auth | The Transcend API capable of pulling the cron identifiers. | string | N/A | true |
1202
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1146
1203
  | dataSiloId | The ID of the data silo to pull in. | string - UUID | N/A | true |
1147
1204
  | file | Path to the CSV file where identifiers will be written to. | string - file-path | ./request-identifiers.csv | false |
1148
1205
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -1183,7 +1240,7 @@ The API key must have the following scopes:
1183
1240
 
1184
1241
  | Argument | Description | Type | Default | Required |
1185
1242
  | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------- | --------------- | ------------------------ | -------- |
1186
- | auth | The Transcend API capable of pulling the cron identifiers. | string | N/A | true |
1243
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1187
1244
  | dataSiloId | The ID of the data silo to pull in. | string - UUID | N/A | true |
1188
1245
  | actions | The [request action](https://docs.transcend.io/docs/privacy-requests/configuring-requests/data-subject-requests#data-actions) to restart. | RequestAction[] | N/A | true |
1189
1246
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
@@ -1217,9 +1274,9 @@ The API key must have the following scopes:
1217
1274
 
1218
1275
  | Argument | Description | Type | Default | Required |
1219
1276
  | ------------ | ----------------------------------------------------------------------------- | ------------ | ------------------------ | -------- |
1220
- | auth | The Transcend API capable of pulling the cron identifiers. | string | N/A | true |
1277
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1221
1278
  | bundleTypes | The bundle types to deploy | BundleType[] | PRODUCTION,TEST | false |
1222
- | deokiy | When true, deploy the Consent Manager after updating the version | boolean | false | false |
1279
+ | deploy | When true, deploy the Consent Manager after updating the version | boolean | false | false |
1223
1280
  | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
1224
1281
 
1225
1282
  #### Usage
@@ -1261,6 +1318,70 @@ tr-generate-api-keys --email=test@transcend.io --password=$TRANSCEND_PASSWORD -
1261
1318
  yarn tr-update-consent-manager --auth=./transcend-api-keys.json --deploy=true
1262
1319
  ```
1263
1320
 
1321
+ ### tr-upload-data-flows-from-csv
1322
+
1323
+ This command allows for uploading of data flows from CSV.
1324
+
1325
+ Step 1) Download the CSV of data flows that you want to edit from the Admin Dashboard under [Consent Manager -> Data Flows](https://app.transcend.io/consent-manager/data-flows). You can download data flows from both the "Triage" and "Approved" tabs.
1326
+
1327
+ <img width="1464" alt="Screenshot 2023-06-22 at 6 05 36 PM" src="https://github.com/transcend-io/cli/assets/10264973/c4b65b31-2cf3-49c9-b543-041567c7aff8">
1328
+
1329
+ Step 2) You can edit the contents of the CSV file as needed. You may adjust the "Purpose" column, adjust the "Notes" column, add "Owners" and "Teams" or even add custom columns with additional metadata.
1330
+
1331
+ Step 3) Upload the modified CSV file back into the dashboard with the command `yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --file=./approved-flows.csv --trackerStatus=LIVE`
1332
+
1333
+ #### Authentication
1334
+
1335
+ In order to use this cli, you will first need to generate an API key on the Transcend Admin Dashboard (https://app.transcend.io/infrastructure/api-keys).
1336
+
1337
+ The API key must have the following scopes:
1338
+
1339
+ - "Manage Data Flows"
1340
+
1341
+ #### Arguments
1342
+
1343
+ | Argument | Description | Type | Default | Required |
1344
+ | --------------- | ---------------------------------------------------------------------------------------------------------- | -------------------- | ------------------------ | -------- |
1345
+ | auth | The Transcend API key with the scopes necessary for the command. | string | N/A | true |
1346
+ | trackerStatus | Whether or not to upload the data flows into the "Approved" tab (LIVE) or the "Triage" tab (NEEDS_REVIEW). | ConsentTrackerStatus | N/A | true |
1347
+ | file | Path to the CSV file to upload | string - file-path | ./data-flows.csv | false |
1348
+ | classifyService | When true, automatically assign the service for a data flow based on the domain that is specified | boolean | false | false |
1349
+ | transcendUrl | URL of the Transcend backend. Use https://api.us.transcend.io for US hosting. | string - URL | https://api.transcend.io | false |
1350
+
1351
+ Note: You `trackerStatus` can be specified on a per data flow basis by adding a column named "Status" to the CSV. The values should be of type `ConsentTrackerStatus` - which is `LIVE` or `NEEDS_REVIEW`.
1352
+
1353
+ #### Usage
1354
+
1355
+ Upload the file of data flows in `./data-flows.csv` into the ["Approved" tab](https://app.transcend.io/consent-manager/data-flows/approved).
1356
+
1357
+ ```sh
1358
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --trackerStatus=LIVE
1359
+ ```
1360
+
1361
+ Upload the file of data flows in `./data-flows.csv` into the ["Triage" tab](https://app.transcend.io/consent-manager/data-flows).
1362
+
1363
+ ```sh
1364
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --trackerStatus=NEEDS_REVIEW
1365
+ ```
1366
+
1367
+ Specifying the CSV file to read from:
1368
+
1369
+ ```sh
1370
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --trackerStatus=LIVE --file=./custom/my-data-flows.csv
1371
+ ```
1372
+
1373
+ Have Transcend automatically fill in the service names by looking up the data flow host in Transcend's database.
1374
+
1375
+ ```sh
1376
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --trackerStatus=LIVE --classifyService=true
1377
+ ```
1378
+
1379
+ Specifying the backend URL, needed for US hosted backend infrastructure.
1380
+
1381
+ ```sh
1382
+ yarn tr-upload-data-flows-from-csv --auth=$TRANSCEND_API_KEY --transcendUrl=https://api.us.transcend.io
1383
+ ```
1384
+
1264
1385
  ### tr-generate-api-keys
1265
1386
 
1266
1387
  This command allows for creating API keys across multiple Transcend instances. This is useful for customers that are managing many Transcend instances and need to regularly create, cycle or delete API keys across all of their instances. Unlike the other commands that rely on API key authentication, this command relies upon username/password authentication. This command will spit out the API keys into a [JSON file](./examples/api-keys.json), and that JSON file can be used in subsequent cli commands.
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli-request-approve.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-request-approve.d.ts","sourceRoot":"","sources":["../src/cli-request-approve.ts"],"names":[],"mappings":""}
@@ -0,0 +1,56 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+ var __importDefault = (this && this.__importDefault) || function (mod) {
4
+ return (mod && mod.__esModule) ? mod : { "default": mod };
5
+ };
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const yargs_parser_1 = __importDefault(require("yargs-parser"));
8
+ const colors_1 = __importDefault(require("colors"));
9
+ const logger_1 = require("./logger");
10
+ const privacy_types_1 = require("@transcend-io/privacy-types");
11
+ const requests_1 = require("./requests");
12
+ /**
13
+ * Restart requests based on some filter criteria
14
+ *
15
+ * Requires scopes:
16
+ * - Request Approval and Communication
17
+ * - View Incoming Requests
18
+ * - Manage Request Compilation
19
+ *
20
+ * Dev Usage:
21
+ * yarn ts-node ./src/cli-request-approve.ts --auth=asd123 \
22
+ * --requestType=ERASURE --silentModeBefore=06/23/2023
23
+ *
24
+ * Standard usage:
25
+ * yarn tr-request-export --auth=asd123 \
26
+ * --requestType=ERASURE --silentModeBefore=06/23/2023
27
+ */
28
+ async function main() {
29
+ // Parse command line arguments
30
+ const { transcendUrl = 'https://api.transcend.io', auth, actions = '', silentModeBefore, concurrency = '100', } = (0, yargs_parser_1.default)(process.argv.slice(2));
31
+ // Ensure auth is passed
32
+ if (!auth) {
33
+ logger_1.logger.error(colors_1.default.red('A Transcend API key must be provided. You can specify using --auth=asd123'));
34
+ process.exit(1);
35
+ }
36
+ // Validate actions
37
+ const parsedActions = (0, requests_1.splitCsvToList)(actions);
38
+ const invalidActions = parsedActions.filter(
39
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
40
+ (type) => !Object.values(privacy_types_1.RequestAction).includes(type));
41
+ if (invalidActions.length > 0) {
42
+ logger_1.logger.error(colors_1.default.red(`Failed to parse actions:"${invalidActions.join(',')}".\n` +
43
+ `Expected one of: \n${Object.values(privacy_types_1.RequestAction).join('\n')}`));
44
+ process.exit(1);
45
+ }
46
+ // Pull privacy requests
47
+ await (0, requests_1.approvePrivacyRequests)({
48
+ transcendUrl,
49
+ requestActions: parsedActions,
50
+ auth,
51
+ concurrency: parseInt(concurrency, 10),
52
+ silentModeBefore: silentModeBefore ? new Date(silentModeBefore) : undefined,
53
+ });
54
+ }
55
+ main();
56
+ //# sourceMappingURL=cli-request-approve.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-request-approve.js","sourceRoot":"","sources":["../src/cli-request-approve.ts"],"names":[],"mappings":";;;;;;AAEA,gEAAiC;AACjC,oDAA4B;AAE5B,qCAAkC;AAClC,+DAA4D;AAC5D,yCAAoE;AAEpE;;;;;;;;;;;;;;;GAeG;AACH,KAAK,UAAU,IAAI;IACjB,+BAA+B;IAC/B,MAAM,EACJ,YAAY,GAAG,0BAA0B,EACzC,IAAI,EACJ,OAAO,GAAG,EAAE,EACZ,gBAAgB,EAChB,WAAW,GAAG,KAAK,GACpB,GAAG,IAAA,sBAAK,EAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAA8B,CAAC;IAE9D,wBAAwB;IACxB,IAAI,CAAC,IAAI,EAAE;QACT,eAAM,CAAC,KAAK,CACV,gBAAM,CAAC,GAAG,CACR,2EAA2E,CAC5E,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IAED,mBAAmB;IACnB,MAAM,aAAa,GAAG,IAAA,yBAAc,EAAC,OAAO,CAAoB,CAAC;IACjE,MAAM,cAAc,GAAG,aAAa,CAAC,MAAM;IACzC,8DAA8D;IAC9D,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,6BAAa,CAAC,CAAC,QAAQ,CAAC,IAAW,CAAC,CAC9D,CAAC;IACF,IAAI,cAAc,CAAC,MAAM,GAAG,CAAC,EAAE;QAC7B,eAAM,CAAC,KAAK,CACV,gBAAM,CAAC,GAAG,CACR,4BAA4B,cAAc,CAAC,IAAI,CAAC,GAAG,CAAC,MAAM;YACxD,sBAAsB,MAAM,CAAC,MAAM,CAAC,6BAAa,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAClE,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IAED,wBAAwB;IACxB,MAAM,IAAA,iCAAsB,EAAC;QAC3B,YAAY;QACZ,cAAc,EAAE,aAAa;QAC7B,IAAI;QACJ,WAAW,EAAE,QAAQ,CAAC,WAAW,EAAE,EAAE,CAAC;QACtC,gBAAgB,EAAE,gBAAgB,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,SAAS;KAC5E,CAAC,CAAC;AACL,CAAC;AAED,IAAI,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli-upload-data-flows-from-csv.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-upload-data-flows-from-csv.d.ts","sourceRoot":"","sources":["../src/cli-upload-data-flows-from-csv.ts"],"names":[],"mappings":""}
@@ -0,0 +1,59 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+ var __importDefault = (this && this.__importDefault) || function (mod) {
4
+ return (mod && mod.__esModule) ? mod : { "default": mod };
5
+ };
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const yargs_parser_1 = __importDefault(require("yargs-parser"));
8
+ const colors_1 = __importDefault(require("colors"));
9
+ const logger_1 = require("./logger");
10
+ const consent_manager_1 = require("./consent-manager");
11
+ const privacy_types_1 = require("@transcend-io/privacy-types");
12
+ /**
13
+ * Upload a CSV of data flows
14
+ *
15
+ * Requires an API key with follow scopes: https://app.transcend.io/infrastructure/api-keys
16
+ * - "Manage Data Flows"
17
+ *
18
+ * Dev Usage:
19
+ * yarn ts-node ./src/cli-upload-data-flows-from-csv.ts --auth=asd123 \
20
+ * --file=/Users/michaelfarrell/Desktop/test.csv \
21
+ * --trackerStatus=LIVE
22
+ *
23
+ * Standard usage:
24
+ * yarn tr-upload-data-flows-from-csv --auth=asd123 \
25
+ * --file=/Users/michaelfarrell/Desktop/test.csv \
26
+ * --trackerStatus=LIVE
27
+ */
28
+ async function main() {
29
+ // Parse command line arguments
30
+ const { auth, trackerStatus, classifyService = 'false', file = './data-flows.csv', transcendUrl = 'https://api.transcend.io', } = (0, yargs_parser_1.default)(process.argv.slice(2));
31
+ // Ensure auth is passed
32
+ if (!auth) {
33
+ logger_1.logger.error(colors_1.default.red('A Transcend API key must be provided. You can specify using --auth=asd123'));
34
+ process.exit(1);
35
+ }
36
+ // Ensure trackerStatus is passed
37
+ const VALID_TRACKER_OPTIONS = Object.values(privacy_types_1.ConsentTrackerStatus);
38
+ if (!trackerStatus) {
39
+ logger_1.logger.error(colors_1.default.red('The trackerStatus must be provided. You can specify using --trackerStatus=LIVE. ' +
40
+ `Valid options include: ${VALID_TRACKER_OPTIONS.join(',')}`));
41
+ process.exit(1);
42
+ }
43
+ const consentTrackerStatus = trackerStatus;
44
+ if (!VALID_TRACKER_OPTIONS.includes(consentTrackerStatus)) {
45
+ logger_1.logger.error(colors_1.default.red(`The trackerStatus option was invalid, got: "${trackerStatus}". You can specify using --trackerStatus=LIVE. ` +
46
+ `Valid options include: ${VALID_TRACKER_OPTIONS.join(',')}`));
47
+ process.exit(1);
48
+ }
49
+ // Upload data flows
50
+ await (0, consent_manager_1.uploadDataFlowsFromCsv)({
51
+ auth,
52
+ trackerStatus: consentTrackerStatus,
53
+ file,
54
+ classifyService: classifyService === 'true',
55
+ transcendUrl,
56
+ });
57
+ }
58
+ main();
59
+ //# sourceMappingURL=cli-upload-data-flows-from-csv.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli-upload-data-flows-from-csv.js","sourceRoot":"","sources":["../src/cli-upload-data-flows-from-csv.ts"],"names":[],"mappings":";;;;;;AAEA,gEAAiC;AACjC,oDAA4B;AAE5B,qCAAkC;AAClC,uDAA2D;AAC3D,+DAAmE;AAEnE;;;;;;;;;;;;;;;GAeG;AACH,KAAK,UAAU,IAAI;IACjB,+BAA+B;IAC/B,MAAM,EACJ,IAAI,EACJ,aAAa,EACb,eAAe,GAAG,OAAO,EACzB,IAAI,GAAG,kBAAkB,EACzB,YAAY,GAAG,0BAA0B,GAC1C,GAAG,IAAA,sBAAK,EAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAA8B,CAAC;IAE9D,wBAAwB;IACxB,IAAI,CAAC,IAAI,EAAE;QACT,eAAM,CAAC,KAAK,CACV,gBAAM,CAAC,GAAG,CACR,2EAA2E,CAC5E,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IAED,iCAAiC;IACjC,MAAM,qBAAqB,GAAG,MAAM,CAAC,MAAM,CAAC,oCAAoB,CAAC,CAAC;IAClE,IAAI,CAAC,aAAa,EAAE;QAClB,eAAM,CAAC,KAAK,CACV,gBAAM,CAAC,GAAG,CACR,kFAAkF;YAChF,0BAA0B,qBAAqB,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAC9D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IAED,MAAM,oBAAoB,GAAG,aAAqC,CAAC;IACnE,IAAI,CAAC,qBAAqB,CAAC,QAAQ,CAAC,oBAAoB,CAAC,EAAE;QACzD,eAAM,CAAC,KAAK,CACV,gBAAM,CAAC,GAAG,CACR,+CAA+C,aAAa,iDAAiD;YAC3G,0BAA0B,qBAAqB,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAC9D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IAED,oBAAoB;IACpB,MAAM,IAAA,wCAAsB,EAAC;QAC3B,IAAI;QACJ,aAAa,EAAE,oBAAoB;QACnC,IAAI;QACJ,eAAe,EAAE,eAAe,KAAK,MAAM;QAC3C,YAAY;KACb,CAAC,CAAC;AACL,CAAC;AAED,IAAI,EAAE,CAAC"}
@@ -1,2 +1,3 @@
1
1
  export * from './updateConsentManagerVersionToLatest';
2
+ export * from './uploadDataFlowsFromCsv';
2
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/consent-manager/index.ts"],"names":[],"mappings":"AAAA,cAAc,uCAAuC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/consent-manager/index.ts"],"names":[],"mappings":"AAAA,cAAc,uCAAuC,CAAC;AACtD,cAAc,0BAA0B,CAAC"}
@@ -15,4 +15,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./updateConsentManagerVersionToLatest"), exports);
18
+ __exportStar(require("./uploadDataFlowsFromCsv"), exports);
18
19
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/consent-manager/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,wEAAsD"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/consent-manager/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,wEAAsD;AACtD,2DAAyC"}
@@ -0,0 +1,53 @@
1
+ import * as t from 'io-ts';
2
+ import { ConsentTrackerStatus } from '@transcend-io/privacy-types';
3
+ /**
4
+ * Minimal set required to mark as completed
5
+ */
6
+ export declare const DataFlowCsvInput: t.IntersectionC<[t.TypeC<{
7
+ /** The value of the data flow (host or regex) */
8
+ 'Connections Made To': t.StringC;
9
+ /** The type of the data flow */
10
+ Type: t.KeyofC<{
11
+ HOST: unknown;
12
+ PATH: unknown;
13
+ QUERY_PARAM: unknown;
14
+ REGEX: unknown;
15
+ CSP: unknown;
16
+ }>;
17
+ /** The CSV of purposes mapped to that data flow */
18
+ Purpose: t.StringC;
19
+ }>, t.PartialC<{
20
+ /** The service that the data flow relates to */
21
+ Service: t.StringC;
22
+ /** Notes and descriptions for the data flow */
23
+ Notes: t.StringC;
24
+ /** Set of data flow owners */
25
+ Owners: t.StringC;
26
+ /** Set of data flow team owners */
27
+ Teams: t.StringC;
28
+ /** LIVE vs NEEDS_REVIEW aka Approved vs Triage */
29
+ Status: t.KeyofC<{
30
+ LIVE: unknown;
31
+ NEEDS_REVIEW: unknown;
32
+ }>;
33
+ }>, t.RecordC<t.StringC, t.StringC>]>;
34
+ /** Type override */
35
+ export type DataFlowCsvInput = t.TypeOf<typeof DataFlowCsvInput>;
36
+ /**
37
+ * Upload a set of data flows from CSV
38
+ *
39
+ * @param options - Options
40
+ */
41
+ export declare function uploadDataFlowsFromCsv({ auth, trackerStatus, file, classifyService, transcendUrl, }: {
42
+ /** CSV file path */
43
+ file: string;
44
+ /** Transcend API key authentication */
45
+ auth: string;
46
+ /** Sombra API key authentication */
47
+ trackerStatus: ConsentTrackerStatus;
48
+ /** classify data flow service if missing */
49
+ classifyService?: boolean;
50
+ /** API URL for Transcend backend */
51
+ transcendUrl?: string;
52
+ }): Promise<void>;
53
+ //# sourceMappingURL=uploadDataFlowsFromCsv.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"uploadDataFlowsFromCsv.d.ts","sourceRoot":"","sources":["../../src/consent-manager/uploadDataFlowsFromCsv.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,OAAO,CAAC;AAE3B,OAAO,EACL,oBAAoB,EAErB,MAAM,6BAA6B,CAAC;AAOrC;;GAEG;AACH,eAAO,MAAM,gBAAgB;IAEzB,iDAAiD;;IAEjD,gCAAgC;;;;;;;;IAEhC,mDAAmD;;;IAInD,gDAAgD;;IAEhD,+CAA+C;;IAE/C,8BAA8B;;IAE9B,mCAAmC;;IAEnC,mDAAmD;;;;;qCAKrD,CAAC;AAcH,oBAAoB;AACpB,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEjE;;;;GAIG;AACH,wBAAsB,sBAAsB,CAAC,EAC3C,IAAI,EACJ,aAAa,EACb,IAAI,EACJ,eAAuB,EACvB,YAAyC,GAC1C,EAAE;IACD,oBAAoB;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,uCAAuC;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,oCAAoC;IACpC,aAAa,EAAE,oBAAoB,CAAC;IACpC,4CAA4C;IAC5C,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,oCAAoC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,GAAG,OAAO,CAAC,IAAI,CAAC,CA8DhB"}