schematichq/schematic-php

Schematic API

0.9.0 2025-02-12 21:19 UTC

This package is not auto-updated.

Last update: 2025-02-12 21:28:42 UTC


README

Schematic API

For more information, please visit https://schematichq.com.

Installation & Usage

Requirements

PHP 7.4 and later. Should also work with PHP 8.0.

Installation

You can install the Schematic PHP SDK via Composer. Run the following command in your project directory:

composer require schematichq/schematic-php

Usage

To initialize the Schematic client, provide a secret API key; you can issue an API key in the API Keys section of settings in the Schematic web app.

<?php

require_once 'vendor/autoload.php';

use Schematic\Schematic;

$schematic = new Schematic('YOUR_SECRET_API_KEY');

Once you have initialized the Schematic client, you can make API calls using the various API classes provided by the SDK.

$companies = $schematic->CompaniesApi->listCompanies();

The SDK throws exceptions in case of API errors. You can catch and handle these exceptions in your code:

try {
    $companies = $schematic->CompaniesApi->listCompanies();
    // Process the companies
} catch (\Exception $e) {
    // Handle the exception
    echo 'Error: ' . $e->getMessage();
}

API Endpoints

The following Schematic API endpoints are accessible via this client library. All URIs are relative to https://api.schematichq.com

Models

Author

engineering@schematichq.com

Support

If you encounter any issues or have questions regarding the Schematic PHP SDK, please contact our support team at support@schematic.com.