Closed stevestreza closed 11 years ago
I think that it’ll make more sense to have this as something like limits.file_size, then we can also get limits.following (to make a nicer UX when a free-tier has hit their max followers) and any other limits that may be added in the future.
+1 for this
I like this idea too -- a general get my limits endpoint, authenticated to the user. Can initially contain the current free user limits, and add more as needed.
+1
Really need this - having to hardcode these limits and use the correct one based on what type of user account it is (inferred from how much total storage space there is), sucks. :)
The comment from @simonwelsh is great - a general limits object for other account limitations is probably in order here.
I haven't rolled out documentation for this yet, but there is now a limits
object when you request /stream/0/token. It contains max_file_size
in bytes and possibly following
if there is a limit to how many users this person can follow. Please make sure your app still handles HTTP 507s when a user exceeds their quota (especially in the follow case).
The token endpoint returns a bunch of useful information about what that token can do. It includes a storage field with the available and used storage amounts. A field representing what the file size limit would be useful, as the two tiers have different limits, and that gives forward-looking flexibility in terms of changing those limits. Also it'll get more apps using the data in that endpoint, which is probably good.