mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-17 08:20:58 -05:00
Add webhook for something else in mind.
This commit is contained in:
parent
8fe69d3c5c
commit
1766ab0490
@ -1,4 +1,4 @@
|
|||||||
import Discord, { Client, GatewayIntentBits, Partials } from 'discord.js';
|
import Discord, { Client, WebhookClient, GatewayIntentBits, Partials } from 'discord.js';
|
||||||
import fs from 'node:fs';
|
import fs from 'node:fs';
|
||||||
import timeNames from './timeNames';
|
import timeNames from './timeNames';
|
||||||
import { Punishment, formatTimeOpt, Tokens, Config } from './typings/interfaces';
|
import { Punishment, formatTimeOpt, Tokens, Config } from './typings/interfaces';
|
||||||
@ -187,3 +187,6 @@ export default class TClient extends Client {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export class WClient extends WebhookClient {tokens: Tokens; constructor(){super({url: tokens.webhook_url})}}
|
||||||
|
// hi tae, ik you went to look for secret hello msgs in here too.
|
@ -1,9 +1,9 @@
|
|||||||
import Discord,{SlashCommandBuilder} from 'discord.js';
|
import Discord,{SlashCommandBuilder} from 'discord.js';
|
||||||
import { Octokit } from '@octokit/rest';
|
import {Octokit} from '@octokit/rest';
|
||||||
import {exec} from 'node:child_process';
|
import {exec} from 'node:child_process';
|
||||||
import { readFileSync } from 'node:fs';
|
import {readFileSync} from 'node:fs';
|
||||||
import * as util from 'node:util';
|
import * as util from 'node:util';
|
||||||
import TClient from 'src/client';
|
import TClient from '../client';
|
||||||
import path from 'node:path';
|
import path from 'node:path';
|
||||||
const removeUsername = (text: string)=>{
|
const removeUsername = (text: string)=>{
|
||||||
let matchesLeft = true;
|
let matchesLeft = true;
|
||||||
@ -117,7 +117,6 @@ export default {
|
|||||||
`Name: **${currentActivities[0].name}**`,
|
`Name: **${currentActivities[0].name}**`,
|
||||||
`URL: \`${currentActivities[0].url}\``
|
`URL: \`${currentActivities[0].url}\``
|
||||||
].join('\n'))
|
].join('\n'))
|
||||||
break
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data: new SlashCommandBuilder()
|
data: new SlashCommandBuilder()
|
||||||
|
1
src/typings/interfaces.d.ts
vendored
1
src/typings/interfaces.d.ts
vendored
@ -123,6 +123,7 @@ export interface Tokens {
|
|||||||
token_beta: string
|
token_beta: string
|
||||||
token_toast: string
|
token_toast: string
|
||||||
token_tae: string
|
token_tae: string
|
||||||
|
webhook_url: string
|
||||||
}
|
}
|
||||||
export interface Config {
|
export interface Config {
|
||||||
embedColor: ColorResolvable,
|
embedColor: ColorResolvable,
|
||||||
|
Loading…
Reference in New Issue
Block a user