PHPackages                             skylab/studio - 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. skylab/studio

ActiveLibrary[API Development](/categories/api)

skylab/studio
=============

studio.skylabtech.ai PHP client

0.0.2(2y ago)06PHP

Since Apr 24Pushed 2y ago1 watchersCompare

[ Source](https://github.com/skylab-tech/studio_client_php)[ Packagist](https://packagist.org/packages/skylab/studio)[ RSS](/packages/skylab-studio/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (3)Versions (3)Used By (0)

Skylab Studio PHP Client
========================

[](#skylab-studio-php-client)

[studio.skylabtech.ai](https://studio.skylabtech.ai)

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

[](#installation)

```
composer require skylab/studio

```

Example usage
-------------

[](#example-usage)

Ensure that autoload is configured properly in `composer.json`

```
{
  "autoload": {
    "psr-4": {
      "Skylab\\Studio\\": "src/"
    }
  }
}
```

```
require './vendor/autoload.php';
use Skylab\Studio\SkylabStudio;

$api = new SkylabStudio('your-api-key');

// CREATE PROFILE
$profilePayload = [
  'name' => 'profile name',
  'enable_crop' => false,
  'enable_retouch' => true
];

$profile = $api->createProfile($profilePayload);

// CREATE JOB
$jobPayload = [
  'name' => 'job name',
  'profile_id' => $profile['id']
];

$job = $api->createJob($jobPayload);

// UPLOAD JOB PHOTO(S)
$filePath = '/path/to/photo';
$api->uploadJobPhoto($filePath, $job['id']);

// QUEUE JOB
$payload = [ 'callback_url' => 'YOUR_CALLBACK_ENDPOINT' ];
$api->queueJob($job['id'], $payload);

// NOTE: Once the job is queued, it will transition to processed and then completed
// We will send a response to the specified callback_url with the output photo download urls
```

Jobs
----

[](#jobs)

### List all Jobs

[](#list-all-jobs)

List the last 30 jobs.

```
$api->listJobs();
```

### Create a Job

[](#create-a-job)

```
$payload = [
  'name' => 'your unique job name',
  'profile_id' => 123
]

$api->createJob($payload);
```

For all payload options, consult the [API documentation](https://studio-docs.skylabtech.ai/#tag/job/operation/createJob).

### Get a Job

[](#get-a-job)

```
$api->getJob($jobId);
```

### Get Job by Name

[](#get-job-by-name)

```
$api->getJobByName($name);
```

### Update a Job

[](#update-a-job)

```
$payload = [
  'name' => 'your updated job name',
  'profile_id' => 123
]

$api->updateJob($jobId, $payload);
```

For all payload options, consult the [API documentation](https://studio-docs.skylabtech.ai/#tag/job/operation/updateJobById).

### Queue Job

[](#queue-job)

```
$payload = [ 'callback_url' => 'YOUR_CALLBACK_ENDPOINT' ]

$api->queueJob($jobId, $payload);
```

### Jobs in Front

[](#jobs-in-front)

```
$api->getJobsInFront($jobId);
```

### Delete a Job

[](#delete-a-job)

```
$api->deleteJob($jobId);
```

### Cancel a Job

[](#cancel-a-job)

```
$api->cancelJob($jobId);
```

Profiles
--------

[](#profiles)

### List all Profiles

[](#list-all-profiles)

```
$api->listProfiles();
```

### Create a Profile

[](#create-a-profile)

```
$api->createProfile([
  'name' => 'My Profile'
]);
```

For all payload options, consult the [API documentation](https://studio-docs.skylabtech.ai/#tag/profile/operation/createProfile).

### Get a Profile

[](#get-a-profile)

```
$api->getProfile($profileId);
```

### Update profile

[](#update-profile)

```
$payload = [
  'name' => 'My updated profile name',
];

$api->updateProfile($profileId, $payload);
```

For all payload options, consult the [API documentation](https://studio-docs.skylabtech.ai/#tag/profile/operation/updateProfileById).

Photos
------

[](#photos)

#### Upload Job Photo

[](#upload-job-photo)

This function handles validating a photo, creating a photo object and uploading it to your job/profile's s3 bucket. If the bucket upload process fails, it retries 3 times and if failures persist, the photo object is deleted.

```
$api->uploadJobPhoto($photoPath, $jobId);
```

`Returns: { photo: { photoObject }, uploadResponse: bucketUploadResponseStatus }`

If upload fails, the photo object is deleted for you. If upload succeeds and you later decide you no longer want to include that image, use delete\_photo to remove it.

### Get a Photo

[](#get-a-photo)

```
$api->getPhoto($photoId);
```

### Delete a Photo

[](#delete-a-photo)

```
$api->deletePhoto($photoId);
```

Troubleshooting
---------------

[](#troubleshooting)

### General Troubleshooting

[](#general-troubleshooting)

- Enable debug mode
- Capture the response data and check your logs — often this will have the exact error

### Enable Debug Mode

[](#enable-debug-mode)

Debug mode prints out the underlying request information as well as the data payload that gets sent to Skylab. You will most likely find this information in your logs. To enable it, simply put `true` as a parameter when instantiating the API object.

```
$api = new SkylabStudio("your-api-key", true);
```

### Response Ranges

[](#response-ranges)

SkylabTech's API typically sends responses back in these ranges:

- 2xx – Successful Request
- 4xx – Failed Request (Client error)
- 5xx – Failed Request (Server error)

If you're receiving an error in the 400 response range follow these steps:

- Double check the data and ID's getting passed to Skylab
- Ensure your API key is correct
- Log and check the body of the response

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance31

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity31

Early-stage or recently created project

 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 ~1 days

Total

2

Last Release

743d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ed166d806a56668cd30b5782832a337b4350c7ae4c3d8b4045e37e70fbfb56d4?d=identicon)[skylab-tech](/maintainers/skylab-tech)

---

Top Contributors

[![2lives](https://avatars.githubusercontent.com/u/34896692?v=4)](https://github.com/2lives "2lives (47 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/skylab-studio/health.svg)

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

###  Alternatives

[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3731.2M42](/packages/tencentcloud-tencentcloud-sdk-php)[convertkit/convertkitapi

Kit PHP SDK for the Kit API

2167.1k1](/packages/convertkit-convertkitapi)[mapado/rest-client-sdk

Rest Client SDK for hydra API

1125.9k2](/packages/mapado-rest-client-sdk)

PHPackages © 2026

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