M API

From docs
Revision as of 07:13, 15 July 2026 by Ashley DeBon (talk | contribs) (Created page with "== User Login == === Base URL === https://apimobile.callproof.com === Endpoint === /api/login === Purpose === Authenticates a registered user, verifies that the user and co...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

User Login

Base URL

https://apimobile.callproof.com

Endpoint

/api/login

Purpose

Authenticates a registered user, verifies that the user and company accounts are active, and provides access credentials for authorized CallProof services. The request may also include mobile-device information used for notifications, device recognition, and account preferences.

HTTP Method

POST

Headers

Header Required Description
Content-Type Yes application/x-www-form-urlencoded

Security

  • No – No prior authentication is required. Valid user credentials must be supplied in the request body.

Parameters

Request Body Fields

Parameter Type Required Description
email string Yes The user's registered email address. Email matching is case-insensitive.
password string Yes The user's account password.
device_id_app string No The mobile device notification token used to associate the device with the user's account.
device_type string No The mobile device platform. Recognized values are android and ios.
device_phone_number string No The phone number associated with the mobile device.
device_time_zone string No The device's time zone. When omitted, a time zone may be determined automatically.
cp_version string No The installed CallProof application version.
product string No The device product or model identifier.
resolution string No The device screen resolution.
device_name string No The user-visible device name.
is_tablet boolean No Indicates whether the device is a tablet.
android_version string No The Android operating-system version.
android_api_version string No The Android API version.
android_apk_version string No The installed Android application package version.
is_callLog_build boolean No Indicates whether the Android application supports call-log capabilities.
ios_version string No The iOS operating-system version.

Successful Response (200)

The user was authenticated successfully and receives access credentials together with two-factor authentication status information.

Response Field Type Description
clientStatusCode integer Business-level response status. A successful login returns 200.
data.token_type string The authentication token type.
data.expires_in integer The access token validity period.
data.access_token string The credential used to access authenticated API endpoints.
data.refresh_token string The credential used to obtain a new access token.
data.is_2fa_enabled boolean Indicates whether two-factor authentication is enabled for the user or company.
data.is_verified boolean Indicates whether the applicable two-factor authentication requirement has been satisfied.
data.email string The authenticated user's email address.
uri string The URL of the login request.

Error Responses

Authentication-related failures are returned with HTTP status 200, while clientStatusCode in the response body is set to 401.

HTTP Status Code Client Status Code Meaning
200 401 The email and password combination is invalid.
200 401 The user account or associated company account is disabled.
200 401 The account is not eligible for this type of access and must be updated through CallProof Support.

Error Response Fields

Response Field Type Description
clientStatusCode integer The business-level error status. Authentication failures return 401.
error.code integer The business error code. Authentication failures generally return 1500.
error.message string A plain-language explanation of the login failure.
uri string The URL of the login request.