Skip to content

BuddyPress Automations

Send an Email When a BuddyPress Friendship Request Is Sent

Friendships are how members of a BuddyPress community connect, but a request is easy to miss. Zapify can nudge the member who received it with an email in your own words, using the A user sends a friendship request trigger and the Send an email action.

What this automation does

The automation is one trigger plus one action:

  • Trigger: A user sends a friendship request (BP_FRIENDSHIP_REQUESTED, BuddyPress)
  • Action: Send an email (WP_SEND_EMAIL, WordPress)

When a member sends a friendship request, Zapify emails the member who received it.

Two people are involved, so it helps to know who is who. The automation runs for the member who sent the request, so the usual user tokens (such as Display name) describe the sender. The member who received it is described by the Friend tokens.

Before you start

  • BuddyPress must be installed and active, with the Friend Connections component switched on in your BuddyPress settings. Zapify's BuddyPress integration is not available on sites running BuddyBoss Platform.

Check what members already receive

BuddyPress can send its own notification for community events such as friendship requests, depending on your settings and each member's preferences. Look at what your members already get before adding another email, so nobody receives two messages for the same thing. This automation is most useful when you want your own wording and branding, or when you want to notify someone else, such as a community manager.

How to build the automation

Step 1: Create a new automation

  1. In the WordPress admin, go to Zapify → Automations.
  2. Click Add New to open the builder.
  3. Name it clearly, such as Notify member of friend request.

Create a new automation

Step 2: Add the "A user sends a friendship request" trigger

  1. Click Add Trigger.
  2. Choose BuddyPress as the app.
  3. Select the trigger A user sends a friendship request.

This trigger has no settings to fill in.

Add a trigger

Select BuddyPress as the trigger

Select A user sends a friendship request

Step 3: Add the "Send an email" action

  1. Click Add Action.
  2. Choose WordPress as the app.
  3. Select Send an email.

Add an action

Select WordPress as the action

Select Send an email

Step 4: Address the email to the member who received the request

In the To field, click the {} token button and insert the Friend email token. That is the member the request was sent to.

Select the email recipient

Field Required What it does
To Yes Insert the Friend email token to reach the member who received the request.
Subject Yes The subject line. Tokens are allowed.
Format Yes HTML (default) or Plain text.
Body Yes The message. Tokens are allowed.
Cc / Bcc No Extra recipients.
From name / From email No Override the sender.
Reply to No Where replies go.

For example:

  • To: the Friend email token
  • Subject: {Display name} wants to connect with you
  • Body: Hi {Friend first name}, {Display name} has sent you a friendship request. Log in to accept it.

Complete the Send an Email Action

Step 5: Set the steps Live and save

  1. Set both the trigger and the action to Live. A new automation starts as Draft and will not run until its steps are Live.
  2. Click Save.

Set the automation live

Tokens you can use

The Friend tokens describe the member the request was sent to.

Token What it holds
Friendship ID The numeric ID of the friendship record.
Friend ID The member's numeric ID.
Friend name The member's display name.
Friend email The member's email address.
Friend first name / Friend last name The member's name fields.
Friend profile URL The link to the member's profile.

The member who sent the request is available as the usual user tokens, such as Display name, User email, First name and Last name.

How to test it

  1. Log in as one test member and send a friendship request to a second test member.
  2. Check the second member's inbox for your email.
  3. If nothing arrives, open Zapify → Logs to see whether the run fired.

Conclusion

With the A user sends a friendship request trigger and the Send an email action, Zapify makes sure friendship requests get noticed, in your own voice, on the free plan. Next, reward connections with add a role to both members when a friendship is accepted.

FAQs

Who does the email go to?

To whoever you put in To. With the Friend email token it goes to the member who received the request. With a fixed address it goes to that person, such as your community manager.

Which tokens describe the person who sent the request?

The usual user tokens: Display name, User email, First name, Last name and the rest. The Friend tokens always describe the other member, the one who received the request.

Is this feature free?

Yes. BuddyPress is a free Zapify integration, and both the A user sends a friendship request trigger and the Send an email action are included in the free plan.

Why didn't the email send?

First confirm both the trigger and the action are set to Live and the automation is saved. Then check Zapify → Logs. If the run succeeded but no email arrived, the cause is usually the site's mail configuration; an SMTP plugin resolves most delivery problems.

Do I need to write any code?

No. Everything is configured in the Zapify visual builder.

Was this page helpful?