MCPcopy
hub / github.com/DefiLlama/chainlist / sendDiscordMessage

Function sendDiscordMessage

scripts/build-msg.js:85–96  ·  view source on GitHub ↗
(content)

Source from the content-addressed store, hash-verified

83commitSummary += '\n' + `📸 ${COMMIT_HASH}`
84
85async function sendDiscordMessage(content) {
86 if (!BUILD_STATUS_WEBHOOK) {
87 console.error('BUILD_STATUS_WEBHOOK is not set')
88 return
89 }
90 const body = { content }
91 await fetch(BUILD_STATUS_WEBHOOK, {
92 method: 'POST',
93 body: JSON.stringify(body),
94 headers: { 'Content-Type': 'application/json' }
95 })
96}
97
98const sendMessages = async () => {
99 const message = `\`\`\`\n===== COMMIT SUMMARY =====\n${commitSummary}\n\n===== BUILD SUMMARY =====\n${buildSummary}\n\`\`\``

Callers 1

sendMessagesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected