public override void Configure(CommandLineApplication command) { _app = command; command.Description = "Update a folder."; _folderId = command.Argument("folderId", "Id of folder to update"); _bulkFilePath = BulkFilePathOption.ConfigureOption(command); _filePath = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); _save = SaveOption.ConfigureOption(command); _parentFolderId = command.Option("--parent-folder-id", "Id of new parent folder <ID>", CommandOptionType.SingleValue); _name = command.Option("--name", "New name for folder <NAME>", CommandOptionType.SingleValue); _description = command.Option("--description", "New description for folder <DESCRIPTION>", CommandOptionType.SingleValue); _notSynced = command.Option("--not-synced", "Set sync state to not synced", CommandOptionType.NoValue); _partiallySynced = command.Option("--partially-synced", "Set sync state to partially synced", CommandOptionType.NoValue); _synced = command.Option("--synced", "Set sync state to synced", CommandOptionType.NoValue); _access = command.Option("--folder-upload-email-access <ACCESS>", "Upload email access level", CommandOptionType.SingleValue); _sharedLinkAccess = command.Option("--shared-link-access <ACCESS>", "Shared link access level", CommandOptionType.SingleValue); _sharedLinkPassword = command.Option("--shared-link-password <PASSWORD>", "Shared link password", CommandOptionType.SingleValue); _sharedLinkUnsharedAt = command.Option("--shared-link-unshared-at <TIME>", "Time that this link will become disabled, use formatting like 03w for 3 weeks.", CommandOptionType.SingleValue); _sharedLinkCanDownload = command.Option("--shared-link-can-download", "Whether the shared link allows downloads", CommandOptionType.NoValue); _tags = command.Option("--tags <TAGS>", "Comma seperated tags", CommandOptionType.SingleValue); _etag = command.Option("--etag <ETAG>", "Only move if etag value matches", CommandOptionType.SingleValue); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "Update a collaboration."; _id = command.Argument("collaborationId", "ID of the collaboration"); _path = FilePathOption.ConfigureOption(command); _bulkPath = BulkFilePathOption.ConfigureOption(command); _save = SaveOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); _fieldsOption = FieldsOption.ConfigureOption(command); _editor = command.Option("--editor", "Set the role to editor.", CommandOptionType.NoValue); _viewer = command.Option("--viewer", "Set the role to viewer.", CommandOptionType.NoValue); _previewer = command.Option("--previewer", "Set the role to previewer.", CommandOptionType.NoValue); _uploader = command.Option("--uploader", "Set the role to uploader.", CommandOptionType.NoValue); _previewerUploader = command.Option("--previewer-uploader", "Set the role to previewer uploader.", CommandOptionType.NoValue); _viewerUploader = command.Option("--viewer-uploader", "Set the role to viewer uploader.", CommandOptionType.NoValue); _coowner = command.Option("--co-owner", "Set the role to co-owner.", CommandOptionType.NoValue); _owner = command.Option("--owner", "Set the role to owner.", CommandOptionType.NoValue); _role = command.Option("-r|--role", "An option to manually enter the role", CommandOptionType.SingleValue); _status = command.Option("--status", "Update the collaboration status", CommandOptionType.SingleValue); _canViewPath = command.Option("--can-view-path", "Whether view path collaboration feature is enabled or not.", CommandOptionType.NoValue); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "Create a collaboration for a Box item."; _path = FilePathOption.ConfigureOption(command); _bulkPath = BulkFilePathOption.ConfigureOption(command); _save = SaveOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); _fieldsOption = FieldsOption.ConfigureOption(command); _editor = command.Option("--editor", "Set the role to editor.", CommandOptionType.NoValue); _viewer = command.Option("--viewer", "Set the role to viewer.", CommandOptionType.NoValue); _previewer = command.Option("--previewer", "Set the role to previewer.", CommandOptionType.NoValue); _uploader = command.Option("--uploader", "Set the role to uploader.", CommandOptionType.NoValue); _previewerUploader = command.Option("--previewer-uploader", "Set the role to previewer uploader.", CommandOptionType.NoValue); _viewerUploader = command.Option("--viewer-uploader", "Set the role to viewer uploader.", CommandOptionType.NoValue); _coowner = command.Option("--co-owner", "Set the role to co-owner.", CommandOptionType.NoValue); _role = command.Option("-r|--role", "An option to manually enter the role", CommandOptionType.SingleValue); _userId = command.Option("--user-id", "Id for user to collaborate", CommandOptionType.SingleValue); _groupId = command.Option("--group-id", "Id for group to collaborate", CommandOptionType.SingleValue); _login = command.Option("--login", "Login for user to collaborate", CommandOptionType.SingleValue); _canViewPath = command.Option("--can-view-path", "Whether view path collaboration feature is enabled or not.", CommandOptionType.NoValue); _idOnly = IdOnlyOption.ConfigureOption(command); _id = command.Argument("boxItemId", "Id of the Box item"); if (base._t == BoxType.enterprise) { _type = command.Argument("boxItemType", "Type of Box item"); } command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "List all webhooks."; _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "List items in a folder."; _folderId = command.Argument("folderId", "Id of folder to manage, use '0' for the root folder"); _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "List all tasks on this file."; _fileId = command.Argument("fileId", "Id of file on which to retrieve tasks"); _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "List all task assignments on a task."; _taskId = command.Argument("taskId", "Id of task"); _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "Get events."; _enterprise = command.Option("-e|--enterprise", "Get enterprise events", CommandOptionType.NoValue); _createdBefore = command.Option("--created-before", "Return enterprise events that occured before a time. Use a timestamp or shorthand syntax 00t, like 05w for 5 weeks. If not used, defaults to now.", CommandOptionType.SingleValue); _createdAfter = command.Option("--created-after", "Return enterprise events that occured before a time. Use a timestamp or shorthand syntax 00t, like 05w for 5 weeks. If not used, defaults to 5 days ago.", CommandOptionType.SingleValue); _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); command.OnExecute(async () => { return await this.Execute(); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "List all Box users."; _managedUsers = ManagedUsersOnlyOption.ConfigureOption(command); _appUsers = AppUsersOnlyOption.ConfigureOption(command); _save = SaveOption.ConfigureOption(command); _path = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); _fieldsOption = FieldsOption.ConfigureOption(command); _limit = LimitOption.ConfigureOption(command); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }
public override void Configure(CommandLineApplication command) { _app = command; command.Description = "Create a new folder"; _bulkPath = BulkFilePathOption.ConfigureOption(command); _filePath = FilePathOption.ConfigureOption(command); _fileFormat = FileFormatOption.ConfigureOption(command); _save = SaveOption.ConfigureOption(command); _idOnly = IdOnlyOption.ConfigureOption(command); _parentFolderId = command.Argument("parentFolderId", "Id of parent folder to add new folder to, use '0' for the root folder"); _name = command.Argument("name", "Name of new folder"); command.OnExecute(async() => { return(await this.Execute()); }); base.Configure(command); }