Authentication
Sign in with email and password
Authenticates a user and returns a session token. If MFA is enabled, returns MFA challenge info. Use the optional “role” parameter to specify login type - “user” for regular users, “organization” for enterprise accounts.
POST
/
v1
/
auth
/
signin
Sign in with email and password
curl --request POST \
--url https://api.hyperprop.com/platform/v1/auth/signin \
--header 'Content-Type: application/json' \
--data '
{
"email": "user@example.com",
"password": "SecurePass123!",
"role": "user"
}
'import requests
url = "https://api.hyperprop.com/platform/v1/auth/signin"
payload = {
"email": "user@example.com",
"password": "SecurePass123!",
"role": "user"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({email: 'user@example.com', password: 'SecurePass123!', role: 'user'})
};
fetch('https://api.hyperprop.com/platform/v1/auth/signin', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hyperprop.com/platform/v1/auth/signin",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'user@example.com',
'password' => 'SecurePass123!',
'role' => 'user'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.hyperprop.com/platform/v1/auth/signin"
payload := strings.NewReader("{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.hyperprop.com/platform/v1/auth/signin")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hyperprop.com/platform/v1/auth/signin")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"message": "Signed in successfully",
"code": "MFA_REQUIRED",
"data": {
"mfaRequired": false,
"factors": [
{
"id": "factor-550e8400-e29b-41d4-a716-446655440000",
"friendlyName": "Authenticator App"
}
],
"session": {
"user_id": "550e8400-e29b-41d4-a716-446655440000",
"email": "user@example.com",
"session_id": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"refresh_token": "v1.MRjMN...",
"expires_at": 1772643600,
"expires_in": 3600
},
"role": "user",
"organization": {
"id": "org-550e8400-e29b-41d4-a716-446655440000",
"status": "active",
"name": "Acme Corporation",
"description": "Leading provider of enterprise solutions",
"contactEmail": "contact@acme.com",
"websiteUrl": "https://acme.com",
"logoUrl": "https://storage.example.com/logos/acme-logo.png"
},
"teamRole": "admin"
}
}{
"statusCode": 401,
"error": "Unauthorized",
"message": "Invalid email or password",
"code": "INVALID_CREDENTIALS"
}{
"statusCode": 403,
"error": "Forbidden",
"message": "This account is not registered as an organization account",
"code": "ROLE_MISMATCH"
}{
"statusCode": 429,
"error": "Too Many Requests",
"message": "Too many failed sign-in attempts. Try again in 12 minute(s).",
"code": "TOO_MANY_ATTEMPTS"
}{
"success": false,
"statusCode": 500,
"error": "Internal Server Error",
"message": "An unexpected error occurred",
"code": "INTERNAL_ERROR"
}Body
application/json
Related topics
Request password reset emailSign up a new userAdd a team member with a roleVerify an OAuth session (Google sign-in)Rebind a customer to a new Hyperprop login (support flow)⌘I
Sign in with email and password
curl --request POST \
--url https://api.hyperprop.com/platform/v1/auth/signin \
--header 'Content-Type: application/json' \
--data '
{
"email": "user@example.com",
"password": "SecurePass123!",
"role": "user"
}
'import requests
url = "https://api.hyperprop.com/platform/v1/auth/signin"
payload = {
"email": "user@example.com",
"password": "SecurePass123!",
"role": "user"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({email: 'user@example.com', password: 'SecurePass123!', role: 'user'})
};
fetch('https://api.hyperprop.com/platform/v1/auth/signin', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hyperprop.com/platform/v1/auth/signin",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'user@example.com',
'password' => 'SecurePass123!',
'role' => 'user'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.hyperprop.com/platform/v1/auth/signin"
payload := strings.NewReader("{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.hyperprop.com/platform/v1/auth/signin")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hyperprop.com/platform/v1/auth/signin")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"user@example.com\",\n \"password\": \"SecurePass123!\",\n \"role\": \"user\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"message": "Signed in successfully",
"code": "MFA_REQUIRED",
"data": {
"mfaRequired": false,
"factors": [
{
"id": "factor-550e8400-e29b-41d4-a716-446655440000",
"friendlyName": "Authenticator App"
}
],
"session": {
"user_id": "550e8400-e29b-41d4-a716-446655440000",
"email": "user@example.com",
"session_id": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"refresh_token": "v1.MRjMN...",
"expires_at": 1772643600,
"expires_in": 3600
},
"role": "user",
"organization": {
"id": "org-550e8400-e29b-41d4-a716-446655440000",
"status": "active",
"name": "Acme Corporation",
"description": "Leading provider of enterprise solutions",
"contactEmail": "contact@acme.com",
"websiteUrl": "https://acme.com",
"logoUrl": "https://storage.example.com/logos/acme-logo.png"
},
"teamRole": "admin"
}
}{
"statusCode": 401,
"error": "Unauthorized",
"message": "Invalid email or password",
"code": "INVALID_CREDENTIALS"
}{
"statusCode": 403,
"error": "Forbidden",
"message": "This account is not registered as an organization account",
"code": "ROLE_MISMATCH"
}{
"statusCode": 429,
"error": "Too Many Requests",
"message": "Too many failed sign-in attempts. Try again in 12 minute(s).",
"code": "TOO_MANY_ATTEMPTS"
}{
"success": false,
"statusCode": 500,
"error": "Internal Server Error",
"message": "An unexpected error occurred",
"code": "INTERNAL_ERROR"
}