PHPackages                             invoq/invoq-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. [Payment Processing](/categories/payments)
4. /
5. invoq/invoq-php

ActiveLibrary[Payment Processing](/categories/payments)

invoq/invoq-php
===============

PHP SDK for invoq server APIs and webhook verification.

v0.2.0(1w ago)00MITPHPPHP ^8.1

Since Jul 8Pushed 1w agoCompare

[ Source](https://github.com/invoqmoney/sdk-php)[ Packagist](https://packagist.org/packages/invoq/invoq-php)[ RSS](/packages/invoq-invoq-php/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependenciesVersions (4)Used By (0)

invoq PHP SDK
=============

[](#invoq-php-sdk)

**English** · [Bahasa Indonesia](./docs/README.id.md) · [Español](./docs/README.es-419.md) · [Français](./docs/README.fr.md) · [Português](./docs/README.pt-BR.md) · [Tiếng Việt](./docs/README.vi.md) · [Türkçe](./docs/README.tr.md) · [ไทย](./docs/README.th.md) · [简体中文](./docs/README.zh-Hans.md) · [繁體中文](./docs/README.zh-Hant.md)

PHP SDK for invoq server APIs and webhook verification.

Use this package only on your server. It accepts secret keys and must not be bundled into browser code.

Server SDKs
-----------

[](#server-sdks)

Create invoices and verify webhooks from your backend in any of these languages — same REST API, same webhook signature. This repository is the PHP SDK.

LanguageRepositoryNode.js[github.com/invoqmoney/sdk-js](https://github.com/invoqmoney/sdk-js) (`@invoq/server`)Python[github.com/invoqmoney/sdk-python](https://github.com/invoqmoney/sdk-python)PHP**this repo**Go[github.com/invoqmoney/sdk-go](https://github.com/invoqmoney/sdk-go)Rust[github.com/invoqmoney/sdk-rust](https://github.com/invoqmoney/sdk-rust)Ruby[github.com/invoqmoney/sdk-ruby](https://github.com/invoqmoney/sdk-ruby)The browser side is the same for every backend: **`@invoq/checkout`** (JavaScript, in [github.com/invoqmoney/sdk-js](https://github.com/invoqmoney/sdk-js)) opens the in-page checkout modal for any frontend.

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

[](#installation)

```
composer require invoq/invoq-php
```

Requires PHP 8.1 or newer.

Get your keys
-------------

[](#get-your-keys)

1. Sign in to the [invoq dashboard](https://app.invoq.money) and create a project.
2. On the **API keys** page, create a secret key. Test keys start with `sk_test_`, live keys with `sk_live_`.
3. In your project's **webhooks** settings, save your webhook URL. The webhook secret (`whsec_...`) for that mode is shown once, when you first enable the webhook. Store it right away.

Add both to your server environment:

```
INVOQ_SECRET_KEY=sk_test_...
INVOQ_WEBHOOK_SECRET=whsec_...
```

Create a client
---------------

[](#create-a-client)

```
