Support Topics Documentation Slack YouTube Blog

Get Directory File Listing

(Roy N.) #1

Today I got an error using the Directory Listing API for REST. I had specified a page size of 200 and I received an error stating that the page size limit is 100.

When there are more than 100 files (500 files) in a directory, how do you enumerate all 500 files?

I see the “totalObjects”:500 in the response JSON data. Is this object string going to be there in the future?

If I can count on this string being there telling me the total objects, then I can adjust the offset in the call for the Directory Listing to get the next page of data until there isn’t anymore.

(Roy N.) #2

A few months ago, I thought the totalObjects was going to be removed???

(Anton Govorushkin) #3

Hello Roy

In the current release we still use ‘total objects’. We’ll inform you as soon as the changes will be made.


(Roy N.) #4

Additionally, are you saying that the total objects will be removed for sure in the future and some other method will be put into place so that developers can enumerate file listings?

(Anton Govorushkin) #5

Sure, that’s exactly what I meant.


(Roy N.) #6

Will this not break developers code that currently uses the totalObjects to enumerate all files in a directory that contains more than 100 files?

(Anton Govorushkin) #7

Unfortunately, I’m pretty sure it will.


(Mark Piller) #8

We are currently working on the new version of Backendless - version 4.0. The new release will contain some important changes that will break backward compatibility. There will be two clusters running: one with the existing (3.x) apps and the other with the 4.0 version of Backendless. There will also be a way to migrate the backend from 3.x to 4.0 (and keep the 3.x running for some time). There will be grace period so everyone can migrate their client app to 4.0.


(Roy N.) #9

Thanks for the information - It does help

(Jeroen Dierckx) #10

Will the new API be the same as requesting data collections now (using a nextPage URL property)? I am refactoring some code and if so, I can take that into account.

(Sergey Kukurudzyak) #11

it will be the same with nextPage

(Ps Jimmy) #12

Hi Mark and Sergey

To be honest with you, I am really happy with what you have done with the changes on file-Referencing. Kudos to you guys.
It is unfortunate that i don’t know how to apply it in my code yet but I believe it is part of the 4.0 package. Can’t wait to see the docs on the new changes. But if the docs are ready, kindly let us know.

Keep up with the good work.

(Jeroen Dierckx) #13

Yes, documentation about the upcoming changes, even when incomplete, will get a lot of us excited.

Thanks for the hard work!