Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: WhatsApp with Vonage function #12

Merged
merged 14 commits into from
Jul 30, 2023
Merged

Conversation

loks0n
Copy link
Member

@loks0n loks0n commented Jul 18, 2023

What does this PR do?

Adds a function to auto reply to a WhatsApp message through the Vonage Messages API

Have you read the Contributing Guidelines on issues?

Yes

@Meldiron
Copy link
Contributor

Let's ping Tessa when this gets merged.

Comment on lines 8 to 20
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const staticFolder = path.join(__dirname, '../static');

export default async ({ req, res }) => {
if (
!process.env.VONAGE_API_KEY ||
!process.env.VONAGE_API_SECRET ||
!process.env.VONAGE_API_SIGNATURE_SECRET ||
!process.env.VONAGE_WHATSAPP_NUMBER
) {
throw new Error('Missing environment variables.');
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's use our typical utils.js for those stuff

@Meldiron Meldiron merged commit 47e903b into main Jul 30, 2023
@loks0n loks0n deleted the feat-whatsapp-with-vonage branch October 3, 2023 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants