PHPackages                             farapayamak/php - 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. farapayamak/php

ActiveLibrary[API Development](/categories/api)

farapayamak/php
===============

Farapayamak webservice wrapper for PHP language

1.2.0(2y ago)28061MITPHPPHP &gt;=5.3.0

Since Feb 25Pushed 2y agoCompare

[ Source](https://github.com/Farapayamak/PHP)[ Packagist](https://packagist.org/packages/farapayamak/php)[ RSS](/packages/farapayamak-php/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

Farapayamak PHP
===============

[](#farapayamak-php)

Introduction
------------

[](#introduction)

Here we've provided a complete 3rd-party library (SDK) for PHP developers that covers both **SOAP** and **REST** webservices. Before using, make sure you have provided a [valid account in Farapayamak corporation](https://farapayamak.ir/start/).

### معرفی

[](#معرفی)

فراپیامک مجموعۀ کامل از متدهای اتصال به وب سرویس **REST** و **SOAP** این شرکت را برای توسعه دهندگان PHP فراهم نموده. قبل از استفاده از این کتابخانه، نیاز به [خرید پنل فراپیامک](https://farapayamak.ir/start/) دارید

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

[](#installation)

You can run the following **composer** command to have it:

```
composer require farapayamak/php:1.2.0

```

Usage
-----

[](#usage)

This is the simple usage for both REST and SOAP APIs:

```
$restClient = new Rest_Client('username', 'password');
print_r($restClient->SendSMS('09123456789', '5000xxx', 'test sms', false));

$soapClient = new Soap_Client('username', 'password');
print_r($soapClient->SendSimpleSMS2('09123456789', '5000xxx', 'test sms', false));
```

Further demonstrations can be found inside the *rest-sample.php* and *soap-sample.php* files.

REST or SOAP?
-------------

[](#rest-or-soap)

We support a small number of methods in REST against the SOAP web service that supports the entire ones.

REST Methods
------------

[](#rest-methods)

We're currently supporting the following methods in REST web service:

```
$restClient->SendSMS($to, $from, $text, $isFlash);
$restClient->GetDeliveries2($recId);
$restClient->GetMessages($location, $from, $index, $count);
$restClient->GetCredit();
$restClient->GetBasePrice();
$restClient->GetUserNumbers();
$restClient->BaseServiceNumber($text, $to, $bodyId);
$restClient->SendSmartSMS($to, $text, $from, $fromSupportOne, $fromSupportTwo);
$restClient->SendMultipleSmartSMS($to, $text, $from, $fromSupportOne, $fromSupportTwo);
$restClient->GetSmartSMSDeliveries2($id);
$restClient->GetSmartSMSDeliveries($ids);
```

SOAP Methods
------------

[](#soap-methods)

We support a wide range of methods in SOAP web service. They're scope separated. Let's review all the SOAP web service methods.

### Send Web Service

[](#send-web-service)

```
$soapClient->GetCredit();
$soapClient->GetDeliveries($recIds);
$soapClient->GetDeliveries3($recId);
$soapClient->GetSmsPrice($irancellCount, $mtnCount, $from, $text);
$soapClient->SendByBaseNumber($text, $to, $bodyId);
$soapClient->SendByBaseNumber2($text, $to, $bodyId);
$soapClient->SendByBaseNumber3($text, $to);
$soapClient->SendSimpleSMS($to, $from, $text, $isflash);
$soapClient->SendSimpleSMS2($to, $from, $text, $isflash);
$soapClient->SendSms($to, $from, $text, $isflash, $udh, $recId);
$soapClient->SendSms2($to, $from, $text, $isflash, $udh, $recId, $status, $filterId);
$soapClient->SendMultipleSMS($to, $from, $text, $isflash, $udh, $recId);
$soapClient->SendMultipleSMS2($to, $from, $text, $isflash, $udh, $recId);
```

### Receive Web Service

[](#receive-web-service)

```
$soapClient->ChangeMessageIsRead($msgIds);
$soapClient->GetInboxCount();
$soapClient->GetLatestReceiveMsg($sender, $receiver);
$soapClient->GetMessages($location, $from, $index, $count);
$soapClient->GetMessagesAfterID($location, $from, $count, $msgId);
$soapClient->GetMessagesFilterByDate($location, $from, $index, $count, $dateFrom, $dateTo, $isRead);
$soapClient->GetMessagesReceptions($msgId, $fromRows);
$soapClient->GetMessagesWithChangeIsRead($location, $from, $index, $count, $isRead, $changeIsRead);
$soapClient->GetOutBoxCount();
$soapClient->RemoveMessages($location, $msgIds);
```

### User Web Service

[](#user-web-service)

```
$soapClient->AddUser($productId, $descriptions, $mobileNumber, $emailAddress, $nationalCode,
        $name, $family, $corporation, $phone, $fax, $address, $postalCode, $certificateNumber);
$soapClient->AddUserWithLocation($productId, $descriptions, $mobileNumber, $emailAddress, $nationalCode,
    $name, $family, $corporation, $phone, $fax, $address, $postalCode, $certificateNumber, $country, $province, $city);
$soapClient->AddUserWithMobileNumber($productId, $mobileNumber, $firstName, $lastName, $email);
$soapClient->AddUserWithMobileNumber2($productId, $mobileNumber, $firstName, $lastName, $userName, $email);
$soapClient->AddUserWithUserNameAndPass($productId, $descriptions, $mobileNumber, $emailAddress, $nationalCode,
    $name, $family, $corporation, $phone, $fax, $address, $postalCode, $certificateNumber, $targetUserName, $targetUserPassword);
$soapClient->AuthenticateUser();
$soapClient->ChangeUserCredit($amount, $description, $targetUsername, $GetTax);
$soapClient->DeductUserCredit($amount, $description);
$soapClient->ForgotPassword($mobileNumber, $emailAddress, $targetUsername);
$soapClient->GetCities($provinceId);
$soapClient->GetEnExpireDate();
$soapClient->GetExpireDate();
$soapClient->GetProvinces();
$soapClient->GetUserBasePrice($targetUsername);
$soapClient->GetUserCredit($targetUsername);
$soapClient->GetUserCredit2();
$soapClient->GetUserDetails($targetUsername);
$soapClient->GetUserIsExist($targetUsername);
$soapClient->GetUserNumbers();
$soapClient->GetUserTransactions($targetUsername, $creditType, $dateFrom, $dateTo, $keyword);
$soapClient->GetUserWallet();
$soapClient->GetUserWalletTransaction($dateFrom, $dateTo, $count, $startIndex, $payType, $payLoc);
$soapClient->GetUsers();
$soapClient->RemoveUser($targetUsername);
```

### Voice Web Service

[](#voice-web-service)

```
$soapClient->SendBulkSpeechText($title, $body, $receivers, $DateToSend, $repeatCount);
$soapClient->SendBulkVoiceSMS($title, $voiceFileId, $receivers, $DateToSend, $repeatCount);
$soapClient->UploadVoiceFile($title, $base64StringFile);
```

### Contacts Web Service

[](#contacts-web-service)

```
$soapClient->AddContact($groupIds, $firstname, $lastname, $nickname, $corporation, $mobilenumber,
        $phone, $fax, $birthdate, $email, $gender, $province, $city, $address, $postalCode, $additionaldate,
        $additionaltext, $descriptions);
$soapClient->AddContactEvents($contactId, $eventName, $eventType, $eventDate);
$soapClient->AddGroup($groupName, $Descriptions, $showToChilds);
$soapClient->ChangeContact($contactId, $firstname, $lastname, $nickname, $corporation, $mobilenumber,
        $phone, $fax, $email, $gender, $province, $city, $address, $postalCode, $contactStatus,
        $additionaltext, $descriptions);
$soapClient->ChangeGroup($groupId, $groupName, $Descriptions, $showToChilds, $groupStatus);
$soapClient->CheckMobileExistInContact($mobileNumber);
$soapClient->GetContactEvents($contactId);
$soapClient->GetContacts($groupId, $keyword, $from, $count);
$soapClient->GetContactsByID($contactId, $status);
$soapClient->GetGroups();
$soapClient->MergeGroups($originGroupId, $destinationGroupId, $deleteOriginGroup);
$soapClient->RemoveContact($mobilenumber);
$soapClient->RemoveContactByContactID($contactId);
$soapClient->RemoveGroup($groupId);
```

### Schedule Web Service

[](#schedule-web-service)

```
$soapClient->AddNewMultipleSchedule($to, $from, $text, $isflash, $scheduleDateTime, $period);
$soapClient->AddNewUsance($to, $from, $text, $isflash, $scheduleStartDateTime, $countrepeat,
        $scheduleEndDateTime, $periodType);
$soapClient->AddSchedule($to, $from, $text, $isflash, $scheduleDateTime, $period);
$soapClient->GetScheduleDetails($scheduleId);
$soapClient->GetScheduleStatus($scheduleId);
$soapClient->RemoveSchedule($scheduleId);
```

### Bulk Web Service

[](#bulk-web-service)

```
$soapClient->AddNumberBulk($from, $title, $messages, $receivers, $DateToSend);
$soapClient->BulkReception($bulkId, $maximumRows, $startRowIndex);
$soapClient->BulkReceptionCount($bulkId);
$soapClient->GetBulkDeliveries($recIds);
$soapClient->GetBulkDeliveries2($recId);
$soapClient->GetBulkDetails($bulkdId);
```

### Smart Web Service

[](#smart-web-service)

```
$soapClient->SendSmartSMS($to, $text, $from, $fromSupportOne, $fromSupportTwo);
$soapClient->SendMultipleSmartSMS($to, $text, $from, $fromSupportOne, $fromSupportTwo);
$soapClient->GetSmartSMSDeliveries($ids);
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

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

Every ~579 days

Total

2

Last Release

963d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3642c54bfeae6e892bd6ed23b2ebebcff6aebb888c936524358490ce6a97ded9?d=identicon)[farapayamakdev](/maintainers/farapayamakdev)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/farapayamak-php/health.svg)

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

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[facebook/php-business-sdk

PHP SDK for Facebook Business

90821.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

74513.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

265103.1M454](/packages/google-gax)[google/common-protos

Google API Common Protos for PHP

173103.7M50](/packages/google-common-protos)

PHPackages © 2026

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