PHPackages                             vendasta/sso - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. vendasta/sso

ActiveLibrary

vendasta/sso
============

Vendasta SSO library for PHP

v0.0.10(8y ago)4123[1 issues](https://github.com/vendasta/sso-php-sdk/issues)PHP

Since Mar 23Pushed 3y ago22 watchersCompare

[ Source](https://github.com/vendasta/sso-php-sdk)[ Packagist](https://packagist.org/packages/vendasta/sso)[ RSS](/packages/vendasta-sso/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (4)Versions (11)Used By (0)

vendasta/sso
============

[](#vendastasso)

Description
-----------

[](#description)

This is Vendasta's official PHP SDK for integrating SSO. Both Identity Provider and Service Provider interfaces are provided through this SDK.

Requirements
------------

[](#requirements)

- PHP 5.5 and above or PHP 7.0 and above
- [PECL](https://pecl.php.net/) (may be used to install the required PHP extensions)
- [Composer](https://getcomposer.org/)
- [PHP gmp extension](http://php.net/manual/en/book.gmp.php)
- OPTIONAL (but recommended): [PHP grpc extension](https://cloud.google.com/php/grpc)

Installation
------------

[](#installation)

Install the requirements from above, then:

```
composer require vendasta/sso
```

Authentication
--------------

[](#authentication)

To authenticate your SDK calls, you must provision a service account from within the Vendasta platform.

*This feature is currently in alpha, therefore your service account credentials file will be provided to you manually.*

You must put this file on your server, and set an environment variable to it's path:

```
export VENDASTA_APPLICATION_CREDENTIALS=
```

Client Initialization
---------------------

[](#client-initialization)

It is highly recommended that you use a singleton client instance. Each client initilization will open it's own connection, therefore using a singleton results in reusing a connection, saving time and resources.

To instantiate the client:

```
// Uncomment to use the sandbox environment, as setup for you by Vendasta
// $hostname = 'sso-api-demo.vendasta-internal.com';
// $scope = 'https://sso-api-demo.vendasta-internal.com';

// Production
$hostname = 'sso-api-prod.vendasta-internal.com';
$scope = 'https://sso-api-prod.vendasta-internal.com';

// Reuse this instance for all of your SDK calls
$client = new Vendasta\Sso\V1\IdentityProviderClient($hostname, $scope); // For Identity Providers
// $client = new Vendasta\Sso\V1\ServiceProviderClient($hostname, $scope); // For Service Providers
```

Next Steps
----------

[](#next-steps)

At this point, your usage depends on whether you are using this SDK as an Identity Provider or a Service Provider. Identity Providers are applications which replace the Vendasta login screens, and provide the identity verification of users. Service Providers are applications that provide functionality for users, such as [Marketplace](https://www.vendasta.com/marketplace) applications.

Identity Provider
-----------------

[](#identity-provider)

As an identity provider, the functions in this SDK are provided to faciliate the login/logout SSO flow.

See the functions in `Vendasta\Sso\V1\IdentityProviderClient` for more information.

Service Provider
----------------

[](#service-provider)

As a service provider, the functions in this SDK are provided to initiate a session transfer from the identity provider, which is known as *service provider initiated SSO*.

*Service provider functionality is currently not yet implemented in this SDK. If you are a service provider and you want to use this SDK, please talk to your Vendasta representative about having it added*.

Understanding Service Provider ID's and Service Context
-------------------------------------------------------

[](#understanding-service-provider-ids-and-service-context)

The `Service Provider ID` is assigned by Vendasta, which is simply a unique identifier for describing a service. For example, `RM` is the service provider ID assigned to Reputation Management. Marketplace applications typically have a service provider ID that starts with `MP-`. *TODO: Add a function to this RPC to list service provider IDs.*

The `Service Context` is a little bit harder to explain, but the concept is simple - the service context describes the resource that the user is attempting to access through the SSO process. A resource could be an account (business), a partner (typically represents screens that are not tied to a single account, such as a user profile screen), or several others. Unless your SSO configuration is setup for just-in-time identity and access management, you will not typically need to care about the service context - access checks will happen after the SSO process is completed, you simply have to pass the context through.

However, if you are using JiT IAM, you *must* parse the service context and do access checks as a part of your SSO flow.

*TODO: Link to a more in depth article on service context instructions.*

Development Notes
-----------------

[](#development-notes)

### Tests

[](#tests)

To run the integration test suite, you must first set your credentials environment variable, then you can run phpunit directly from the vendor folder:

```
export VENDASTA_APPLICATION_CREDENTIALS=
./vendor/bin/phpunit --bootstrap vendor/autoload.php test
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance15

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 88.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~6 days

Total

9

Last Release

2928d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1498d6f30e570d34309cfb7c848cb3b80d0eca6bd8e28af9d5db3f4196b300bb?d=identicon)[vendasta](/maintainers/vendasta)

---

Top Contributors

[![brentyates](https://avatars.githubusercontent.com/u/2278954?v=4)](https://github.com/brentyates "brentyates (15 commits)")[![avadan1](https://avatars.githubusercontent.com/u/83599192?v=4)](https://github.com/avadan1 "avadan1 (1 commits)")[![dhopkins-va](https://avatars.githubusercontent.com/u/2280661?v=4)](https://github.com/dhopkins-va "dhopkins-va (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/vendasta-sso/health.svg)

```
[![Health](https://phpackages.com/badges/vendasta-sso/health.svg)](https://phpackages.com/packages/vendasta-sso)
```

###  Alternatives

[neuron-core/neuron-ai

The PHP Agentic Framework.

1.8k245.3k21](/packages/neuron-core-neuron-ai)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3731.2M42](/packages/tencentcloud-tencentcloud-sdk-php)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
