@deffa5556/bail 1.0.6 → 1.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/WAProto/index.cjs +106053 -0
- package/cjs/deffa/config.cjs +14 -0
- package/cjs/deffa/plugins/ai/deepseekr1.cjs +35 -0
- package/cjs/deffa/plugins/ai/gita.cjs +26 -0
- package/cjs/deffa/plugins/ai/glm47flash.cjs +35 -0
- package/cjs/deffa/plugins/ai/gptoss120b.cjs +35 -0
- package/cjs/deffa/plugins/ai/qwq32b.cjs +35 -0
- package/cjs/deffa/plugins/berita/antara.cjs +25 -0
- package/cjs/deffa/plugins/berita/cnbcindonesia.cjs +25 -0
- package/cjs/deffa/plugins/berita/cnn.cjs +25 -0
- package/cjs/deffa/plugins/berita/kompas.cjs +25 -0
- package/cjs/deffa/plugins/berita/liputan6.cjs +25 -0
- package/cjs/deffa/plugins/berita/merdeka.cjs +25 -0
- package/cjs/deffa/plugins/berita/sindonews.cjs +25 -0
- package/cjs/deffa/plugins/berita/tribunnews.cjs +25 -0
- package/cjs/deffa/plugins/downloader/douyin.cjs +30 -0
- package/cjs/deffa/plugins/downloader/facebook.cjs +30 -0
- package/cjs/deffa/plugins/downloader/github.cjs +35 -0
- package/cjs/deffa/plugins/downloader/lahelu.cjs +30 -0
- package/cjs/deffa/plugins/downloader/snackvideo.cjs +30 -0
- package/cjs/deffa/plugins/downloader/soundcloud.cjs +30 -0
- package/cjs/deffa/plugins/downloader/tiktok.cjs +30 -0
- package/cjs/deffa/plugins/downloader/tiktokhd.cjs +30 -0
- package/cjs/deffa/plugins/downloader/twitter.cjs +30 -0
- package/cjs/deffa/plugins/downloader/ummy.cjs +36 -0
- package/cjs/deffa/plugins/index.cjs +213 -0
- package/cjs/deffa/plugins/info/bmkg.cjs +34 -0
- package/cjs/deffa/plugins/info/cuaca.cjs +31 -0
- package/cjs/deffa/plugins/info/jadwaltv.cjs +29 -0
- package/cjs/deffa/plugins/maker/brat.cjs +45 -0
- package/cjs/deffa/plugins/maker/bratvid.cjs +52 -0
- package/cjs/deffa/plugins/search/8font.cjs +28 -0
- package/cjs/deffa/plugins/search/applemusic.cjs +28 -0
- package/cjs/deffa/plugins/search/bimg.cjs +30 -0
- package/cjs/deffa/plugins/search/brave.cjs +34 -0
- package/cjs/deffa/plugins/search/duckduckgo.cjs +28 -0
- package/cjs/deffa/plugins/search/lahelu.cjs +28 -0
- package/cjs/deffa/plugins/search/mangatoon.cjs +28 -0
- package/cjs/deffa/plugins/search/mcpedl.cjs +28 -0
- package/cjs/deffa/plugins/search/myinstants.cjs +28 -0
- package/cjs/deffa/plugins/search/otakotaku.cjs +28 -0
- package/cjs/deffa/plugins/search/pinterest.cjs +30 -0
- package/cjs/deffa/plugins/search/resep.cjs +28 -0
- package/cjs/deffa/plugins/search/seegore.cjs +30 -0
- package/cjs/deffa/plugins/search/soundcloud.cjs +28 -0
- package/cjs/deffa/plugins/search/youtube.cjs +28 -0
- package/cjs/deffa/plugins/stalk/github.cjs +38 -0
- package/cjs/deffa/plugins/stalk/pinterest.cjs +37 -0
- package/cjs/deffa/plugins/stalk/threads.cjs +34 -0
- package/cjs/deffa/plugins/stalk/tiktok.cjs +37 -0
- package/cjs/deffa/plugins/stalk/twitter.cjs +37 -0
- package/cjs/deffa/plugins/stalk/youtube.cjs +37 -0
- package/cjs/lib/Defaults/index.cjs +158 -0
- package/cjs/lib/Discord/Client.cjs +263 -0
- package/cjs/lib/Discord/Constants.cjs +1842 -0
- package/cjs/lib/Discord/connect-dc.cjs +11 -0
- package/cjs/lib/Discord/esm-bridge.cjs +136 -0
- package/cjs/lib/Discord/gateway/Dispatcher.cjs +93 -0
- package/cjs/lib/Discord/gateway/Shard.cjs +695 -0
- package/cjs/lib/Discord/gateway/ShardManager.cjs +344 -0
- package/cjs/lib/Discord/gateway/compression/base.cjs +13 -0
- package/cjs/lib/Discord/gateway/compression/config.cjs +47 -0
- package/cjs/lib/Discord/gateway/compression/pako.cjs +44 -0
- package/cjs/lib/Discord/gateway/compression/zlib-native.cjs +47 -0
- package/cjs/lib/Discord/gateway/compression/zlib-sync.cjs +31 -0
- package/cjs/lib/Discord/gateway/compression/zstd-napi.cjs +80 -0
- package/cjs/lib/Discord/gateway/compression/zstd-native.cjs +46 -0
- package/cjs/lib/Discord/gateway/events.cjs +956 -0
- package/cjs/lib/Discord/index.cjs +238 -0
- package/cjs/lib/Discord/rest/Bucket.cjs +69 -0
- package/cjs/lib/Discord/rest/DiscordHTTPError.cjs +63 -0
- package/cjs/lib/Discord/rest/DiscordRESTError.cjs +84 -0
- package/cjs/lib/Discord/rest/OAuthHelper.cjs +226 -0
- package/cjs/lib/Discord/rest/RESTManager.cjs +116 -0
- package/cjs/lib/Discord/rest/RequestHandler.cjs +320 -0
- package/cjs/lib/Discord/rest/SequentialBucket.cjs +69 -0
- package/cjs/lib/Discord/routes/Applications.cjs +625 -0
- package/cjs/lib/Discord/routes/Channels.cjs +1199 -0
- package/cjs/lib/Discord/routes/Guilds.cjs +1792 -0
- package/cjs/lib/Discord/routes/Interactions.cjs +212 -0
- package/cjs/lib/Discord/routes/Lobbies.cjs +197 -0
- package/cjs/lib/Discord/routes/Miscellaneous.cjs +120 -0
- package/cjs/lib/Discord/routes/OAuth.cjs +350 -0
- package/cjs/lib/Discord/routes/Users.cjs +107 -0
- package/cjs/lib/Discord/routes/Webhooks.cjs +308 -0
- package/cjs/lib/Discord/structures/AnnouncementChannel.cjs +46 -0
- package/cjs/lib/Discord/structures/AnnouncementThreadChannel.cjs +28 -0
- package/cjs/lib/Discord/structures/Application.cjs +345 -0
- package/cjs/lib/Discord/structures/ApplicationCommand.cjs +109 -0
- package/cjs/lib/Discord/structures/Attachment.cjs +46 -0
- package/cjs/lib/Discord/structures/AuditLogEntry.cjs +41 -0
- package/cjs/lib/Discord/structures/AutoModerationRule.cjs +117 -0
- package/cjs/lib/Discord/structures/AutocompleteInteraction.cjs +90 -0
- package/cjs/lib/Discord/structures/Base.cjs +56 -0
- package/cjs/lib/Discord/structures/BaseEntitlement.cjs +40 -0
- package/cjs/lib/Discord/structures/CategoryChannel.cjs +102 -0
- package/cjs/lib/Discord/structures/Channel.cjs +89 -0
- package/cjs/lib/Discord/structures/ClientApplication.cjs +269 -0
- package/cjs/lib/Discord/structures/CommandInteraction.cjs +294 -0
- package/cjs/lib/Discord/structures/ComponentInteraction.cjs +306 -0
- package/cjs/lib/Discord/structures/Entitlement.cjs +24 -0
- package/cjs/lib/Discord/structures/ExtendedUser.cjs +48 -0
- package/cjs/lib/Discord/structures/ForumChannel.cjs +20 -0
- package/cjs/lib/Discord/structures/GroupChannel.cjs +160 -0
- package/cjs/lib/Discord/structures/Guild.cjs +1289 -0
- package/cjs/lib/Discord/structures/GuildChannel.cjs +82 -0
- package/cjs/lib/Discord/structures/GuildPreview.cjs +141 -0
- package/cjs/lib/Discord/structures/GuildScheduledEvent.cjs +166 -0
- package/cjs/lib/Discord/structures/GuildTemplate.cjs +96 -0
- package/cjs/lib/Discord/structures/Integration.cjs +123 -0
- package/cjs/lib/Discord/structures/Interaction.cjs +78 -0
- package/cjs/lib/Discord/structures/InteractionResolvedChannel.cjs +36 -0
- package/cjs/lib/Discord/structures/Invite.cjs +196 -0
- package/cjs/lib/Discord/structures/InviteGuild.cjs +117 -0
- package/cjs/lib/Discord/structures/InviteRole.cjs +88 -0
- package/cjs/lib/Discord/structures/Lobby.cjs +84 -0
- package/cjs/lib/Discord/structures/LobbyMember.cjs +30 -0
- package/cjs/lib/Discord/structures/MediaChannel.cjs +20 -0
- package/cjs/lib/Discord/structures/Member.cjs +300 -0
- package/cjs/lib/Discord/structures/Message.cjs +553 -0
- package/cjs/lib/Discord/structures/ModalSubmitInteraction.cjs +263 -0
- package/cjs/lib/Discord/structures/OAuthApplication.cjs +203 -0
- package/cjs/lib/Discord/structures/OAuthGuild.cjs +98 -0
- package/cjs/lib/Discord/structures/PartialApplication.cjs +97 -0
- package/cjs/lib/Discord/structures/Permission.cjs +61 -0
- package/cjs/lib/Discord/structures/PermissionOverwrite.cjs +46 -0
- package/cjs/lib/Discord/structures/PingInteraction.cjs +27 -0
- package/cjs/lib/Discord/structures/Poll.cjs +69 -0
- package/cjs/lib/Discord/structures/PrimaryGuild.cjs +93 -0
- package/cjs/lib/Discord/structures/PrivateChannel.cjs +131 -0
- package/cjs/lib/Discord/structures/PrivateThreadChannel.cjs +28 -0
- package/cjs/lib/Discord/structures/PublicThreadChannel.cjs +36 -0
- package/cjs/lib/Discord/structures/Role.cjs +126 -0
- package/cjs/lib/Discord/structures/SKU.cjs +58 -0
- package/cjs/lib/Discord/structures/Soundboard.cjs +58 -0
- package/cjs/lib/Discord/structures/StageChannel.cjs +45 -0
- package/cjs/lib/Discord/structures/StageInstance.cjs +80 -0
- package/cjs/lib/Discord/structures/Subscription.cjs +21 -0
- package/cjs/lib/Discord/structures/Team.cjs +70 -0
- package/cjs/lib/Discord/structures/TestEntitlement.cjs +22 -0
- package/cjs/lib/Discord/structures/TextChannel.cjs +48 -0
- package/cjs/lib/Discord/structures/TextableChannel.cjs +265 -0
- package/cjs/lib/Discord/structures/TextableVoiceChannel.cjs +70 -0
- package/cjs/lib/Discord/structures/ThreadChannel.cjs +276 -0
- package/cjs/lib/Discord/structures/ThreadOnlyChannel.cjs +205 -0
- package/cjs/lib/Discord/structures/ThreadableChannel.cjs +57 -0
- package/cjs/lib/Discord/structures/UnavailableGuild.cjs +21 -0
- package/cjs/lib/Discord/structures/User.cjs +223 -0
- package/cjs/lib/Discord/structures/VoiceChannel.cjs +34 -0
- package/cjs/lib/Discord/structures/VoiceState.cjs +113 -0
- package/cjs/lib/Discord/structures/Webhook.cjs +224 -0
- package/cjs/lib/Discord/util/Collection.cjs +77 -0
- package/cjs/lib/Discord/util/Errors.cjs +81 -0
- package/cjs/lib/Discord/util/QueryBuilder.cjs +20 -0
- package/cjs/lib/Discord/util/Routes.cjs +293 -0
- package/cjs/lib/Discord/util/SimpleCollection.cjs +78 -0
- package/cjs/lib/Discord/util/Time.cjs +92 -0
- package/cjs/lib/Discord/util/TypedCollection.cjs +78 -0
- package/cjs/lib/Discord/util/TypedEmitter.cjs +20 -0
- package/cjs/lib/Discord/util/Util.cjs +906 -0
- package/cjs/lib/Discord/util/interactions/InteractionOptionsWrapper.cjs +207 -0
- package/cjs/lib/Discord/util/interactions/MessageInteractionResponse.cjs +26 -0
- package/cjs/lib/Discord/util/interactions/ModalSubmitInteractionComponentsWrapper.cjs +98 -0
- package/cjs/lib/Discord/util/interactions/SelectMenuValuesWrapper.cjs +77 -0
- package/cjs/lib/Discord/util/interactions/shared.cjs +20 -0
- package/cjs/lib/Discord/util/warning.cjs +34 -0
- package/cjs/lib/Signal/Group/ciphertext-message.cjs +16 -0
- package/cjs/lib/Signal/Group/group-session-builder.cjs +67 -0
- package/cjs/lib/Signal/Group/group_cipher.cjs +86 -0
- package/cjs/lib/Signal/Group/index.cjs +58 -0
- package/cjs/lib/Signal/Group/keyhelper.cjs +56 -0
- package/cjs/lib/Signal/Group/sender-chain-key.cjs +30 -0
- package/cjs/lib/Signal/Group/sender-key-distribution-message.cjs +67 -0
- package/cjs/lib/Signal/Group/sender-key-message.cjs +70 -0
- package/cjs/lib/Signal/Group/sender-key-name.cjs +52 -0
- package/cjs/lib/Signal/Group/sender-key-record.cjs +45 -0
- package/cjs/lib/Signal/Group/sender-key-state.cjs +88 -0
- package/cjs/lib/Signal/Group/sender-message-key.cjs +30 -0
- package/cjs/lib/Signal/libsignal.cjs +467 -0
- package/cjs/lib/Signal/lid-mapping.cjs +281 -0
- package/cjs/lib/Socket/Client/index.cjs +19 -0
- package/cjs/lib/Socket/Client/types.cjs +15 -0
- package/cjs/lib/Socket/Client/websocket.cjs +61 -0
- package/cjs/lib/Socket/business.cjs +384 -0
- package/cjs/lib/Socket/chats.cjs +1221 -0
- package/cjs/lib/Socket/communities.cjs +440 -0
- package/cjs/lib/Socket/groups.cjs +353 -0
- package/cjs/lib/Socket/index.cjs +14 -0
- package/cjs/lib/Socket/messages-recv.cjs +1772 -0
- package/cjs/lib/Socket/messages-send.cjs +1376 -0
- package/cjs/lib/Socket/mex.cjs +46 -0
- package/cjs/lib/Socket/newsletter.cjs +230 -0
- package/cjs/lib/Socket/socket.cjs +976 -0
- package/cjs/lib/Store/index.cjs +20 -0
- package/cjs/lib/Store/make-in-memory-store.cjs +470 -0
- package/cjs/lib/Store/make-ordered-dictionary.cjs +82 -0
- package/cjs/lib/Store/object-repository.cjs +28 -0
- package/cjs/lib/Telegram/button.cjs +147 -0
- package/cjs/lib/Telegram/composer.cjs +582 -0
- package/cjs/lib/Telegram/context.cjs +853 -0
- package/cjs/lib/Telegram/core/helpers/args.cjs +57 -0
- package/cjs/lib/Telegram/core/helpers/check.cjs +55 -0
- package/cjs/lib/Telegram/core/helpers/compact.cjs +16 -0
- package/cjs/lib/Telegram/core/helpers/deunionize.cjs +12 -0
- package/cjs/lib/Telegram/core/helpers/formatting.cjs +91 -0
- package/cjs/lib/Telegram/core/helpers/util.cjs +50 -0
- package/cjs/lib/Telegram/core/network/client.cjs +338 -0
- package/cjs/lib/Telegram/core/network/error.cjs +21 -0
- package/cjs/lib/Telegram/core/network/multipart-stream.cjs +79 -0
- package/cjs/lib/Telegram/core/network/polling.cjs +87 -0
- package/cjs/lib/Telegram/core/network/webhook.cjs +54 -0
- package/cjs/lib/Telegram/core/types/typegram.cjs +31 -0
- package/cjs/lib/Telegram/deffa-telegraf.cjs +264 -0
- package/cjs/lib/Telegram/esm-bridge.cjs +20 -0
- package/cjs/lib/Telegram/filters.cjs +69 -0
- package/cjs/lib/Telegram/format.cjs +58 -0
- package/cjs/lib/Telegram/future.cjs +140 -0
- package/cjs/lib/Telegram/index.cjs +67 -0
- package/cjs/lib/Telegram/input.cjs +61 -0
- package/cjs/lib/Telegram/markup.cjs +129 -0
- package/cjs/lib/Telegram/middleware.cjs +2 -0
- package/cjs/lib/Telegram/reactions.cjs +84 -0
- package/cjs/lib/Telegram/router.cjs +46 -0
- package/cjs/lib/Telegram/scenes/base.cjs +39 -0
- package/cjs/lib/Telegram/scenes/context.cjs +104 -0
- package/cjs/lib/Telegram/scenes/index.cjs +21 -0
- package/cjs/lib/Telegram/scenes/stage.cjs +49 -0
- package/cjs/lib/Telegram/scenes/wizard/context.cjs +31 -0
- package/cjs/lib/Telegram/scenes/wizard/index.cjs +45 -0
- package/cjs/lib/Telegram/scenes.cjs +21 -0
- package/cjs/lib/Telegram/session.cjs +166 -0
- package/cjs/lib/Telegram/telegram-types.cjs +6 -0
- package/cjs/lib/Telegram/telegram.cjs +945 -0
- package/cjs/lib/Telegram/types.cjs +2 -0
- package/cjs/lib/Telegram/utils.cjs +5 -0
- package/cjs/lib/Types/Auth.cjs +3 -0
- package/cjs/lib/Types/Bussines.cjs +3 -0
- package/cjs/lib/Types/Call.cjs +3 -0
- package/cjs/lib/Types/Chat.cjs +11 -0
- package/cjs/lib/Types/Contact.cjs +3 -0
- package/cjs/lib/Types/Events.cjs +4 -0
- package/cjs/lib/Types/GroupMetadata.cjs +3 -0
- package/cjs/lib/Types/Label.cjs +26 -0
- package/cjs/lib/Types/LabelAssociation.cjs +8 -0
- package/cjs/lib/Types/Message.cjs +19 -0
- package/cjs/lib/Types/Mex.cjs +40 -0
- package/cjs/lib/Types/Product.cjs +3 -0
- package/cjs/lib/Types/RichType.cjs +24 -0
- package/cjs/lib/Types/Signal.cjs +4 -0
- package/cjs/lib/Types/Socket.cjs +4 -0
- package/cjs/lib/Types/State.cjs +54 -0
- package/cjs/lib/Types/USync.cjs +4 -0
- package/cjs/lib/Types/index.cjs +42 -0
- package/cjs/lib/Utils/auth-utils.cjs +312 -0
- package/cjs/lib/Utils/browser-utils.cjs +39 -0
- package/cjs/lib/Utils/business.cjs +241 -0
- package/cjs/lib/Utils/chat-utils.cjs +890 -0
- package/cjs/lib/Utils/companion-reg-client-utils.cjs +51 -0
- package/cjs/lib/Utils/crypto.cjs +170 -0
- package/cjs/lib/Utils/decode-wa-message.cjs +330 -0
- package/cjs/lib/Utils/event-buffer.cjs +629 -0
- package/cjs/lib/Utils/generics.cjs +427 -0
- package/cjs/lib/Utils/history.cjs +141 -0
- package/cjs/lib/Utils/identity-change-handler.cjs +56 -0
- package/cjs/lib/Utils/index.cjs +43 -0
- package/cjs/lib/Utils/link-preview.cjs +122 -0
- package/cjs/lib/Utils/logger.cjs +8 -0
- package/cjs/lib/Utils/lt-hash.cjs +11 -0
- package/cjs/lib/Utils/make-mutex.cjs +38 -0
- package/cjs/lib/Utils/message-retry-manager.cjs +267 -0
- package/cjs/lib/Utils/messages-media.cjs +906 -0
- package/cjs/lib/Utils/messages.cjs +1909 -0
- package/cjs/lib/Utils/noise-handler.cjs +205 -0
- package/cjs/lib/Utils/offline-node-processor.cjs +43 -0
- package/cjs/lib/Utils/pre-key-manager.cjs +113 -0
- package/cjs/lib/Utils/process-message.cjs +755 -0
- package/cjs/lib/Utils/reporting-utils.cjs +263 -0
- package/cjs/lib/Utils/rich-message-utils.cjs +434 -0
- package/cjs/lib/Utils/session-guard.cjs +163 -0
- package/cjs/lib/Utils/signal.cjs +214 -0
- package/cjs/lib/Utils/stanza-ack.cjs +41 -0
- package/cjs/lib/Utils/sync-action-utils.cjs +54 -0
- package/cjs/lib/Utils/tc-token-utils.cjs +174 -0
- package/cjs/lib/Utils/text-sticker.cjs +174 -0
- package/cjs/lib/Utils/use-multi-file-auth-state.cjs +125 -0
- package/cjs/lib/Utils/use-single-file-auth-state.cjs +113 -0
- package/cjs/lib/Utils/use-sqlite-auth-state.cjs +145 -0
- package/cjs/lib/Utils/validate-connection.cjs +210 -0
- package/cjs/lib/WABinary/constants.cjs +1470 -0
- package/cjs/lib/WABinary/decode.cjs +301 -0
- package/cjs/lib/WABinary/encode.cjs +257 -0
- package/cjs/lib/WABinary/generic-utils.cjs +240 -0
- package/cjs/lib/WABinary/index.cjs +22 -0
- package/cjs/lib/WABinary/jid-utils.cjs +114 -0
- package/cjs/lib/WABinary/types.cjs +37 -0
- package/cjs/lib/WAM/BinaryInfo.cjs +14 -0
- package/cjs/lib/WAM/constants.cjs +22856 -0
- package/cjs/lib/WAM/encode.cjs +154 -0
- package/cjs/lib/WAM/index.cjs +20 -0
- package/cjs/lib/WAUSync/Protocols/USyncContactProtocol.cjs +56 -0
- package/cjs/lib/WAUSync/Protocols/USyncDeviceProtocol.cjs +58 -0
- package/cjs/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.cjs +31 -0
- package/cjs/lib/WAUSync/Protocols/USyncStatusProtocol.cjs +42 -0
- package/cjs/lib/WAUSync/Protocols/USyncUsernameProtocol.cjs +29 -0
- package/cjs/lib/WAUSync/Protocols/UsyncBotProfileProtocol.cjs +55 -0
- package/cjs/lib/WAUSync/Protocols/UsyncLIDProtocol.cjs +33 -0
- package/cjs/lib/WAUSync/Protocols/index.cjs +22 -0
- package/cjs/lib/WAUSync/USyncQuery.cjs +102 -0
- package/cjs/lib/WAUSync/USyncUser.cjs +35 -0
- package/cjs/lib/WAUSync/index.cjs +20 -0
- package/cjs/lib/index.cjs +372 -0
- package/cjs/lib/plugins/loader.cjs +117 -0
- package/lib/Defaults/index.js +1 -1
- package/package.json +11 -6
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
// config.js — isi sesuai kebutuhan
|
|
4
|
+
exports.default = {
|
|
5
|
+
supabase: {
|
|
6
|
+
url: process.env.SUPABASE_URL || '',
|
|
7
|
+
serviceKey: process.env.SUPABASE_KEY || '',
|
|
8
|
+
bucket: process.env.SUPABASE_BUCKET || 'deffa-media',
|
|
9
|
+
},
|
|
10
|
+
smtp: {
|
|
11
|
+
user: process.env.SMTP_USER || '',
|
|
12
|
+
pass: process.env.SMTP_PASS || '',
|
|
13
|
+
},
|
|
14
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'ai-deepseekr1', name: 'deepseekr1', category: 'AI',
|
|
9
|
+
path: '/api/ai/deepseekr1', method: 'GET',
|
|
10
|
+
description: 'Chat dengan deepseekr1 via siputzx',
|
|
11
|
+
params: [
|
|
12
|
+
{ name: 'prompt', required: true, example: 'Halo, siapa kamu?', description: 'Prompt pengguna' },
|
|
13
|
+
{ name: 'system', required: false, example: 'You are a helpful assistant.', description: 'System prompt' },
|
|
14
|
+
{ name: 'temperature', required: false, example: '0.7', description: 'Temperature (0-1)' },
|
|
15
|
+
],
|
|
16
|
+
handler: async (req, getInput) => {
|
|
17
|
+
const prompt = getInput(req, 'prompt');
|
|
18
|
+
if (!prompt)
|
|
19
|
+
return { ok: false, status: 400, message: "Parameter 'prompt' wajib diisi." };
|
|
20
|
+
try {
|
|
21
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/ai/deepseekr1', {
|
|
22
|
+
params: { prompt, system: getInput(req, 'system') || undefined, temperature: getInput(req, 'temperature') || undefined },
|
|
23
|
+
timeout: 30000,
|
|
24
|
+
});
|
|
25
|
+
if (!data?.status)
|
|
26
|
+
return { ok: false, status: 502, message: 'Gagal mendapat respons.' };
|
|
27
|
+
const raw = data.data?.response || '';
|
|
28
|
+
const result = raw.replace(/<think>[\s\S]*?<\/think>\s*/i, '').trim();
|
|
29
|
+
return { ok: true, type: 'text', result };
|
|
30
|
+
}
|
|
31
|
+
catch (err) {
|
|
32
|
+
return { ok: false, status: 500, message: err.message };
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'ai-gita', name: 'Gita AI', category: 'AI',
|
|
9
|
+
path: '/api/ai/gita', method: 'GET',
|
|
10
|
+
description: 'Tanya Bhagavad Gita AI',
|
|
11
|
+
params: [{ name: 'q', required: true, example: 'What is karma?', description: 'Pertanyaan' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const q = getInput(req, 'q');
|
|
14
|
+
if (!q)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'q' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/ai/gita', { params: { q }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mendapat respons.' };
|
|
20
|
+
return { ok: true, type: 'text', result: data.data };
|
|
21
|
+
}
|
|
22
|
+
catch (err) {
|
|
23
|
+
return { ok: false, status: 500, message: err.message };
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'ai-glm47flash', name: 'glm47flash', category: 'AI',
|
|
9
|
+
path: '/api/ai/glm47flash', method: 'GET',
|
|
10
|
+
description: 'Chat dengan glm47flash via siputzx',
|
|
11
|
+
params: [
|
|
12
|
+
{ name: 'prompt', required: true, example: 'Halo, siapa kamu?', description: 'Prompt pengguna' },
|
|
13
|
+
{ name: 'system', required: false, example: 'You are a helpful assistant.', description: 'System prompt' },
|
|
14
|
+
{ name: 'temperature', required: false, example: '0.7', description: 'Temperature (0-1)' },
|
|
15
|
+
],
|
|
16
|
+
handler: async (req, getInput) => {
|
|
17
|
+
const prompt = getInput(req, 'prompt');
|
|
18
|
+
if (!prompt)
|
|
19
|
+
return { ok: false, status: 400, message: "Parameter 'prompt' wajib diisi." };
|
|
20
|
+
try {
|
|
21
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/ai/glm47flash', {
|
|
22
|
+
params: { prompt, system: getInput(req, 'system') || undefined, temperature: getInput(req, 'temperature') || undefined },
|
|
23
|
+
timeout: 30000,
|
|
24
|
+
});
|
|
25
|
+
if (!data?.status)
|
|
26
|
+
return { ok: false, status: 502, message: 'Gagal mendapat respons.' };
|
|
27
|
+
const raw = data.data?.response || '';
|
|
28
|
+
const result = raw.replace(/<think>[\s\S]*?<\/think>\s*/i, '').trim();
|
|
29
|
+
return { ok: true, type: 'text', result };
|
|
30
|
+
}
|
|
31
|
+
catch (err) {
|
|
32
|
+
return { ok: false, status: 500, message: err.message };
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'ai-gptoss120b', name: 'gptoss120b', category: 'AI',
|
|
9
|
+
path: '/api/ai/gptoss120b', method: 'GET',
|
|
10
|
+
description: 'Chat dengan gptoss120b via siputzx',
|
|
11
|
+
params: [
|
|
12
|
+
{ name: 'prompt', required: true, example: 'Halo, siapa kamu?', description: 'Prompt pengguna' },
|
|
13
|
+
{ name: 'system', required: false, example: 'You are a helpful assistant.', description: 'System prompt' },
|
|
14
|
+
{ name: 'temperature', required: false, example: '0.7', description: 'Temperature (0-1)' },
|
|
15
|
+
],
|
|
16
|
+
handler: async (req, getInput) => {
|
|
17
|
+
const prompt = getInput(req, 'prompt');
|
|
18
|
+
if (!prompt)
|
|
19
|
+
return { ok: false, status: 400, message: "Parameter 'prompt' wajib diisi." };
|
|
20
|
+
try {
|
|
21
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/ai/gptoss120b', {
|
|
22
|
+
params: { prompt, system: getInput(req, 'system') || undefined, temperature: getInput(req, 'temperature') || undefined },
|
|
23
|
+
timeout: 30000,
|
|
24
|
+
});
|
|
25
|
+
if (!data?.status)
|
|
26
|
+
return { ok: false, status: 502, message: 'Gagal mendapat respons.' };
|
|
27
|
+
const raw = data.data?.response || '';
|
|
28
|
+
const result = raw.replace(/<think>[\s\S]*?<\/think>\s*/i, '').trim();
|
|
29
|
+
return { ok: true, type: 'text', result };
|
|
30
|
+
}
|
|
31
|
+
catch (err) {
|
|
32
|
+
return { ok: false, status: 500, message: err.message };
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'ai-qwq32b', name: 'qwq32b', category: 'AI',
|
|
9
|
+
path: '/api/ai/qwq32b', method: 'GET',
|
|
10
|
+
description: 'Chat dengan qwq32b via siputzx',
|
|
11
|
+
params: [
|
|
12
|
+
{ name: 'prompt', required: true, example: 'Halo, siapa kamu?', description: 'Prompt pengguna' },
|
|
13
|
+
{ name: 'system', required: false, example: 'You are a helpful assistant.', description: 'System prompt' },
|
|
14
|
+
{ name: 'temperature', required: false, example: '0.7', description: 'Temperature (0-1)' },
|
|
15
|
+
],
|
|
16
|
+
handler: async (req, getInput) => {
|
|
17
|
+
const prompt = getInput(req, 'prompt');
|
|
18
|
+
if (!prompt)
|
|
19
|
+
return { ok: false, status: 400, message: "Parameter 'prompt' wajib diisi." };
|
|
20
|
+
try {
|
|
21
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/ai/qwq32b', {
|
|
22
|
+
params: { prompt, system: getInput(req, 'system') || undefined, temperature: getInput(req, 'temperature') || undefined },
|
|
23
|
+
timeout: 30000,
|
|
24
|
+
});
|
|
25
|
+
if (!data?.status)
|
|
26
|
+
return { ok: false, status: 502, message: 'Gagal mendapat respons.' };
|
|
27
|
+
const raw = data.data?.response || '';
|
|
28
|
+
const result = raw.replace(/<think>[\s\S]*?<\/think>\s*/i, '').trim();
|
|
29
|
+
return { ok: true, type: 'text', result };
|
|
30
|
+
}
|
|
31
|
+
catch (err) {
|
|
32
|
+
return { ok: false, status: 500, message: err.message };
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-antara', name: 'Berita antara', category: 'Berita',
|
|
9
|
+
path: '/api/berita/antara', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari antara',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/antara', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-cnbcindonesia', name: 'Berita cnbcindonesia', category: 'Berita',
|
|
9
|
+
path: '/api/berita/cnbcindonesia', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari cnbcindonesia',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/cnbcindonesia', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-cnn', name: 'Berita cnn', category: 'Berita',
|
|
9
|
+
path: '/api/berita/cnn', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari cnn',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/cnn', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-kompas', name: 'Berita kompas', category: 'Berita',
|
|
9
|
+
path: '/api/berita/kompas', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari kompas',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/kompas', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-liputan6', name: 'Berita liputan6', category: 'Berita',
|
|
9
|
+
path: '/api/berita/liputan6', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari liputan6',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/liputan6', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-merdeka', name: 'Berita merdeka', category: 'Berita',
|
|
9
|
+
path: '/api/berita/merdeka', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari merdeka',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/merdeka', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-sindonews', name: 'Berita sindonews', category: 'Berita',
|
|
9
|
+
path: '/api/berita/sindonews', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari sindonews',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/sindonews', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'berita-tribunnews', name: 'Berita tribunnews', category: 'Berita',
|
|
9
|
+
path: '/api/berita/tribunnews', method: 'GET',
|
|
10
|
+
description: 'Ambil berita terbaru dari tribunnews',
|
|
11
|
+
params: [],
|
|
12
|
+
handler: async (_req, _getInput) => {
|
|
13
|
+
try {
|
|
14
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/berita/tribunnews', { timeout: 15000 });
|
|
15
|
+
if (!data?.status)
|
|
16
|
+
return { ok: false, status: 502, message: 'Gagal mengambil berita.' };
|
|
17
|
+
const arr = Array.isArray(data.data) ? data.data : [];
|
|
18
|
+
const text = arr.slice(0, 5).map((item, i) => `${i + 1}. *${item.title || item.judul || '-'}*\n ${item.link || item.url || ''}`).join('\n\n');
|
|
19
|
+
return { ok: true, type: 'text', result: text || 'Tidak ada berita.' };
|
|
20
|
+
}
|
|
21
|
+
catch (err) {
|
|
22
|
+
return { ok: false, status: 500, message: err.message };
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-douyin', name: 'Douyin Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/douyin', method: 'GET',
|
|
10
|
+
description: 'Download video Douyin',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://www.douyin.com/video/xxx', description: 'URL video Douyin' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/douyin', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const videoUrl = data.data?.play || data.data?.wmplay;
|
|
21
|
+
const caption = data.data?.title || data.data?.desc || 'Douyin Video';
|
|
22
|
+
if (!videoUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL video tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'video', url: videoUrl, caption };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-facebook', name: 'Facebook Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/facebook', method: 'GET',
|
|
10
|
+
description: 'Download video Facebook',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://www.facebook.com/share/r/xxx/', description: 'URL video Facebook' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/facebook', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const videoUrl = data.data?.sd || data.data?.hd;
|
|
21
|
+
const caption = data.data?.title || 'Facebook Video';
|
|
22
|
+
if (!videoUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL video tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'video', url: videoUrl, caption };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-github', name: 'GitHub Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/github', method: 'GET',
|
|
10
|
+
description: 'Download/lihat konten GitHub (repo/gist)',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://gist.github.com/user/xxx', description: 'URL GitHub repo atau gist' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/github', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengambil data.' };
|
|
20
|
+
const d = data.data || {};
|
|
21
|
+
const text = [
|
|
22
|
+
d.name ? `📁 *${d.name}*` : '',
|
|
23
|
+
d.description ? `📝 ${d.description}` : '',
|
|
24
|
+
d.html_url ? `🔗 ${d.html_url}` : '',
|
|
25
|
+
d.stargazers_count != null ? `⭐ ${d.stargazers_count} stars` : '',
|
|
26
|
+
d.forks_count != null ? `🍴 ${d.forks_count} forks` : '',
|
|
27
|
+
d.language ? `💻 ${d.language}` : '',
|
|
28
|
+
].filter(Boolean).join('\n');
|
|
29
|
+
return { ok: true, type: 'text', result: text || JSON.stringify(d, null, 2) };
|
|
30
|
+
}
|
|
31
|
+
catch (err) {
|
|
32
|
+
return { ok: false, status: 500, message: err.message };
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-lahelu', name: 'Lahelu Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/lahelu', method: 'GET',
|
|
10
|
+
description: 'Download konten Lahelu',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://lahelu.com/post/xxx', description: 'URL post Lahelu' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/lahelu', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const videoUrl = data.data?.video || data.data?.url;
|
|
21
|
+
const caption = data.data?.title || 'Lahelu';
|
|
22
|
+
if (!videoUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL video tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'video', url: videoUrl, caption };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-snackvideo', name: 'SnackVideo Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/snackvideo', method: 'GET',
|
|
10
|
+
description: 'Download video SnackVideo',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://s.snackvideo.com/p/xxx', description: 'URL SnackVideo' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/snackvideo', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const videoUrl = data.data?.play || data.data?.url;
|
|
21
|
+
const caption = data.data?.title || 'SnackVideo';
|
|
22
|
+
if (!videoUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL video tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'video', url: videoUrl, caption };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-soundcloud', name: 'SoundCloud Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/soundcloud', method: 'GET',
|
|
10
|
+
description: 'Download audio SoundCloud',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://soundcloud.com/user/track', description: 'URL SoundCloud' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/soundcloud', { params: { url }, timeout: 20000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const audioUrl = data.data?.url || data.data?.audio || data.data?.download;
|
|
21
|
+
const caption = data.data?.title || data.data?.name || 'SoundCloud Audio';
|
|
22
|
+
if (!audioUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL audio tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'audio', url: audioUrl, caption, mimetype: 'audio/mpeg' };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
|
7
|
+
exports.default = {
|
|
8
|
+
id: 'dl-tiktok', name: 'TikTok Downloader', category: 'Downloader',
|
|
9
|
+
path: '/api/d/tiktok', method: 'GET',
|
|
10
|
+
description: 'Download video TikTok tanpa watermark',
|
|
11
|
+
params: [{ name: 'url', required: true, example: 'https://vt.tiktok.com/xxx/', description: 'URL TikTok' }],
|
|
12
|
+
handler: async (req, getInput) => {
|
|
13
|
+
const url = getInput(req, 'url');
|
|
14
|
+
if (!url)
|
|
15
|
+
return { ok: false, status: 400, message: "Parameter 'url' wajib diisi." };
|
|
16
|
+
try {
|
|
17
|
+
const { data } = await axios_1.default.get('https://api.siputzx.my.id/api/d/tiktok', { params: { url }, timeout: 25000 });
|
|
18
|
+
if (!data?.status)
|
|
19
|
+
return { ok: false, status: 502, message: 'Gagal mengunduh.' };
|
|
20
|
+
const videoUrl = data.data?.play || data.data?.wmplay || data.data?.hdplay;
|
|
21
|
+
const caption = data.data?.title || data.data?.desc || 'TikTok Video';
|
|
22
|
+
if (!videoUrl)
|
|
23
|
+
return { ok: false, status: 502, message: 'URL video tidak ditemukan.' };
|
|
24
|
+
return { ok: true, type: 'video', url: videoUrl, caption };
|
|
25
|
+
}
|
|
26
|
+
catch (err) {
|
|
27
|
+
return { ok: false, status: 500, message: err.message };
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|