User Signups

The BuddyPress Signups endpoint helps you manage member registrations of your community site.

Note: User registrations must be enabled on your community site to be able to use the following endpoints.

Schema Schema

The schema defines all the fields that exist for a signup object.

id

integer
Unique numeric identifier for the signup.
Read only
Context: viewedit
user_login

string
The login of the new user.
Required
Context: view, edit
user_name (1)

string
The full name of the new user.
Required
Context: viewedit
user_email

string
The email of the new member.
Required
Context: edit
activation_key

string
The signup’s activation key.
Read only
Context: edit
registered

string,
date-time
The registration date for the new member.
Read only
Context: viewedit
date_sent

string,
date-time
The date the activation email was sent to the pending member, in the site’s timezone.
Read only
Context: edit
count_sent

integer
The number of times the activation email was sent to the pending member.
Read only
Context: edit
meta

object
The signup meta information. BuddyPress uses it to store the password hash of the new member. This password hash is never included into the BP REST API responses.
Context: edit
site_name (2)

string
Unique name (slug) of the new member’s child site.
Default: ''
Context: edit
site_title (2)

string
Title of the new member’s child site.
Default: ''
Context: edit
site_public (2)

boolean
Search engine visibility of the new member’s site. true to be visible, false otherwise.
Default: true
Context: edit
site_language (2)

string
Language to use for the new member’s site.
Default: the Network main site’s locale (eg: en_US)
One of: the available locales of the Network.
Context: edit

(1) Only available if the BuddyPress xProfile component is active.
(2) Only available on WordPress Multisite configurations where it is possible to signup with a blog.

Top ↑

List Signups List Signups

Arguments Arguments

NameTypeDescription
contextstringScope under which the request is made; determines fields present in response.
Default: view
One of: view, edit
numberintegerTotal number of signups to return.
Default: 1
offsetintegerOffset the result set by a specific number of items.
Default: 1
includearrayEnsure the result set includes specific Signup IDs.
Default: []
user_loginstringEnsure the result set only returns the signup for a specific pending member login.
Default: ''
orderbystringOrder the result set according to a specific parameter.
Default: signup_id
One of: signup_id, login, email, registered, activated
orderarrayOrder sort type (ascending or descending).
Default: desc
One of: asc, desc

Top ↑

Definition Definition

GET /buddypress/v1/signup

Top ↑

Example of use Example of use

Alert: To use the bp.apiRequest function, you need to enqueue the bp-api-request JavaScript or use it as a dependency of your script. Refer to this page to know more about loading JavaScript files in WordPress.

bp.apiRequest( {
  path: 'buddypress/v1/signup',
  type: 'GET',
  data: {
    context: 'view'
  }
} ).done( function( data ) {
  return data;
} ).fail( function( error ) {
  return error;
} );

Top ↑

Signup a user (with or without a blog) Signup a user (with or without a blog)

Top ↑

Arguments Arguments

NameTypeDescription
user_loginstringA numeric identifier for the new member.
Required
passwordstringPassword for the new member.
Required
user_emailstringThe email address for the new member.
Required
user_name (1)stringFull name for the new member.
Required
site_name (2)stringUnique name (slug) of the new member’s child site.
Default: ''
site_title (2)stringTitle of the new member’s child site.
Default: ''
site_public (2)booleanSearch engine visibility of the new member’s site. true to be visible, false otherwise.
Default: true
site_language (2)stringLanguage to use for the new member’s site.
Default: the Network main site’s locale (eg: en_US)

(1) Only available if the BuddyPress xProfile component is active.
(2) Only available on WordPress Multisite configurations where it is possible to signup with a blog.

Top ↑

Definition Definition

POST /buddypress/v1/signup

Top ↑

Example of use Example of use

Alert: To use the bp.apiRequest function, you need to enqueue the bp-api-request JavaScript or use it as a dependency of your script. Refer to this page to know more about loading JavaScript files in WordPress.

// Example for a simple signup when the BP xProfile component is not active.
bp.apiRequest( {
  path: 'buddypress/v1/signup',
  type: 'POST',
  data: {
    context: 'edit',
    user_login: 'testuser',
    user_email: 'test@user.mail',
    password: 'password' // Always use strong passwords, not like this one!
  }
} ).done( function( data ) {
  return data;
} ).fail( function( error ) {
  return error;
} );

Top ↑

Retrieve a specific Signup Retrieve a specific Signup

Top ↑

Arguments Arguments

NameTypeDescription
idstringUnique identifier for the signup. It can be a signup ID, an email address, or most likely an activation key.
Required
contextstringScope under which the request is made; determines fields present in response.
Default: view
One of: view, edit

Top ↑

Definition Definition

GET /buddypress/v1/signup/<id>

Top ↑

Example of use Example of use

Alert: To use the bp.apiRequest function, you need to enqueue the bp-api-request JavaScript or use it as a dependency of your script. Refer to this page to know more about loading JavaScript files in WordPress.

bp.apiRequest( {
  path: 'buddypress/v1/signup/1f56ce56bf66ef53', // Activation key.
  type: 'GET',
  data: {
    context: 'view'
  }
} ).done( function( data ) {
  return data;
} ).fail( function( error ) {
  return error;
} );

Top ↑

Activate a specific Signup Activate a specific Signup

Top ↑

Arguments Arguments

NameTypeDescription
activation_keystringActivation key of the signup.
Required
contextstringScope under which the request is made; determines fields present in response.
Default: edit
One of: view, edit

Top ↑

Definition Definition

PUT /buddypress/v1/signup/activate/<activation_key>

Top ↑

Example of use Example of use

Alert: To use the bp.apiRequest function, you need to enqueue the bp-api-request JavaScript or use it as a dependency of your script. Refer to this page to know more about loading JavaScript files in WordPress.

bp.apiRequest( {
  path: 'buddypress/v1/signup/activate/1f56ce56bf66ef53',
  type: 'PUT',
  data: {
    context: 'edit'
  }
} ).done( function( data ) {
  return data;
} ).fail( function( error ) {
  return error;
} );

Top ↑

Delete a specific Signup Delete a specific Signup

Top ↑

Arguments Arguments

NameTypeDescription
idstringUnique identifier for the signup. It can be a signup ID, an email address, or most likely an activation key.
Required
contextstringScope under which the request is made; determines fields present in response.
Default: edit
One of: view, edit

Top ↑

Definition Definition

DELETE /buddypress/v1/signup/<id>

Top ↑

Example of use Example of use

Alert: To use the bp.apiRequest function, you need to enqueue the bp-api-request JavaScript or use it as a dependency of your script. Refer to this page to know more about loading JavaScript files in WordPress.

bp.apiRequest( {
  path: 'buddypress/v1/signup/1f56ce56bf66ef53', // Activation key.
  type: 'DELETE',
  data: {
    context: 'edit',
  }
} ).done( function( data ) {
  return data;
} ).fail( function( error ) {
  return error;
} );