PHPackages                             porta/datetime - 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. [API Development](/categories/api)
4. /
5. porta/datetime

ActiveLibrary[API Development](/categories/api)

porta/datetime
==============

PortaOne billing API datetime helper class

0.1.0(2y ago)0731MITPHPPHP ^7.4|^8.0|^8.1|^8.2

Since Jun 4Pushed 2y ago1 watchersCompare

[ Source](https://github.com/portabilling/datetime)[ Packagist](https://packagist.org/packages/porta/datetime)[ Docs](https://github.com/portabilling/datetime)[ RSS](/packages/porta-datetime/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (2)Used By (1)

PortaOne Billing API datetime helper class
==========================================

[](#portaone-billing-api-datetime-helper-class)

Purpose
-------

[](#purpose)

This package intended to simplify datetime and data fields management when work with Portabilling API.

PortaDateTime class exptends standatd DateTimeImmutable class to provide specific methods. All the datatime fields of API has MySQL format and always UTC timezone. This helper class allows easy manipulation between billing UTC datetime strings and desired-timezone DateTime-like objects, unlocking the full power of DateTie class in your biling-related application.

It also support PSR-4 autoload to root namespace () and PSR-11 DI containers for default timezone definition storage.

Usage
-----

[](#usage)

I suppose you should be familiar with PortaOne billing API. Start with [example](https://github.com/portabilling/datetime/blob/master/examples/UsageExample.php), browse [PHPdoc](https://portabilling.github.io/datetime/). Use sources to understand how it works, it is very simple.

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

[](#installation)

In the Composer storage. Just add proper require section:

```
"require": {
    "porta/datetime": "^0.1"
}

```

Please, review [changelog](https://github.com/portabilling/datetime/blob/master/CHANGELOG.MD) before to change used version.

Dependencies
------------

[](#dependencies)

- php: ^7.4|^8.0|^8.1|^8.2
- psr/container: "\*"

Testing
-------

[](#testing)

Tested with PHPUnit 9.6 on php 7.4 to 8.2, 100% coverage, which does not mean everything will work as intended. Current testing and compatibility status check on [Github flows](https://github.com/portabilling/datetime/actions/workflows/Compatibility.yml)

To test, install in dev mode and use:

- `composer test` command from library root for run all standard modular tests

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

1078d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/51fb7e1bfe1a741b842ccaffe58a95229f1afa531676dff7d14e61cda27a9ae7?d=identicon)[pavlyuts](/maintainers/pavlyuts)

---

Top Contributors

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

---

Tags

api-clientbillingphpportaoneportastartapibillingportaoneportastart

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/porta-datetime/health.svg)

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

###  Alternatives

[maksekeskus/maksekeskus-php

Maksekeskus PHP SDK

12179.8k](/packages/maksekeskus-maksekeskus-php)[invoiced/invoiced

Invoiced PHP Library

14117.1k](/packages/invoiced-invoiced)[rubix/server

Deploy your Rubix ML models to production with scalable stand-alone inference servers.

632.3k](/packages/rubix-server)

PHPackages © 2026

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