Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Media uploads: enforce file length limit for non nostr.build accounts before upload #2216

Open
2 tasks
Tracked by #2214
jb55 opened this issue May 6, 2024 · 1 comment
Open
2 tasks
Tracked by #2214

Comments

@jb55
Copy link
Collaborator

jb55 commented May 6, 2024

To do this, we need a way to know if the current user has a nostr build account. Maybe some kind of quick http nostr auth to test.

Once we know if we have a nostr.build account, then we can know what the size limit on uploads are.

Perhaps this should be generalized with NIP-96 metadata, not sure if it has this

@fishcake advised:

https://developer.apple.com/documentation/avfoundation/avassetexportsession/1622333-filelengthlimit

@jb55 jb55 mentioned this issue May 6, 2024
8 tasks
@jb55
Copy link
Collaborator Author

jb55 commented May 6, 2024

@fishcakeday let me know what is the best way to get the file size limit.

curl https://nostr.build/api/v2/upload/limit is implemented, it will check based on your NIP98 authentication or return a free upload limit by default with no headers:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

2 participants