PHPackages                             wiatrogon/allegro-rest-api - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. wiatrogon/allegro-rest-api

ActiveLibrary[HTTP &amp; Networking](/categories/http)

wiatrogon/allegro-rest-api
==========================

simple interface for Allegro REST API

0.0.7(7y ago)1812.6k↓50%19[3 issues](https://github.com/Wiatrogon/php-allegro-rest-api/issues)[3 PRs](https://github.com/Wiatrogon/php-allegro-rest-api/pulls)MITPHPPHP &gt;=5.3

Since Nov 10Pushed 7y ago8 watchersCompare

[ Source](https://github.com/Wiatrogon/php-allegro-rest-api)[ Packagist](https://packagist.org/packages/wiatrogon/allegro-rest-api)[ RSS](/packages/wiatrogon-allegro-rest-api/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (1)Versions (9)Used By (0)

php-allegro-rest-api
====================

[](#php-allegro-rest-api)

Simple interface for Allegro REST API resources

Authorization and Tokens
------------------------

[](#authorization-and-tokens)

In order to use Allegro REST Api, you have to register your application and authorize it ().

### Authorization link

[](#authorization-link)

```
$api = new Api($clientId, $clientSecret, $apiKey, $redirectUri, null, null);
echo $api->getAuthorizationUri();
```

### Getting new token

[](#getting-new-token)

```
# example contents of your_redirect_uri.com/index.php
$code = $_GET['code'];
$api = new Api($clientId, $clientSecret, $apiKey, $redirectUri, null, null);
$response = $api->getNewAccessToken($code);
# response contains json with your access_token and refresh_token
```

### Refreshing existing token

[](#refreshing-existing-token)

```
$api = new Api($clientId, $clientSecret, $apiKey, $redirectUri, $accessToken, $refreshToken);
$response = $api->refreshAccessToken();
# response contains json with your new access_token and refresh_token
```

Example usage
-------------

[](#example-usage)

```
$api = new Api($clientId, $clientSecret, $apiKey, $redirectUri, $accessToken, $refreshToken);

// GET https://allegroapi.io/{resource}
// $api->{resource}->get();

// GET https://allegroapi.io/categories
$api->categories->get();

// GET https://allegroapi.io/{resource}/{resource_id}
// $api->{resource}({resource_id})->get();

// GET https://allegroapi.io/categories/2
$api->categories(2)->get();

// PUT https://allegroapi.io/{resource}/{resource_id}/{command-name}-command/{uuid}
// $api->{resource}({resource_id})->commands()->{command_name}($data);

// PUT https://allegroapi.io/offers/12345/change-price-commands/84c16171-233a-42de-8115-1f1235c8bc0f
$api->offers(12345)->commands()->change_price($data);
```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity36

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 86.7% 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 ~78 days

Recently: every ~130 days

Total

8

Last Release

2917d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/11462938?v=4)[wiatrogon](/maintainers/wiatrogon)[@Wiatrogon](https://github.com/Wiatrogon)

---

Top Contributors

[![Wiatrogon](https://avatars.githubusercontent.com/u/11462938?v=4)](https://github.com/Wiatrogon "Wiatrogon (26 commits)")[![serten-d](https://avatars.githubusercontent.com/u/36070617?v=4)](https://github.com/serten-d "serten-d (3 commits)")[![marcinc81](https://avatars.githubusercontent.com/u/900272?v=4)](https://github.com/marcinc81 "marcinc81 (1 commits)")

---

Tags

restallegro

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/wiatrogon-allegro-rest-api/health.svg)

```
[![Health](https://phpackages.com/badges/wiatrogon-allegro-rest-api/health.svg)](https://phpackages.com/packages/wiatrogon-allegro-rest-api)
```

###  Alternatives

[zircote/swagger-php

Generate interactive documentation for your RESTful API using PHP attributes (preferred) or PHPDoc annotations

5.3k132.9M468](/packages/zircote-swagger-php)[psr/link

Common interfaces for HTTP links

2.5k144.1M69](/packages/psr-link)[league/fractal

Handle the output of complex data structures ready for API output.

3.5k64.1M476](/packages/league-fractal)[friendsofsymfony/rest-bundle

This Bundle provides various tools to rapidly develop RESTful API's with Symfony

2.8k73.3M319](/packages/friendsofsymfony-rest-bundle)[lexik/jwt-authentication-bundle

This bundle provides JWT authentication for your Symfony REST API

2.6k58.7M210](/packages/lexik-jwt-authentication-bundle)[nelmio/api-doc-bundle

Generates documentation for your REST API from attributes

2.3k63.6M233](/packages/nelmio-api-doc-bundle)

PHPackages © 2026

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