Comments (3)
I'll work on this issue both tonight & tomorrow.
The current plan is to use Fluent-FFMPEG to Trim videos exceeding the max length down automatically, downloading the direct url of the post if need be.
from byte-api.
update I got it working and most of what I said initially was wrong lmao but here are actually the steps simplified for future reference:
Step 1:
POST to /upload
// may also wanna be using user agent headers
headers: {
'Content-Type': 'application/json',
Authorization: '<your token>'
}
payload: {
contentType: 'video/mp4'
}
returns data with an uploadID and uploadURL
Step 2:
PUT to that uploadURL
headers: {
'Content-Type': 'video/mp4'
}
// payload is just an mp4 file, 5MB limit, seems to also have min length limit but unsure exactly.
Step 3:
POST to /post
headers: {
'Content-Type': 'application/json',
Authorization: '<your token>'
}
payload:{
category: '<any category on byte>',
videoUploadID :'<uploadID from step 1>' ,
thumbUploadID: '<uploadID from step 1>',
caption: '<your caption>'
}
that will return a video aka post object & should let you know if successful
credit to mix and his examples which basically showed the way.
from byte-api.
Was added in 340a8a8
from byte-api.
Related Issues (9)
- JSDocs & Github Pages not working. HOT 1
- Add Rebyte Endpoint HOT 1
- Add Set Avatar ability HOT 1
- use of FFMPEG to resize and modify videos before upload
- Needed Typedefs for JSDocs HOT 1
- Add method (or does it exist?) to get self user account HOT 1
- ReferenceError: resolveSource is not defined - Client.js:236
- TypeScript Rewrite
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from byte-api.