PHPackages                             remessage/message - 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. remessage/message

ActiveLibrary

remessage/message
=================

Message Standard for networking in Re: Message.

v1.0.0(11mo ago)0912Apache-2.0PHPPHP &gt;=8.4CI passing

Since Jun 14Pushed 10mo ago1 watchersCompare

[ Source](https://github.com/re-message/message)[ Packagist](https://packagist.org/packages/remessage/message)[ Docs](https://dev.remessage.ru/packages/message)[ RSS](/packages/remessage-message/feed)WikiDiscussions release Synced 1mo ago

READMEChangelogDependencies (6)Versions (2)Used By (2)

Message Standard
================

[](#message-standard)

This package defines the rules and formats for communication between clients and servers that are part of [Re: Message](https://remessage.ru).

Standard based on JSON format and created to implement a [JSON-pure API](https://mmikowski.github.io/json-pure/). This package uses the `symfony/serializer` for encoding and decoding JSON.

The `remessage/client` and `remessage/core` based on this standard.

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

[](#requirements)

PHP 8.4+ with these extensions:

1. json
2. mbstring

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

[](#installation)

You will need Composer to install:

`composer require remessage/message`

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

[](#description)

Message is any data sent as part of the server-client interaction. Any message **MUST** have a `type` high level property with the message type (see [Types](#types)).

### Transport

[](#transport)

As a data transmission channel, HTTP or sockets can be used. See [Core documentation](https://dev.remessage.ru/transport) for details.

When using the HTTP protocol, only action, response, error messages can be used.

### Types

[](#types)

There are several types of messages for communication. The main types of messages: action, response and error. These types of messages can be sent and received via any transport.

### Action

[](#action)

The Action message is a message, which is a request to perform some action and return its results as a [Response](#response). Action can be sent only from a client side.

Any action message **MUST** have a `name` and a `parameters` properties. The `name` property contains a name of action (e.g. `auth.sendCode`). The `parameters` property is a list of parameters for action.

Also, Action message can have these optional properties:

- `id` property: a random identifier for the Action message which **MUST** be returned in the [Response](#response) message if the identifier was sent
- `token` property: access token to this action (you can pass the token in [other ways](https://dev.remessage.ru/auth))

Example:

```
{
    "type": "action",
    "name": "auth.sendCode",
    "parameters": {
        "phone": "+79123456789",
        "requestId": "d0f2f571-d07d-4e1d-bdf6-e3470efe9ac5",
        "code": "012345"
    }
}
```

### Response

[](#response)

The Response message is a message returned as the result of the [Action](#action) if the action completed successfully. A message of this type **MUST** have a `content` property, that contains the results of action. Response can be sent only by the Core.

Also, Response message can have these optional properties:

- `id` property: an identifier from the Action message if the identifier was sent

Example:

```
{
    "type": "response",
    "content": {
        "method": "sms",
        "requestId": "b4b12d26-8fd6-4d9f-aa2c-0e56ced951be",
        "expiredAt": 1587075673
    }
}
```

### Error

[](#error)

The Error message is the message returned if an error occurred while performing an action. The error message **MUST** have a `code` and `message` properties. The `code` property is a number code of error. The `message` property is a short description about error. A complete list of errors that may be thrown is available [here](https://dev.remessage.ru/errors). Error can be sent only by the Core.

Example:

```
{
    "type": "error",
    "code": 51,
    "message": "One of the passed parameters is invalid."
}
```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance55

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity53

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

330d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7c247169833cef4170f4431e5e8b28085b03fc8982e2c2a8594604d617e9c57a?d=identicon)[h1karo](/maintainers/h1karo)

---

Top Contributors

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

---

Tags

communicationjsonre-messageremessage

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/remessage-message/health.svg)

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

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M647](/packages/sylius-sylius)[api-platform/core

Build a fully-featured hypermedia or GraphQL API in minutes!

2.6k48.1M235](/packages/api-platform-core)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[liuggio/fastest

Simple parallel testing execution... with some goodies for functional tests.

4825.6M26](/packages/liuggio-fastest)[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6939.5M341](/packages/drupal-core-recommended)

PHPackages © 2026

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