{"id":24313539,"url":"https://github.com/qubitsync/vidweave","last_synced_at":"2026-05-05T10:32:08.188Z","repository":{"id":272767489,"uuid":"917672792","full_name":"QubitSync/VidWeave","owner":"QubitSync","description":"Efficient Zig-based backend for video processing, handling transcoding, quality chunking, and optimization for seamless streaming applications","archived":false,"fork":false,"pushed_at":"2025-01-16T13:29:04.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-01-16T14:57:24.476Z","etag":null,"topics":["ffmpeg","server","sqlite","zig"],"latest_commit_sha":null,"homepage":"","language":"Zig","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/QubitSync.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-16T12:42:04.000Z","updated_at":"2025-01-16T13:29:06.000Z","dependencies_parsed_at":"2025-01-16T14:57:32.059Z","dependency_job_id":"853d3ecc-c0b3-4fe8-9229-c9dfa9b0ddf8","html_url":"https://github.com/QubitSync/VidWeave","commit_stats":null,"previous_names":["qubitsync/vidweave"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QubitSync%2FVidWeave","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QubitSync%2FVidWeave/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QubitSync%2FVidWeave/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QubitSync%2FVidWeave/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/QubitSync","download_url":"https://codeload.github.com/QubitSync/VidWeave/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242705667,"owners_count":20172326,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ffmpeg","server","sqlite","zig"],"created_at":"2025-01-17T09:12:20.567Z","updated_at":"2026-05-05T10:32:08.091Z","avatar_url":"https://github.com/QubitSync.png","language":"Zig","funding_links":[],"categories":[],"sub_categories":[],"readme":"# VidWeave\n\nVidWeave is a lightweight, Zig-powered backend designed for efficient video processing. It handles tasks like transcoding, chunking videos into multiple quality levels, and saving metadata to an SQLite database. VidWeave also provides a REST API for seamless integration with other services.\n\n## Features\n\n- **Video Processing**: Transcode videos into multiple quality chunks.\n- **SQLite Integration**: Save video metadata and processing details in an SQLite database.\n- **REST API**: Easily integrate with your frontend or other services.\n\n## Requirements\n\n- Zig (latest version)\n- FFmpeg (for video processing)\n- SQLite3\n- Zap\n\n## Installation\n\n1. Clone this repository:\n   ```bash\n   git clone https://github.com/yourusername/VidWeave.git\n   cd VidWeave\n   ```\n\n2. Install dependencies (ensure FFmpeg and SQLite are installed on your system).\n\n3. Build the project:\n   ```bash\n   zig build\n   ```\n\n## Usage\n\nRun the application:\n```bash\nzig build run\n```\n\n## API Endpoints\n\nThe provided API and database schema define a clear workflow for uploading, managing, and streaming videos. Below is a summary and clarification for ease of understanding:\n\n### **API Overview**\n\n#### **Upload Video**\n- **Endpoint**: `/api/upload`\n- **Method**: `POST`\n- **Purpose**: Allows uploading a video with metadata like name, description, quality, and a thumbnail.\n- **Required Fields**: `name`, `description`, `quality`, `thumbname`, `video`.\n\n#### **Fetch Video**\n- **Endpoint**: `/api/video/{vid}`\n- **Method**: `GET`\n- **Purpose**: Retrieves video details using the video ID.\n- **Response Data**:\n  - Metadata (`name`, `description`, `quality`, etc.).\n  - Video paths.\n\n#### **Delete Video**\n- **Endpoint**: `/api/video/{vid}`\n- **Method**: `DELETE`\n- **Purpose**: Deletes a specific video by its ID.\n- **Response**: Success message.\n\n#### **Update Video**\n- **Endpoint**: `/api/video/{vid}`\n- **Method**: `PUT`\n- **Purpose**: Updates metadata and video files for a specific video.\n- **Request Fields**: Similar to the upload endpoint.\n\n#### **Player Configuration**\n- **Endpoint**: `/api/player`\n- **Method**: `GET`\n- **Purpose**: Fetches player configuration settings, including video and audio files at different resolutions.\n\n### **Database Schema**\n\nThe `Video` table structure supports the following:\n- Unique identifiers for users (`uid`) and videos (`vid`).\n- Fields for metadata (`name`, `description`, `quality`).\n- JSON structure for video paths, e.g., `{ \"720p:1\": \"/path/to/part1\", ... }`.\n- Timestamps for creation and updates.\n\n### **Player Features**\n- Streams videos and handles buffering.\n- Synchronizes playback with client-side players.\n- Configuration is stored in a JSON-like structure.\n\n## Project Structure\n\n```\n├── src/\n│   ├── main.zig         # Main application file\n│   ├── api.zig          # API endpoint handlers\n│   ├── video_processor.zig  # Video processing logic\n│   ├── db.zig           # SQLite database integration\n├── build.zig            # Build script\n├── README.md            # Project documentation\n```\n\n### Notes for Implementation\n1. **Video Splitting**: The server should handle segmenting videos into parts for efficient streaming (e.g., `320p:1`, `720p:1`).\n2. **Buffer Management**: Ensure the buffer size and synchronization intervals in `playerConfig` match the expected client performance.\n3. **Security**: Protect endpoints, especially upload and delete, with authentication/authorization.\n4. **Error Handling**: Define error responses for cases like invalid video IDs, incomplete uploads, or configuration mismatches.\n\n## Contributing\n\nContributions are welcome! Please open an issue or submit a pull request with your improvements.\n\n## License\n\nThis project is licensed under the MIT License. See `LICENSE` for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqubitsync%2Fvidweave","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqubitsync%2Fvidweave","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqubitsync%2Fvidweave/lists"}