Skip to content

Latest commit

 

History

History
214 lines (145 loc) · 7.88 KB

webhooks.md

File metadata and controls

214 lines (145 loc) · 7.88 KB

box webhooks

List all webhooks

box webhooks

List all webhooks

USAGE
  $ box webhooks

OPTIONS
  -h, --help                             Show CLI help
  -q, --quiet                            Suppress any non-error output to stderr
  -s, --save                             Save report to default reports folder on disk
  -t, --token=token                      Provide a token to perform this call
  -v, --verbose                          Show verbose output, which can be helpful for debugging
  -y, --yes                              Automatically respond yes to all confirmation prompts
  --as-user=as-user                      Provide an ID for a user
  --bulk-file-path=bulk-file-path        File path to bulk .csv or .json objects
  --csv                                  Output formatted CSV
  --fields=fields                        Comma separated list of fields to show
  --json                                 Output formatted JSON

  --max-items=max-items                  A value that indicates the maximum number of results to return. This only
                                         specifies a maximum boundary and will not guarantee the minimum number of
                                         results returned. When the max-items (x) is greater than 1000, then the maximum
                                         ceil(x/1000) requests will be made.

  --no-color                             Turn off colors for logging

  --save-to-file-path=save-to-file-path  Override default file path to save report

ALIASES
  $ box webhooks:list

EXAMPLE
  box webhooks

See code: src/commands/webhooks/index.js

box webhooks:create TARGETTYPE TARGETID

Create a new webhook

USAGE
  $ box webhooks:create TARGETTYPE TARGETID

ARGUMENTS
  TARGETTYPE  (file|folder) Type of Box item to create a webhook on
  TARGETID    ID of the Box item to create a webhook on

OPTIONS
  -T, --triggers=triggers                (required) Triggers for webhook as a comma separated list, e.g.
                                         FILE.DELETED,FILE.PREVIEWED

  -a, --address=address                  (required) URL for your webhook handler

  -h, --help                             Show CLI help

  -q, --quiet                            Suppress any non-error output to stderr

  -s, --save                             Save report to default reports folder on disk

  -t, --token=token                      Provide a token to perform this call

  -v, --verbose                          Show verbose output, which can be helpful for debugging

  -y, --yes                              Automatically respond yes to all confirmation prompts

  --as-user=as-user                      Provide an ID for a user

  --bulk-file-path=bulk-file-path        File path to bulk .csv or .json objects

  --csv                                  Output formatted CSV

  --fields=fields                        Comma separated list of fields to show

  --id-only                              Return only an ID to output from this command

  --json                                 Output formatted JSON

  --no-color                             Turn off colors for logging

  --save-to-file-path=save-to-file-path  Override default file path to save report

EXAMPLE
  box webhooks:create folder 22222 --triggers FILE.DELETED --address https://example.com/webhook/deletion

See code: src/commands/webhooks/create.js

box webhooks:delete ID

Delete a webhook

USAGE
  $ box webhooks:delete ID

ARGUMENTS
  ID  ID of the webhook to delete

OPTIONS
  -h, --help                             Show CLI help
  -q, --quiet                            Suppress any non-error output to stderr
  -s, --save                             Save report to default reports folder on disk
  -t, --token=token                      Provide a token to perform this call
  -v, --verbose                          Show verbose output, which can be helpful for debugging
  -y, --yes                              Automatically respond yes to all confirmation prompts
  --as-user=as-user                      Provide an ID for a user
  --bulk-file-path=bulk-file-path        File path to bulk .csv or .json objects
  --csv                                  Output formatted CSV
  --fields=fields                        Comma separated list of fields to show
  --json                                 Output formatted JSON
  --no-color                             Turn off colors for logging
  --save-to-file-path=save-to-file-path  Override default file path to save report

EXAMPLE
  box webhooks:delete 12345

See code: src/commands/webhooks/delete.js

box webhooks:get ID

Get information about a webhook

USAGE
  $ box webhooks:get ID

ARGUMENTS
  ID  ID of the webhook to get

OPTIONS
  -h, --help                             Show CLI help
  -q, --quiet                            Suppress any non-error output to stderr
  -s, --save                             Save report to default reports folder on disk
  -t, --token=token                      Provide a token to perform this call
  -v, --verbose                          Show verbose output, which can be helpful for debugging
  -y, --yes                              Automatically respond yes to all confirmation prompts
  --as-user=as-user                      Provide an ID for a user
  --bulk-file-path=bulk-file-path        File path to bulk .csv or .json objects
  --csv                                  Output formatted CSV
  --fields=fields                        Comma separated list of fields to show
  --json                                 Output formatted JSON
  --no-color                             Turn off colors for logging
  --save-to-file-path=save-to-file-path  Override default file path to save report

EXAMPLE
  box webhooks:get 12345

See code: src/commands/webhooks/get.js

box webhooks:update ID

Update a webhook

USAGE
  $ box webhooks:update ID

ARGUMENTS
  ID  ID of the webhook to update

OPTIONS
  -T, --triggers=triggers                Triggers for webhook, enter as comma separated list. For example:
                                         FILE.DELETED,FILE.PREVIEWED

  -a, --address=address                  URL for your webhook handler

  -h, --help                             Show CLI help

  -q, --quiet                            Suppress any non-error output to stderr

  -s, --save                             Save report to default reports folder on disk

  -t, --token=token                      Provide a token to perform this call

  -v, --verbose                          Show verbose output, which can be helpful for debugging

  -y, --yes                              Automatically respond yes to all confirmation prompts

  --as-user=as-user                      Provide an ID for a user

  --bulk-file-path=bulk-file-path        File path to bulk .csv or .json objects

  --csv                                  Output formatted CSV

  --fields=fields                        Comma separated list of fields to show

  --json                                 Output formatted JSON

  --no-color                             Turn off colors for logging

  --save-to-file-path=save-to-file-path  Override default file path to save report

EXAMPLE
  box webhooks:update 12345 --triggers FILE.DELETED,FOLDER.DELETED

See code: src/commands/webhooks/update.js