telvri / security
Official Telvri Security PHP SDK for SIM-swap and mobile identity checks.
1.0.0
2026-07-18 03:12 UTC
Requires
- php: ^8.1
- ext-curl: *
- ext-json: *
- ext-mbstring: *
- guzzlehttp/guzzle: ^7.3
- guzzlehttp/psr7: ^1.7 || ^2.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.5
- phpunit/phpunit: ^8.0 || ^9.0
README
Official PHP SDK for the Telvri Security API — real-time SIM-swap and mobile identity risk checks for login recovery, payouts, and wallet protection.
Install
From GitHub (works now)
composer config repositories.telvri vcs https://github.com/Granville-Christopher/telvri-php composer require telvri/security:^1.0.0
Or in your composer.json:
{
"repositories": [
{
"type": "vcs",
"url": "https://github.com/Granville-Christopher/telvri-php"
}
],
"require": {
"telvri/security": "^1.0.0"
}
}
Requires PHP 8.1+.
Packagist (after registration)
Once the package is on Packagist, you can use:
composer require telvri/security
Quick start — SIM-swap check
<?php require_once __DIR__ . '/vendor/autoload.php'; use Telvri\Security\Configuration; use Telvri\Security\Api\SIMSwapIntelligenceApi; use Telvri\Security\Model\CheckSimSwapDto; $config = Configuration::getDefaultConfiguration() ->setApiKey('X-API-Key', getenv('TELVRI_API_KEY')); $api = new SIMSwapIntelligenceApi(null, $config); $dto = (new CheckSimSwapDto()) ->setPhoneNumber('+2348031234569') ->setMaxAgeHours(24); $result = $api->simSwapControllerCheckSimSwap($dto); echo sprintf( "swapped=%s provider=%s operator=%s\n", $result->getSwapped() ? 'true' : 'false', $result->getProvider(), $result->getOperator() );
Set your key first:
export TELVRI_API_KEY=rt_live_your_api_key
API reference
All URIs are relative to https://telvrisecurity.vercel.app.
| Class | Method | HTTP request | Description |
|---|---|---|---|
SIMSwapIntelligenceApi |
simSwapControllerCheckSimSwap |
POST /v1/security/sim-check |
Run a real-time SIM-swap risk check |
DeveloperAuthApi |
authControllerLogin |
POST /auth/login |
Authenticate a developer account |
DeveloperAuthApi |
authControllerSignup |
POST /auth/signup |
Create a developer account |
Models
CheckSimSwapDtoSimSwapResponseDtoLoginDtoSignupDto
Full per-method and per-model docs are in the docs/ folder.
Development
This SDK is generated from the Telvri Security OpenAPI contract using OpenAPI Generator. To regenerate from the API project:
npm run sdk:fetch-spec npm run sdk:generate:php
- API version:
1.0 - Package version:
1.0.0 - Composer package:
telvri/security - Namespace:
Telvri\Security
License
MIT — see LICENSE.