@pnp/cli-microsoft365 6.0.0-beta.e9e0f02 → 6.0.0-beta.ed1cc4a
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/Auth.js +1 -2
- package/dist/m365/booking/commands/business/business-get.js +86 -0
- package/dist/m365/booking/commands/business/business-list.js +30 -0
- package/dist/m365/booking/commands.js +8 -0
- package/dist/m365/cli/commands/config/config-set.js +0 -1
- package/dist/m365/search/commands/externalconnection/externalconnection-remove.js +101 -0
- package/dist/m365/search/commands.js +2 -1
- package/dist/m365/teams/commands/team/team-remove.js +5 -8
- package/dist/m365/teams/commands/team/team-unarchive.js +4 -7
- package/dist/settingsNames.js +0 -1
- package/docs/docs/cmd/aad/app/app-add.md +1 -1
- package/docs/docs/cmd/aad/app/app-set.md +1 -1
- package/docs/docs/cmd/booking/business/business-get.md +33 -0
- package/docs/docs/cmd/booking/business/business-list.md +21 -0
- package/docs/docs/cmd/cli/completion/completion-clink-update.md +1 -1
- package/docs/docs/cmd/cli/completion/completion-pwsh-setup.md +1 -1
- package/docs/docs/cmd/cli/completion/completion-pwsh-update.md +1 -1
- package/docs/docs/cmd/cli/completion/completion-sh-setup.md +1 -1
- package/docs/docs/cmd/cli/completion/completion-sh-update.md +1 -1
- package/docs/docs/cmd/search/externalconnection/externalconnection-remove.md +40 -0
- package/npm-shrinkwrap.json +200 -161
- package/package.json +10 -10
package/dist/Auth.js
CHANGED
|
@@ -301,8 +301,7 @@ class Auth {
|
|
|
301
301
|
logger.logToStderr('');
|
|
302
302
|
}
|
|
303
303
|
logger.log(response.message);
|
|
304
|
-
if (cli_1.Cli.getInstance().getSettingWithDefaultValue(settingsNames_1.settingsNames.
|
|
305
|
-
|| cli_1.Cli.getInstance().getSettingWithDefaultValue(settingsNames_1.settingsNames.autoOpenLinksInBrowser, false)) {
|
|
304
|
+
if (cli_1.Cli.getInstance().getSettingWithDefaultValue(settingsNames_1.settingsNames.autoOpenLinksInBrowser, false)) {
|
|
306
305
|
// _open is never set before hitting this line, but this check
|
|
307
306
|
// is implemented so that we can support lazy loading
|
|
308
307
|
// but also stub it for testing
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
3
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
4
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
5
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
6
|
+
};
|
|
7
|
+
var _BookingBusinessGetCommand_instances, _BookingBusinessGetCommand_initTelemetry, _BookingBusinessGetCommand_initOptions, _BookingBusinessGetCommand_initOptionSets;
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
const request_1 = require("../../../../request");
|
|
10
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
11
|
+
const commands_1 = require("../../commands");
|
|
12
|
+
class BookingBusinessGetCommand extends GraphCommand_1.default {
|
|
13
|
+
constructor() {
|
|
14
|
+
super();
|
|
15
|
+
_BookingBusinessGetCommand_instances.add(this);
|
|
16
|
+
__classPrivateFieldGet(this, _BookingBusinessGetCommand_instances, "m", _BookingBusinessGetCommand_initTelemetry).call(this);
|
|
17
|
+
__classPrivateFieldGet(this, _BookingBusinessGetCommand_instances, "m", _BookingBusinessGetCommand_initOptions).call(this);
|
|
18
|
+
__classPrivateFieldGet(this, _BookingBusinessGetCommand_instances, "m", _BookingBusinessGetCommand_initOptionSets).call(this);
|
|
19
|
+
}
|
|
20
|
+
get name() {
|
|
21
|
+
return commands_1.default.BUSINESS_GET;
|
|
22
|
+
}
|
|
23
|
+
get description() {
|
|
24
|
+
return 'Retrieve the specified Microsoft Bookings business.';
|
|
25
|
+
}
|
|
26
|
+
defaultProperties() {
|
|
27
|
+
return ['id', 'displayName', 'businessType', 'phone', 'email', 'defaultCurrencyIso'];
|
|
28
|
+
}
|
|
29
|
+
commandAction(logger, args, cb) {
|
|
30
|
+
this
|
|
31
|
+
.getBusinessId(args.options)
|
|
32
|
+
.then(businessId => {
|
|
33
|
+
const requestOptions = {
|
|
34
|
+
url: `${this.resource}/v1.0/solutions/bookingBusinesses/${encodeURIComponent(businessId)}`,
|
|
35
|
+
headers: {
|
|
36
|
+
accept: 'application/json;odata.metadata=none'
|
|
37
|
+
},
|
|
38
|
+
responseType: 'json'
|
|
39
|
+
};
|
|
40
|
+
return request_1.default.get(requestOptions);
|
|
41
|
+
})
|
|
42
|
+
.then(business => {
|
|
43
|
+
logger.log(business);
|
|
44
|
+
cb();
|
|
45
|
+
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
46
|
+
}
|
|
47
|
+
getBusinessId(options) {
|
|
48
|
+
if (options.id) {
|
|
49
|
+
return Promise.resolve(options.id);
|
|
50
|
+
}
|
|
51
|
+
const requestOptions = {
|
|
52
|
+
url: `${this.resource}/v1.0/solutions/bookingBusinesses`,
|
|
53
|
+
headers: {
|
|
54
|
+
accept: 'application/json;odata.metadata=none'
|
|
55
|
+
},
|
|
56
|
+
responseType: 'json'
|
|
57
|
+
};
|
|
58
|
+
return request_1.default
|
|
59
|
+
.get(requestOptions)
|
|
60
|
+
.then((response) => {
|
|
61
|
+
const name = options.name;
|
|
62
|
+
const bookingBusinesses = response.value.filter(val => { var _a; return ((_a = val.displayName) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase()) === name.toLocaleLowerCase(); });
|
|
63
|
+
if (!bookingBusinesses.length) {
|
|
64
|
+
return Promise.reject(`The specified business with name ${options.name} does not exist.`);
|
|
65
|
+
}
|
|
66
|
+
if (bookingBusinesses.length > 1) {
|
|
67
|
+
return Promise.reject(`Multiple businesses with name ${options.name} found. Please disambiguate: ${bookingBusinesses.map(x => x.id).join(', ')}`);
|
|
68
|
+
}
|
|
69
|
+
return bookingBusinesses[0].id;
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
_BookingBusinessGetCommand_instances = new WeakSet(), _BookingBusinessGetCommand_initTelemetry = function _BookingBusinessGetCommand_initTelemetry() {
|
|
74
|
+
this.telemetry.push((args) => {
|
|
75
|
+
Object.assign(this.telemetryProperties, {
|
|
76
|
+
id: typeof args.options.id !== 'undefined',
|
|
77
|
+
name: typeof args.options.name !== 'undefined'
|
|
78
|
+
});
|
|
79
|
+
});
|
|
80
|
+
}, _BookingBusinessGetCommand_initOptions = function _BookingBusinessGetCommand_initOptions() {
|
|
81
|
+
this.options.unshift({ option: '-i, --id [id]' }, { option: '-n, --name [name]' });
|
|
82
|
+
}, _BookingBusinessGetCommand_initOptionSets = function _BookingBusinessGetCommand_initOptionSets() {
|
|
83
|
+
this.optionSets.push(['id', 'name']);
|
|
84
|
+
};
|
|
85
|
+
module.exports = new BookingBusinessGetCommand();
|
|
86
|
+
//# sourceMappingURL=business-get.js.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const utils_1 = require("../../../../utils");
|
|
4
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
5
|
+
const commands_1 = require("../../commands");
|
|
6
|
+
class BookingBusinessListCommand extends GraphCommand_1.default {
|
|
7
|
+
get name() {
|
|
8
|
+
return commands_1.default.BUSINESS_LIST;
|
|
9
|
+
}
|
|
10
|
+
get description() {
|
|
11
|
+
return 'Lists all Microsoft Bookings businesses that are created for the tenant.';
|
|
12
|
+
}
|
|
13
|
+
defaultProperties() {
|
|
14
|
+
return ['id', 'displayName'];
|
|
15
|
+
}
|
|
16
|
+
commandAction(logger, args, cb) {
|
|
17
|
+
const endpoint = `${this.resource}/v1.0/solutions/bookingBusinesses`;
|
|
18
|
+
utils_1.odata
|
|
19
|
+
.getAllItems(endpoint)
|
|
20
|
+
.then((items) => {
|
|
21
|
+
return Promise.resolve(items);
|
|
22
|
+
})
|
|
23
|
+
.then((items) => {
|
|
24
|
+
logger.log(items);
|
|
25
|
+
cb();
|
|
26
|
+
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
module.exports = new BookingBusinessListCommand();
|
|
30
|
+
//# sourceMappingURL=business-list.js.map
|
|
@@ -36,7 +36,6 @@ class CliConfigSetCommand extends AnonymousCommand_1.default {
|
|
|
36
36
|
commandAction(logger, args, cb) {
|
|
37
37
|
let value = undefined;
|
|
38
38
|
switch (args.options.key) {
|
|
39
|
-
case settingsNames_1.settingsNames.autoOpenBrowserOnLogin:
|
|
40
39
|
case settingsNames_1.settingsNames.autoOpenLinksInBrowser:
|
|
41
40
|
case settingsNames_1.settingsNames.copyDeviceCodeToClipboard:
|
|
42
41
|
case settingsNames_1.settingsNames.csvHeader:
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
3
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
4
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
5
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
6
|
+
};
|
|
7
|
+
var _SearchExternalConnectionRemoveCommand_instances, _SearchExternalConnectionRemoveCommand_initTelemetry, _SearchExternalConnectionRemoveCommand_initOptions, _SearchExternalConnectionRemoveCommand_initOptionSets;
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
const cli_1 = require("../../../../cli");
|
|
10
|
+
const request_1 = require("../../../../request");
|
|
11
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
12
|
+
const commands_1 = require("../../commands");
|
|
13
|
+
class SearchExternalConnectionRemoveCommand extends GraphCommand_1.default {
|
|
14
|
+
constructor() {
|
|
15
|
+
super();
|
|
16
|
+
_SearchExternalConnectionRemoveCommand_instances.add(this);
|
|
17
|
+
__classPrivateFieldGet(this, _SearchExternalConnectionRemoveCommand_instances, "m", _SearchExternalConnectionRemoveCommand_initTelemetry).call(this);
|
|
18
|
+
__classPrivateFieldGet(this, _SearchExternalConnectionRemoveCommand_instances, "m", _SearchExternalConnectionRemoveCommand_initOptions).call(this);
|
|
19
|
+
__classPrivateFieldGet(this, _SearchExternalConnectionRemoveCommand_instances, "m", _SearchExternalConnectionRemoveCommand_initOptionSets).call(this);
|
|
20
|
+
}
|
|
21
|
+
get name() {
|
|
22
|
+
return commands_1.default.EXTERNALCONNECTION_REMOVE;
|
|
23
|
+
}
|
|
24
|
+
get description() {
|
|
25
|
+
return 'Removes a specific External Connection from Microsoft Search';
|
|
26
|
+
}
|
|
27
|
+
getExternalConnectionId(args) {
|
|
28
|
+
if (args.options.id) {
|
|
29
|
+
return Promise.resolve(args.options.id);
|
|
30
|
+
}
|
|
31
|
+
const requestOptions = {
|
|
32
|
+
url: `${this.resource}/v1.0/external/connections?$filter=name eq '${encodeURIComponent(args.options.name)}'&$select=id`,
|
|
33
|
+
headers: {
|
|
34
|
+
accept: 'application/json;odata.metadata=none'
|
|
35
|
+
},
|
|
36
|
+
responseType: 'json'
|
|
37
|
+
};
|
|
38
|
+
return request_1.default
|
|
39
|
+
.get(requestOptions)
|
|
40
|
+
.then((res) => {
|
|
41
|
+
if (res.value.length === 1) {
|
|
42
|
+
return Promise.resolve(res.value[0].id);
|
|
43
|
+
}
|
|
44
|
+
if (res.value.length === 0) {
|
|
45
|
+
return Promise.reject(`The specified connection does not exist in Microsoft Search`);
|
|
46
|
+
}
|
|
47
|
+
return Promise.reject(`Multiple external connections with name ${args.options.name} found. Please disambiguate (IDs): ${res.value.map(x => x.id).join(', ')}`);
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
commandAction(logger, args, cb) {
|
|
51
|
+
const removeExternalConnection = () => {
|
|
52
|
+
this
|
|
53
|
+
.getExternalConnectionId(args)
|
|
54
|
+
.then((externalConnectionId) => {
|
|
55
|
+
const requestOptions = {
|
|
56
|
+
url: `${this.resource}/v1.0/external/connections/${encodeURIComponent(externalConnectionId)}`,
|
|
57
|
+
headers: {
|
|
58
|
+
accept: 'application/json;odata.metadata=none'
|
|
59
|
+
},
|
|
60
|
+
responseType: 'json'
|
|
61
|
+
};
|
|
62
|
+
return request_1.default
|
|
63
|
+
.delete(requestOptions);
|
|
64
|
+
})
|
|
65
|
+
.then(_ => cb(), (rawRes) => this.handleRejectedODataJsonPromise(rawRes, logger, cb));
|
|
66
|
+
};
|
|
67
|
+
if (args.options.confirm) {
|
|
68
|
+
removeExternalConnection();
|
|
69
|
+
}
|
|
70
|
+
else {
|
|
71
|
+
cli_1.Cli.prompt({
|
|
72
|
+
type: 'confirm',
|
|
73
|
+
name: 'continue',
|
|
74
|
+
default: false,
|
|
75
|
+
message: `Are you sure you want to remove the external connection '${args.options.id || args.options.name}'?`
|
|
76
|
+
}, (result) => {
|
|
77
|
+
if (!result.continue) {
|
|
78
|
+
cb();
|
|
79
|
+
}
|
|
80
|
+
else {
|
|
81
|
+
removeExternalConnection();
|
|
82
|
+
}
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
_SearchExternalConnectionRemoveCommand_instances = new WeakSet(), _SearchExternalConnectionRemoveCommand_initTelemetry = function _SearchExternalConnectionRemoveCommand_initTelemetry() {
|
|
88
|
+
this.telemetry.push((args) => {
|
|
89
|
+
Object.assign(this.telemetryProperties, {
|
|
90
|
+
id: typeof args.options.id !== 'undefined',
|
|
91
|
+
name: typeof args.options.name !== 'undefined',
|
|
92
|
+
confirm: (!(!args.options.confirm)).toString()
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
}, _SearchExternalConnectionRemoveCommand_initOptions = function _SearchExternalConnectionRemoveCommand_initOptions() {
|
|
96
|
+
this.options.unshift({ option: '--id [id]' }, { option: '--name [name]' }, { option: '--confirm' });
|
|
97
|
+
}, _SearchExternalConnectionRemoveCommand_initOptionSets = function _SearchExternalConnectionRemoveCommand_initOptionSets() {
|
|
98
|
+
this.optionSets.push(['id', 'name']);
|
|
99
|
+
};
|
|
100
|
+
module.exports = new SearchExternalConnectionRemoveCommand();
|
|
101
|
+
//# sourceMappingURL=externalconnection-remove.js.map
|
|
@@ -4,6 +4,7 @@ const prefix = 'search';
|
|
|
4
4
|
exports.default = {
|
|
5
5
|
EXTERNALCONNECTION_ADD: `${prefix} externalconnection add`,
|
|
6
6
|
EXTERNALCONNECTION_GET: `${prefix} externalconnection get`,
|
|
7
|
-
EXTERNALCONNECTION_LIST: `${prefix} externalconnection list
|
|
7
|
+
EXTERNALCONNECTION_LIST: `${prefix} externalconnection list`,
|
|
8
|
+
EXTERNALCONNECTION_REMOVE: `${prefix} externalconnection remove`
|
|
8
9
|
};
|
|
9
10
|
//# sourceMappingURL=commands.js.map
|
|
@@ -13,7 +13,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
13
13
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
14
14
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
15
15
|
};
|
|
16
|
-
var _TeamsTeamRemoveCommand_instances, _TeamsTeamRemoveCommand_initTelemetry, _TeamsTeamRemoveCommand_initOptions, _TeamsTeamRemoveCommand_initValidators;
|
|
16
|
+
var _TeamsTeamRemoveCommand_instances, _TeamsTeamRemoveCommand_initTelemetry, _TeamsTeamRemoveCommand_initOptions, _TeamsTeamRemoveCommand_initOptionSets, _TeamsTeamRemoveCommand_initValidators;
|
|
17
17
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
18
|
const cli_1 = require("../../../../cli");
|
|
19
19
|
const request_1 = require("../../../../request");
|
|
@@ -28,6 +28,7 @@ class TeamsTeamRemoveCommand extends GraphCommand_1.default {
|
|
|
28
28
|
__classPrivateFieldGet(this, _TeamsTeamRemoveCommand_instances, "m", _TeamsTeamRemoveCommand_initTelemetry).call(this);
|
|
29
29
|
__classPrivateFieldGet(this, _TeamsTeamRemoveCommand_instances, "m", _TeamsTeamRemoveCommand_initOptions).call(this);
|
|
30
30
|
__classPrivateFieldGet(this, _TeamsTeamRemoveCommand_instances, "m", _TeamsTeamRemoveCommand_initValidators).call(this);
|
|
31
|
+
__classPrivateFieldGet(this, _TeamsTeamRemoveCommand_instances, "m", _TeamsTeamRemoveCommand_initOptionSets).call(this);
|
|
31
32
|
}
|
|
32
33
|
get name() {
|
|
33
34
|
return commands_1.default.TEAM_REMOVE;
|
|
@@ -72,7 +73,7 @@ class TeamsTeamRemoveCommand extends GraphCommand_1.default {
|
|
|
72
73
|
type: 'confirm',
|
|
73
74
|
name: 'continue',
|
|
74
75
|
default: false,
|
|
75
|
-
message: `Are you sure you want to remove the team ${args.options.
|
|
76
|
+
message: `Are you sure you want to remove the team ${args.options.id ? args.options.id : args.options.name}?`
|
|
76
77
|
}, (result) => {
|
|
77
78
|
if (!result.continue) {
|
|
78
79
|
cb();
|
|
@@ -98,14 +99,10 @@ _TeamsTeamRemoveCommand_instances = new WeakSet(), _TeamsTeamRemoveCommand_initT
|
|
|
98
99
|
}, {
|
|
99
100
|
option: '--confirm'
|
|
100
101
|
});
|
|
102
|
+
}, _TeamsTeamRemoveCommand_initOptionSets = function _TeamsTeamRemoveCommand_initOptionSets() {
|
|
103
|
+
this.optionSets.push(['id', 'name']);
|
|
101
104
|
}, _TeamsTeamRemoveCommand_initValidators = function _TeamsTeamRemoveCommand_initValidators() {
|
|
102
105
|
this.validators.push((args) => __awaiter(this, void 0, void 0, function* () {
|
|
103
|
-
if (!args.options.id && !args.options.name) {
|
|
104
|
-
return 'Specify either id or name';
|
|
105
|
-
}
|
|
106
|
-
if (args.options.name && args.options.id) {
|
|
107
|
-
return 'Specify either id or name but not both';
|
|
108
|
-
}
|
|
109
106
|
if (args.options.id && !utils_1.validation.isValidGuid(args.options.id)) {
|
|
110
107
|
return `${args.options.id} is not a valid GUID`;
|
|
111
108
|
}
|
|
@@ -13,7 +13,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
13
13
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
14
14
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
15
15
|
};
|
|
16
|
-
var _TeamsTeamUnarchiveCommand_instances, _TeamsTeamUnarchiveCommand_initOptions, _TeamsTeamUnarchiveCommand_initValidators;
|
|
16
|
+
var _TeamsTeamUnarchiveCommand_instances, _TeamsTeamUnarchiveCommand_initOptions, _TeamsTeamUnarchiveCommand_initOptionSets, _TeamsTeamUnarchiveCommand_initValidators;
|
|
17
17
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
18
|
const request_1 = require("../../../../request");
|
|
19
19
|
const utils_1 = require("../../../../utils");
|
|
@@ -26,6 +26,7 @@ class TeamsTeamUnarchiveCommand extends GraphCommand_1.default {
|
|
|
26
26
|
_TeamsTeamUnarchiveCommand_instances.add(this);
|
|
27
27
|
__classPrivateFieldGet(this, _TeamsTeamUnarchiveCommand_instances, "m", _TeamsTeamUnarchiveCommand_initOptions).call(this);
|
|
28
28
|
__classPrivateFieldGet(this, _TeamsTeamUnarchiveCommand_instances, "m", _TeamsTeamUnarchiveCommand_initValidators).call(this);
|
|
29
|
+
__classPrivateFieldGet(this, _TeamsTeamUnarchiveCommand_instances, "m", _TeamsTeamUnarchiveCommand_initOptionSets).call(this);
|
|
29
30
|
}
|
|
30
31
|
get name() {
|
|
31
32
|
return commands_1.default.TEAM_UNARCHIVE;
|
|
@@ -70,14 +71,10 @@ _TeamsTeamUnarchiveCommand_instances = new WeakSet(), _TeamsTeamUnarchiveCommand
|
|
|
70
71
|
}, {
|
|
71
72
|
option: '-n, --name [name]'
|
|
72
73
|
});
|
|
74
|
+
}, _TeamsTeamUnarchiveCommand_initOptionSets = function _TeamsTeamUnarchiveCommand_initOptionSets() {
|
|
75
|
+
this.optionSets.push(['id', 'name']);
|
|
73
76
|
}, _TeamsTeamUnarchiveCommand_initValidators = function _TeamsTeamUnarchiveCommand_initValidators() {
|
|
74
77
|
this.validators.push((args) => __awaiter(this, void 0, void 0, function* () {
|
|
75
|
-
if (!args.options.id && !args.options.name) {
|
|
76
|
-
return 'Specify either id or name';
|
|
77
|
-
}
|
|
78
|
-
if (args.options.name && args.options.id) {
|
|
79
|
-
return 'Specify either id or name but not both';
|
|
80
|
-
}
|
|
81
78
|
if (args.options.id && !utils_1.validation.isValidGuid(args.options.id)) {
|
|
82
79
|
return `${args.options.id} is not a valid GUID`;
|
|
83
80
|
}
|
package/dist/settingsNames.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.settingsNames = void 0;
|
|
4
4
|
const settingsNames = {
|
|
5
|
-
autoOpenBrowserOnLogin: 'autoOpenBrowserOnLogin',
|
|
6
5
|
autoOpenLinksInBrowser: 'autoOpenLinksInBrowser',
|
|
7
6
|
copyDeviceCodeToClipboard: 'copyDeviceCodeToClipboard',
|
|
8
7
|
csvEscape: 'csvEscape',
|
|
@@ -176,5 +176,5 @@ m365 aad app add --name 'My AAD app' --save
|
|
|
176
176
|
Create new Azure AD app registration with a certificate
|
|
177
177
|
|
|
178
178
|
```sh
|
|
179
|
-
m365 aad app add --name 'My AAD app' --certificateDisplayName "Some certificate name" --certificateFile c:\temp\some-certificate.cer
|
|
179
|
+
m365 aad app add --name 'My AAD app' --certificateDisplayName "Some certificate name" --certificateFile "c:\temp\some-certificate.cer"
|
|
180
180
|
```
|
|
@@ -85,5 +85,5 @@ m365 aad app set --objectId 95cfe30d-ed44-4f9d-b73d-c66560f72e83 --redirectUris
|
|
|
85
85
|
Add a certificate to the app
|
|
86
86
|
|
|
87
87
|
```sh
|
|
88
|
-
m365 aad app set --certificateDisplayName "Some certificate name" --certificateFile c:\temp\some-certificate.cer
|
|
88
|
+
m365 aad app set --appId e75be2e1-0204-4f95-857d-51a37cf40be8 --certificateDisplayName "Some certificate name" --certificateFile "c:\temp\some-certificate.cer"
|
|
89
89
|
```
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# booking business get
|
|
2
|
+
|
|
3
|
+
Retrieve the specified Microsoft Bookings business.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
m365 booking business get [options]
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Options
|
|
12
|
+
|
|
13
|
+
`-i, --id [id]`
|
|
14
|
+
: ID of the business. Specify either `id` or `name` but not both.
|
|
15
|
+
|
|
16
|
+
`-n, --name [name]`
|
|
17
|
+
: Name of the business. Specify either `id` or `name` but not both.
|
|
18
|
+
|
|
19
|
+
--8<-- "docs/cmd/_global.md"
|
|
20
|
+
|
|
21
|
+
## Examples
|
|
22
|
+
|
|
23
|
+
Retrieve the specified Microsoft Bookings business with id _business@contoso.onmicrosoft.com_.
|
|
24
|
+
|
|
25
|
+
```sh
|
|
26
|
+
m365 booking business get --id 'business@contoso.onmicrosoft.com'
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Retrieve the specified Microsoft Bookings business with name _business name_.
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
m365 booking business get --name 'business name'
|
|
33
|
+
```
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# booking business list
|
|
2
|
+
|
|
3
|
+
Lists all Microsoft Bookings businesses that are created for the tenant.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
m365 booking business list [options]
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Options
|
|
12
|
+
|
|
13
|
+
--8<-- "docs/cmd/_global.md"
|
|
14
|
+
|
|
15
|
+
## Examples
|
|
16
|
+
|
|
17
|
+
Returns a list of all Microsoft Bookings businesses that are created for the tenant.
|
|
18
|
+
|
|
19
|
+
```sh
|
|
20
|
+
m365 booking business list
|
|
21
|
+
```
|
|
@@ -29,4 +29,4 @@ cli completion clink update > m365.lua
|
|
|
29
29
|
|
|
30
30
|
## More information
|
|
31
31
|
|
|
32
|
-
- Command completion: [https://pnp.github.io/cli-microsoft365/
|
|
32
|
+
- Command completion: [https://pnp.github.io/cli-microsoft365/user-guide/completion/](https://pnp.github.io/cli-microsoft365/user-guide/completion/)
|
|
@@ -31,4 +31,4 @@ cli completion pwsh setup --profile $profile
|
|
|
31
31
|
|
|
32
32
|
## More information
|
|
33
33
|
|
|
34
|
-
- Command completion: [https://pnp.github.io/cli-microsoft365/
|
|
34
|
+
- Command completion: [https://pnp.github.io/cli-microsoft365/user-guide/completion/](https://pnp.github.io/cli-microsoft365/user-guide/completion/)
|
|
@@ -26,4 +26,4 @@ cli completion pwsh update
|
|
|
26
26
|
|
|
27
27
|
## More information
|
|
28
28
|
|
|
29
|
-
- Command completion: [https://pnp.github.io/cli-microsoft365/
|
|
29
|
+
- Command completion: [https://pnp.github.io/cli-microsoft365/user-guide/completion/](https://pnp.github.io/cli-microsoft365/user-guide/completion/)
|
|
@@ -22,4 +22,4 @@ cli completion sh setup
|
|
|
22
22
|
|
|
23
23
|
## More information
|
|
24
24
|
|
|
25
|
-
- Command completion: [https://pnp.github.io/cli-microsoft365/
|
|
25
|
+
- Command completion: [https://pnp.github.io/cli-microsoft365/user-guide/completion/](https://pnp.github.io/cli-microsoft365/user-guide/completion/)
|
|
@@ -26,4 +26,4 @@ m365 cli completion sh update
|
|
|
26
26
|
|
|
27
27
|
## More information
|
|
28
28
|
|
|
29
|
-
- Command completion: [https://pnp.github.io/cli-microsoft365/
|
|
29
|
+
- Command completion: [https://pnp.github.io/cli-microsoft365/user-guide/completion/](https://pnp.github.io/cli-microsoft365/user-guide/completion/)
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# search externalconnection remove
|
|
2
|
+
|
|
3
|
+
Allow the administrator to remove a specific external connection used in Microsoft Search.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
m365 search externalconnection remove [options]
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Options
|
|
12
|
+
|
|
13
|
+
`-i, --id [id]`
|
|
14
|
+
: ID of the External Connection to remove. Specify either `id` or `name`
|
|
15
|
+
|
|
16
|
+
`-n, --name [name]`
|
|
17
|
+
: Name of the External Connection to remove. Specify either `id` or `name`
|
|
18
|
+
|
|
19
|
+
`--confirm`
|
|
20
|
+
: Don't prompt for confirming removing the connection
|
|
21
|
+
|
|
22
|
+
--8<-- "docs/cmd/_global.md"
|
|
23
|
+
|
|
24
|
+
## Remarks
|
|
25
|
+
|
|
26
|
+
If the command finds multiple external connections used in Microsoft Search with the specified name, it will prompt you to disambiguate which external connection it should remove, listing the discovered IDs.
|
|
27
|
+
|
|
28
|
+
## Examples
|
|
29
|
+
|
|
30
|
+
Removes external connection with id _MyApp_
|
|
31
|
+
|
|
32
|
+
```sh
|
|
33
|
+
m365 search externalconnection remove --id "MyApp"
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Removes external connection with name _Test_. Will NOT prompt for confirmation before removing.
|
|
37
|
+
|
|
38
|
+
```sh
|
|
39
|
+
m365 search externalconnection remove --name "Test" --confirm
|
|
40
|
+
```
|