{"id":39099153,"url":"https://github.com/cycloneaddons/lavalink-track-codec","last_synced_at":"2026-01-20T16:57:11.508Z","repository":{"id":315685473,"uuid":"1059375786","full_name":"CycloneAddons/lavalink-track-codec","owner":"CycloneAddons","description":"🎵 Lightweight TypeScript library to encode/decode Lavalink track metadata — fast, fully typed, and easy to use with CommonJS \u0026 ESM support","archived":false,"fork":false,"pushed_at":"2025-09-20T02:40:21.000Z","size":16,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-20T04:21:17.749Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CycloneAddons.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-18T11:09:51.000Z","updated_at":"2025-09-20T02:40:25.000Z","dependencies_parsed_at":"2025-09-20T04:21:18.939Z","dependency_job_id":"bfac599c-165a-4905-99ff-411fd40bea74","html_url":"https://github.com/CycloneAddons/lavalink-track-codec","commit_stats":null,"previous_names":["cycloneaddons/lavalink-track-codec"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/CycloneAddons/lavalink-track-codec","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CycloneAddons%2Flavalink-track-codec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CycloneAddons%2Flavalink-track-codec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CycloneAddons%2Flavalink-track-codec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CycloneAddons%2Flavalink-track-codec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CycloneAddons","download_url":"https://codeload.github.com/CycloneAddons/lavalink-track-codec/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CycloneAddons%2Flavalink-track-codec/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28516540,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-17T18:55:29.170Z","status":"ssl_error","status_checked_at":"2026-01-17T18:55:03.375Z","response_time":85,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2026-01-17T19:00:57.840Z","updated_at":"2026-01-17T19:00:58.070Z","avatar_url":"https://github.com/CycloneAddons.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![npm version](https://img.shields.io/npm/v/lavalink-track-codec.svg)](https://www.npmjs.com/package/lavalink-track-codec)  \n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)  \n[![TypeScript](https://img.shields.io/badge/TypeScript-%233178C6.svg?style=flat\u0026logo=typescript\u0026logoColor=white)](https://www.typescriptlang.org/)\n\n---\n\n## Overview\n\n**lavalink-track-codec** is a lightweight TypeScript library to encode and decode Lavalink-compatible audio track metadata efficiently. Designed for music bots and streaming applications, it supports both CommonJS and ES Modules with fully typed interfaces for seamless TypeScript integration.\n\n---\n\n## Features\n\n- ⚡ Fast encoding and decoding of track metadata  \n- 🎵 Supports all essential track info: title, author, length, identifier, stream flags, URIs, and more  \n- 🔄 Compatible with CommonJS and ES Module ecosystems  \n- ✅ Written in TypeScript with full type definitions  \n- 🔧 Simple and minimal API for easy integration  \n\n---\n\n## Installation\n\n```bash\nnpm install lavalink-track-codec\n# or\nyarn add lavalink-track-codec\n````\n\n---\n\n## Usage\n\n```ts\nimport { encodeTrack, decodeTrack } from 'lavalink-track-codec';\nimport type { Track } from 'lavalink-track-codec';\n\nconst track: Track = {\n  title: 'Shayad - CYCLONE ADDDD',\n  author: 'Sony Music India',\n  length: 190000,\n  identifier: 'MJyKN-8UncM',\n  isStream: false,\n  uri: 'https://www.youtube.com/watch?v=MJyKN-8UncM',\n  artworkUrl: 'https://i.ytimg.com/vi/MJyKN-8UncM/mqdefault.jpg',\n  isrc: null,\n  sourceName: 'youtube',\n  position: 0,\n};\n\nconst encoded = encodeTrack(track);\nconst decoded = decodeTrack(encoded);\n\nconsole.log('Encoded Track:', encoded);\nconsole.log('Decoded Track:', decoded);\n```\n\n---\n\n## API\n\n### `encodeTrack(track: Track): string`\n\nEncodes a `Track` object into a string representation.\n\n### `decodeTrack(encoded: string): Track`\n\nDecodes an encoded track string back into a `Track` object.\n\n---\n\n## Track Type Definition\n\n```ts\ntype Track = {\n  title: string;\n  author: string;\n  length: number;\n  identifier: string;\n  isStream: boolean;\n  uri: string;\n  artworkUrl: string | null;\n  isrc: string | null;\n  sourceName: string;\n  position: number;\n};\n```\n\n---\n\n## Development\n\nClone the repo, install dependencies, build, and run tests:\n\n```bash\ngit clone https://github.com/CycloneAddons/lavalink-track-codec\ncd lavalink-track-codec\nnpm install\nnpm run build\nnpm run test\n```\n\nContributions and issues are welcome!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcycloneaddons%2Flavalink-track-codec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcycloneaddons%2Flavalink-track-codec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcycloneaddons%2Flavalink-track-codec/lists"}