cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to know all about tools for creatives that work seamlessly with Dropbox, like Adobe? Well, check it out right here!

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Why is "assets" field an array in v2 events API?

Why is "assets" field an array in v2 events API?

Info V.1
Collaborator | Level 8

Hi There,

We are using v2 version of events api and I want to understand why the "assets" field is an array? Under what circumstances can it return more than one values and what are these values?

Example , I get below for file upload event:

"assets": [
                {
                    ".tag": "file",
                    "path": {
                        "contextual": "/Sales/100Files/200/dbx-new-bus--200.docx",
                        "namespace_relative": {
                            "ns_id": "5218920352",
                            "relative_path": "/100Files/200/dbx-new-bus--200.docx"
                        }
                    },
                    "display_name": "dbx-new-bus--200.docx",
                    "file_id": "id:tG_h5JeqH1AAAAAAAAAAfQ"
                }
            ],

Thanks,

Manish

1 Accepted Solution

Accepted Solutions

Re: Why is "assets" field an array in v2 events API?

Greg-DB
Dropboxer

The 'assets' field is documented under /2/team_log/get_events. Make sure you click through 'TeamEvent' > 'AssetLogInfo' for the full description:

Zero or more content assets involved in the action. Currently these include Dropbox files and folders but in the future we might add other asset types such as Paper documents, folders, projects, etc. This field is optional.

So, if a particular event involves more than one asset at once, 'assets' may be longer than 1 item long in order to identify all relevant assets. Each item in the array will be of type 'AssetLogInfo'.

For instance, a 'file_copy' event lists both the 'AssetLogInfo' for the source file, as well as the 'AssetLogInfo' for the new copy of the file.

View solution in original post

1 Reply 1

Re: Why is "assets" field an array in v2 events API?

Greg-DB
Dropboxer

The 'assets' field is documented under /2/team_log/get_events. Make sure you click through 'TeamEvent' > 'AssetLogInfo' for the full description:

Zero or more content assets involved in the action. Currently these include Dropbox files and folders but in the future we might add other asset types such as Paper documents, folders, projects, etc. This field is optional.

So, if a particular event involves more than one asset at once, 'assets' may be longer than 1 item long in order to identify all relevant assets. Each item in the array will be of type 'AssetLogInfo'.

For instance, a 'file_copy' event lists both the 'AssetLogInfo' for the source file, as well as the 'AssetLogInfo' for the new copy of the file.

View solution in original post

Poll
Do you work or study in the creative industry? If so, which area?
If you use Adobe, don't forget to check out our latest integrations update here.
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropboxer
What do Dropbox user levels mean?
Need more support?