feat: 添加发送消息的API密钥
This commit is contained in:
parent
bcc0eb0fd7
commit
f66bf4b39c
@ -1,5 +1,7 @@
|
|||||||
import netTool from "./netTool";
|
import netTool from "./netTool";
|
||||||
|
|
||||||
|
const API_KEY = "1dfz4wlpbbgiky0";
|
||||||
|
|
||||||
const sendMessage = async (body: any) => {
|
const sendMessage = async (body: any) => {
|
||||||
const URL = "https://egg.imoaix.cn/message";
|
const URL = "https://egg.imoaix.cn/message";
|
||||||
try {
|
try {
|
||||||
@ -12,6 +14,7 @@ const sendMessage = async (body: any) => {
|
|||||||
|
|
||||||
sendMessage.byGroupId = async (group_id: string, content: string) => {
|
sendMessage.byGroupId = async (group_id: string, content: string) => {
|
||||||
return sendMessage({
|
return sendMessage({
|
||||||
|
api_key: API_KEY,
|
||||||
group_id,
|
group_id,
|
||||||
msg_type: "interactive",
|
msg_type: "interactive",
|
||||||
content,
|
content,
|
||||||
@ -20,6 +23,7 @@ sendMessage.byGroupId = async (group_id: string, content: string) => {
|
|||||||
|
|
||||||
sendMessage.byChatId = async (chat_id: string, content: string) => {
|
sendMessage.byChatId = async (chat_id: string, content: string) => {
|
||||||
return sendMessage({
|
return sendMessage({
|
||||||
|
api_key: API_KEY,
|
||||||
receive_id: chat_id,
|
receive_id: chat_id,
|
||||||
receive_id_type: "chat_id",
|
receive_id_type: "chat_id",
|
||||||
msg_type: "interactive",
|
msg_type: "interactive",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user