PHPackages                             standards/urn - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. standards/urn

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

standards/urn
=============

A simple library to work with Uniform Resource Names (URNs).

v2.0.0(1y ago)09.9k1MITPHPPHP \*

Since Apr 30Pushed 12mo ago1 watchersCompare

[ Source](https://github.com/dependencies-packagist/standards-urn)[ Packagist](https://packagist.org/packages/standards/urn)[ Docs](https://github.com/dependencies-packagist/standards-urn)[ RSS](/packages/standards-urn/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (3)Used By (1)

Uniform Resource Names (URNs)
=============================

[](#uniform-resource-names-urns)

A simple library to work with Uniform Resource Names (URNs) based on the [RFC 8141](https://tools.ietf.org/html/rfc8141).

[![GitHub Tag](https://camo.githubusercontent.com/b218ec2498cf52794d1f04cf9885710014dc05087ad8f8972830c973440d5ff9/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f646570656e64656e636965732d7061636b61676973742f7374616e64617264732d75726e)](https://github.com/dependencies-packagist/standards-urn/tags)[![Total Downloads](https://camo.githubusercontent.com/d2555482aa24d88774fb2d4c541647a03bd889da21c2736d61413e62e52d1738/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7374616e64617264732f75726e3f7374796c653d666c61742d737175617265)](https://packagist.org/packages/standards/urn)[![Packagist Version](https://camo.githubusercontent.com/2ccce82b4c80568ff70889c8bc327714a730cf15a8eaae0168070c67a12f6329/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7374616e64617264732f75726e)](https://packagist.org/packages/standards/urn)[![Packagist PHP Version Support](https://camo.githubusercontent.com/dab4c6c76b30dc721082c0c8e5d6ba1adcc2b35ea5e6afd19dbaa52274519def/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f7374616e64617264732f75726e)](https://github.com/dependencies-packagist/standards-urn)[![Packagist License](https://camo.githubusercontent.com/22f35018be17e771f2045f66fe33bb758966c4b7f13357ddd14e5fddd1f51579/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f646570656e64656e636965732d7061636b61676973742f7374616e64617264732d75726e)](https://github.com/dependencies-packagist/standards-urn)

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

[](#installation)

You can install the package via [Composer](https://getcomposer.org/):

```
composer require standards/urn
```

Usage
-----

[](#usage)

```
use Standards\URN\NamespaceSpecificString;
use Standards\URN\UniformResourceName;

$urn = UniformResourceName::parse('urn:ietf:params:oauth:jwk-thumbprint:sha-256:NzbLsXh8...');
var_dump($urn->getNamespaceIdentifier());     // ietf
var_dump($urn->getNamespaceSpecificString()); // params:oauth:jwk-thumbprint:sha-256:NzbLsXh8...

$nss = NamespaceSpecificString::parse($urn->getNamespaceSpecificString());
var_dump($nss->getNamespace());    // params
var_dump($nss->getSubNamespace()); // oauth
var_dump($nss->getResource());     // jwk-thumbprint
var_dump($nss->getType());         // sha-256
var_dump($nss->getValue());        // NzbLsXh8...

$nss = NamespaceSpecificString::build(
    value: 'NzbLsXh8...'
);
$nss = NamespaceSpecificString::build()->setValue('NzbLsXh8...');
$urn = UniformResourceName::build('ietf', $nss);
var_dump($urn->toString()); // urn:ietf:params:oauth:jwk-thumbprint:sha-256:NzbLsXh8...
```

License
-------

[](#license)

Nacosvel Contracts is made available under the MIT License (MIT). Please see [License File](LICENSE) for more information.

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance49

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

383d ago

Major Versions

v1.0.0 → v2.0.02025-04-30

### Community

Maintainers

![](https://www.gravatar.com/avatar/2da9b458375a1b7972b7c4d26a5bf8f3e48db305e8805da36f253956f33c5568?d=identicon)[jundayw](/maintainers/jundayw)

---

Top Contributors

[![jundayw](https://avatars.githubusercontent.com/u/16873970?v=4)](https://github.com/jundayw "jundayw (3 commits)")

---

Tags

ietfUniform Resource NamesURNs

### Embed Badge

![Health badge](/badges/standards-urn/health.svg)

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

###  Alternatives

[gitonomy/gitlib

Library for accessing git

46418.6M56](/packages/gitonomy-gitlib)[mglaman/composer-drupal-lenient

1317.4M15](/packages/mglaman-composer-drupal-lenient)

PHPackages © 2026

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