Mega icon

Mega

Work with Mega API

Contact → Search

AI-generated

Summary

Search contacts in Mega by name, identifier, email, or phone number, applying pagination and sorting options.

Inputs

  • Page — Page number for pagination, default is 1.
  • Sort — Sort order for the contact list; options include Email, Last Activity At, Name, and Phone Number, each ascending or descending. Defaults to Name ascending.
  • Query (required) — Search query string to find contacts by name, identifier, email, or phone number.

Output shape

a paginated list of contacts matching the search query

The result returns contacts sorted by the specified criteria and limited to the requested page. Pagination and sorting behavior applies as per input parameters.

Examples

Example 1: Search for contacts whose name or email matches 'john' on page 2, sorted by email descending.

Set Query to 'john', Page to 2, and Sort to 'Email Descending'.

Links

Discussion