We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
DiwakarK
7 years agoExplorer | Level 4
Why file Ids are prefixed with "id:" string?
I have seen that file ids in Dropbox is prefixed with some strings like "id:" or "ns:" or "dbid:". I am new to DB and just want to know the purpose of this? And best practices to handle these ids.
Greg-DB
Dropbox Community Moderator
7 years agoThese prefixes are used to identify and validate these strings across the API. E.g., the "id:" prefix is always used for a file ID, a "ns:" prefix is always used for a namespace ID, etc.
You app can store and re-use these values, but shouldn't attempt to modify them. You can see what kinds of values different parameters accept in the API documentation. E.g., you can see that the "path" parameter for the /2/files/download endpoint accepts relative paths that match '/(.|[\r\n])*', file IDs that match 'id:.*', revision values that match 'rev:[0-9a-f]{9,}', or namespace-relative paths that match 'ns:[0-9]+(/.*)?)'.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!