Login
Getting Started
Authenticate using the Login API to obtain an access token. Include the returned Bearer Token in the Authorization header and provide a unique X-Device-ID with all authenticated requests. All requests must be made over HTTPS and are subject to rate limits.
Base URL: https://insprl.com/api
POST /external/login
Use the Login API to authenticate a SPRL account and generate an access token for accessing Third-Party Integration APIs.
The returned token can be used with browser extensions, WordPress plugins, Make.com, Zapier, mobile applications, and custom integrations to securely interact with SPRL resources.
Request Information
| Method | POST |
| API Endpoint | https://insprl.com/api/external/login |
| Authentication | Public Endpoint |
Header Parameters
| Parameter | Type | Description |
|---|
| X-Device-ID | String | Unique identifier for the integration installation. Used for session validation and security purposes. |
| Content-Type | JSON | application/json |
Request Parameters
| Parameter | Type | Validate | Description |
|---|
| login_id | String | Required | Registered SPRL email address or mobile number. |
| password | String | Required | SPRL account password. |
| otp | String | Optional | Google Authenticator OTP. Required only when two-factor authentication is enabled. |
| source | String | Optional | Integration source such as chrome, firefox, wordpress, make, zapier, mobile or custom. |
Response Parameters
| Parameter | Type | Description |
|---|
| success | Boolean | Request status (true/false). |
| token | String | Authentication token used for future API requests. |
| expires_at | DateTime | Token expiration date and time. |
| user | Object | Authenticated user information. |
| user.id | Integer | Unique SPRL user identifier. |
| user.name | String | User display name. |
Response Codes
| SPRL Code | HTTP Status | Mode | Response Field | Description |
| 100 | 200 | success | data | Request processed successfully. |
| 101 | 401 | failed | message | Authentication failed. Invalid session, token or credentials. |
| 102 | 422 | failed | errors | Parameter validation failed. Check the request fields. |
| 103 | 404 | failed | message | Requested resource was not found. |
| 104 | 403 | failed | message | Access denied or account restricted. |
| 105 | 429 | failed | message | Too many requests. Please retry later. |
| 106 | 500 | failed | message | Unexpected server error. Please try again later. |
Error Flag Reference
| Category | Flag | Type | Description |
| Authentication | INVALID_SESSION | auth_error | The supplied token or device identifier is invalid. |
| Authentication | INVALID_CREDENTIALS | auth_error | Invalid login credentials supplied. |
| Validation | INVALID_PARAMETER | validation_error | One or more request parameters are invalid. |
| Resource | RESOURCE_NOT_FOUND | resource_error | The requested URL, folder, domain or resource could not be found. |
| Account | ACCOUNT_RESTRICTED | account_error | The account is restricted or access has been denied. |
| Rate Limit | RATE_LIMIT_EXCEEDED | rate_limit_exceeded | The request rate limit has been exceeded. |
| Server | UNEXPECTED_ERROR | server_error | An unexpected internal server error occurred. |