Bundle Notifications

A BundleNotification is an E-Mail sent out to users when certain actions are performed on or within a shared set of files and folders.

Endpoint

GET/bundle_notifications

Return Object

BundleNotification[]

Authorization Requirement

Available to all authenticated keys or sessions.

Request Parameters

ParameterDescription
user_id
int64
User ID. Provide a value of 0 to operate the current session's user.
bundle_id
int64
Bundle ID

Additional Arguments

Example Request

curl "https://app.files.com/api/rest/v1/bundle_notifications.json?user_id=1&bundle_id=1" \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

Example Response

[
  {
    "bundle_id": 1,
    "id": 1,
    "notify_on_registration": true,
    "notify_on_upload": true,
    "notify_current_user": true,
    "notify_user_id": 1,
    "workspace_id": 1
  }
]

Endpoint

GET/bundle_notifications/{id}

Return Object

BundleNotification

Authorization Requirement

Available to all authenticated keys or sessions.

Request Parameters

ParameterDescription
id
int64
Required
Bundle Notification ID.

Example Request

curl https://app.files.com/api/rest/v1/bundle_notifications/{id}.json \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

Example Response

{
  "bundle_id": 1,
  "id": 1,
  "notify_on_registration": true,
  "notify_on_upload": true,
  "notify_current_user": true,
  "notify_user_id": 1,
  "workspace_id": 1
}

Endpoint

POST/bundle_notifications

Return Object

BundleNotification

Authorization Requirement

Available to all authenticated keys or sessions.

Request Parameters

ParameterDefaultDescription
user_id
int64
User ID. Provide a value of 0 to operate the current session's user.
bundle_id
int64
Required
Bundle ID to notify on
notify_user_id
int64
The id of the user to notify.
notify_on_registration
boolean
falseTriggers bundle notification when a registration action occurs for it.
notify_on_upload
boolean
falseTriggers bundle notification when a upload action occurs for it.

Example Request

curl https://app.files.com/api/rest/v1/bundle_notifications.json \
  -X POST \
  -H 'Content-Type: application/json' \
  -d '{"user_id":1,"bundle_id":1,"notify_user_id":1,"notify_on_registration":true,"notify_on_upload":true}' \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

Example Response

{
  "bundle_id": 1,
  "id": 1,
  "notify_on_registration": true,
  "notify_on_upload": true,
  "notify_current_user": true,
  "notify_user_id": 1,
  "workspace_id": 1
}

Endpoint

PATCH/bundle_notifications/{id}

Return Object

BundleNotification

Authorization Requirement

Available to all authenticated keys or sessions.

Request Parameters

ParameterDescription
id
int64
Required
Bundle Notification ID.
notify_on_registration
boolean
Triggers bundle notification when a registration action occurs for it.
notify_on_upload
boolean
Triggers bundle notification when a upload action occurs for it.

Example Request

curl https://app.files.com/api/rest/v1/bundle_notifications/{id}.json \
  -X PATCH \
  -H 'Content-Type: application/json' \
  -d '{"notify_on_registration":true,"notify_on_upload":true}' \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

Example Response

{
  "bundle_id": 1,
  "id": 1,
  "notify_on_registration": true,
  "notify_on_upload": true,
  "notify_current_user": true,
  "notify_user_id": 1,
  "workspace_id": 1
}

Endpoint

DELETE/bundle_notifications/{id}

Return Object

No return value.

Authorization Requirement

Available to all authenticated keys or sessions.

Request Parameters

ParameterDescription
id
int64
Required
Bundle Notification ID.

Example Request

curl https://app.files.com/api/rest/v1/bundle_notifications/{id}.json \
  -X DELETE \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

The BundleNotification Object

Some of the endpoints above return a BundleNotification object. The attributes of this object are listed below.

AttributeDescription
bundle_id
int64
Bundle ID to notify on
id
int64
Bundle Notification ID
notify_on_registration
boolean
Triggers bundle notification when a registration action occurs for it.
notify_on_upload
boolean
Triggers bundle notification when a upload action occurs for it.
notify_current_user
boolean
Is the current user the user to notify?
notify_user_id
int64
The id of the user to notify.
workspace_id
int64
Workspace ID. 0 means the default workspace.

Example BundleNotification Object

{
  "bundle_id": 1,
  "id": 1,
  "notify_on_registration": true,
  "notify_on_upload": true,
  "notify_current_user": true,
  "notify_user_id": 1,
  "workspace_id": 1
}