Skip to content

Instantly share code, notes, and snippets.

@mistershubhamkumar
Last active October 16, 2025 15:55
Show Gist options
  • Select an option

  • Save mistershubhamkumar/cabe756b966b7d934fa843498df081aa to your computer and use it in GitHub Desktop.

Select an option

Save mistershubhamkumar/cabe756b966b7d934fa843498df081aa to your computer and use it in GitHub Desktop.
Music 🎶 DAWNLOAD FOR LEVENTER BY MR SHUBHAM
// Create by Corex with 💙
// Modified by MR SHUBHAM
// github.com/Corex24
// t.me/corex2410
const { bot } = require('../lib/')
const fetch = (...args) => import('node-fetch').then(({ default: fetch }) => fetch(...args))
bot(
{
pattern: 'music ?(.*)', // <-- command name
type: 'music',
desc: 'Play music with details & thumbnail',
},
async (message, match) => {
if (!match) return await message.send('❌ कृपया गाने का नाम लिखें।\nउदाहरण: .music arike by kunmie')
const api = `https://apis.davidcyriltech.my.id/play?query=${encodeURIComponent(match)}`
try {
const res = await fetch(api)
const data = await res.json()
if (data.status && data.result && data.result.download_url) {
// Caption तैयार करो
const caption = `🎶 *Title:* ${data.result.title || 'Unknown'}\n👤 *From:* ${data.result.channel || '-'}\n📺 *Total Views:* ${data.result.views || '-'}\n⏱ *Duration:* ${data.result.duration || '-'}\n\n> \`Made By MR SHUBHAM\``
// पहले Thumbnail + Info भेजना
await message.sendFromUrl(
data.result.thumbnail,
{ mimetype: 'image/jpeg', caption: caption }, // <-- caption यहाँ देना ज़रूरी है
'image'
)
// फिर Song भेजना
await message.sendFromUrl(
data.result.download_url,
{ mimetype: 'audio/mp4', ptt: false },
'audio'
)
} else {
await message.send('❌ इस नाम का कोई गाना नहीं मिला।')
}
} catch (e) {
console.error(e)
await message.send('❌ कोई Error आ गया, बाद में कोशिश करें।')
}
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment