Download the PHP package blueink/blueink-client-php without Composer

On this page you can find all versions of the php package blueink/blueink-client-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package blueink-client-php

Blueink API Client for PHP

A PHP SDK for the Blueink eSignature REST API. For full API reference see the Blueink API v2 docs.

Requirements

Installation

Quickstart

Configuration

The Client constructor accepts:

Argument Default Description
$private_api_key getenv('BLUEINK_PRIVATE_API_KEY') Blueink private API key.
$base_url getenv('BLUEINK_API_URL') ?? https://api.blueink.com/api/v2 Override for sandbox or custom hosts.
$raise_exceptions true When false, 4XX/5XX responses are returned as NormalizedResponse instead of throwing a Guzzle exception.

Responses: NormalizedResponse

Every subclient method returns a Blueink\ClientSDK\NormalizedResponse:

The most-recent response for a given subclient is also retained:

Subclients

The Client exposes one property per resource:

Property Class Resource
$client->bundles BundleSubClient Bundles (envelopes)
$client->persons PersonSubClient Persons (signers / contacts)
$client->packets PacketSubClient Packets (per-recipient)
$client->templates TemplateSubClient Document templates
$client->envelope_templates EnvelopeTemplateSubClient Envelope templates
$client->webhooks WebhookSubClient Webhooks, headers, events, deliveries

Bundles

Create a Bundle from a hand-built payload:

Or use BundleHelper to assemble it. The helper exposes convenience methods for adding signers, documents, fields, and auto-placements without hand-rolling the nested payload:

When the helper has files queued via addDocumentByFile(), the SDK transparently switches the request to multipart/form-data.

Building a Bundle from a document Template

addDocumentTemplate() adds a Document backed by an existing template, with optional role assignments and initial field values. assignRole() and setValue() append to the same Document after the fact:

Other Bundle operations:

Persons

The Blueink API normalizes name by splitting on whitespace into first/last tokens, so the round-tripped name may not be byte-identical to what was sent.

Packets

Templates

Envelope Templates

Envelope templates are reusable, end-to-end Bundle workflows configured in the Blueink dashboard. The subclient is read-only:

To create a Bundle from an envelope template, configure a BundleHelper with setEnvelopeTemplate() (plus any signers and field overrides) and post it via createFromEnvelopeTemplateHelper():

For pre-built payloads, createFromEnvelopeTemplate(array $data) posts the array directly to /bundles/create_from_envelope_template/.

Webhooks

Pagination

List endpoints accept page and per_page and return a Pagination object on the response, parsed from the X-Blueink-Pagination header:

For automatic page-walking, every list-capable subclient exposes a pagedList() that returns a Paginated iterator. Each iteration yields the next page's NormalizedResponse:

Error handling

By default, 4XX/5XX responses raise a Blueink\ClientSDK\BlueinkApiError, a typed exception that parses the Blueink error body shape:

BlueinkApiError extends \RuntimeException, so a generic catch (\Throwable $e) still works. The original Guzzle BadResponseException (ClientException / ServerException) is preserved as the previous exception. Network-level failures (GuzzleHttp\Exception\ConnectException, RequestException without a response) are not wrapped and continue to bubble up unchanged.

To inspect failures without try/catch, construct the client with raise_exceptions: false. 4XX and 5XX responses then come back as NormalizedResponse objects with status and decoded data:

Testing

The SDK ships with two PHPUnit suites:

License

MIT.


All versions of blueink-client-php with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
guzzlehttp/guzzle Version ^7.8
psr/http-message Version ^1.1 || ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package blueink/blueink-client-php contains the following files

Loading the files please wait ...