telvri/security

Official Telvri Security PHP SDK for SIM-swap and mobile identity checks.

1.0.0 2026-07-18 03:12 UTC

This package is auto-updated.

Last update: 2026-07-18 03:21:15 UTC


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

  • CheckSimSwapDto
  • SimSwapResponseDto
  • LoginDto
  • SignupDto

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.