PHPackages                             codegyan/client - 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. codegyan/client

ActiveLibrary[API Development](/categories/api)

codegyan/client
===============

Codegyan SDK for interacting with the Codegyan API

v0.1.1(2y ago)08MITPHPPHP ^8.1.0

Since May 11Pushed 2y agoCompare

[ Source](https://github.com/Codegyan-LLC/clients)[ Packagist](https://packagist.org/packages/codegyan/client)[ GitHub Sponsors](https://github.com/prathmeshyelne)[ RSS](/packages/codegyan-client/feed)WikiDiscussions main Synced 1mo ago

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

 [![Codegyan PHP](https://github.com/Codegyan-LLC/client/raw/main/art/code.png)](https://github.com/Codegyan-LLC/client/blob/main/art/code.png)

 [![GitHub Workflow Status (main)](https://camo.githubusercontent.com/b46e6aca4917086687231181a629e66f337ffde7c2b2642654071c3da333184f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f436f64656779616e2d4c4c432f636c69656e742f74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d726f756e642d737175617265)](https://github.com/Codegyan-LLC/client/actions) [![Total Downloads](https://camo.githubusercontent.com/5fc27d7a93f5019fc03422fe405287c311d93bc0ebee315d7586709ba04141b4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f636f64656779616e2f636c69656e74)](https://packagist.org/packages/codegyan/client) [![Latest Version](https://camo.githubusercontent.com/78e82781fe367a03c2e215aa4997558927553f311eb62314642203a81a8d68ec/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f636f64656779616e2f636c69656e74)](https://packagist.org/packages/codegyan/client) [![PHP Version](https://camo.githubusercontent.com/0865ebd4a4b8163e3d6836d34682c56eaccfdc901c7aae1db8bb86ac778d54a2/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253545382e312e302d79656c6c6f77)](https://www.php.net/) [![License](https://camo.githubusercontent.com/800e45b537855b350485ed7180ad8395966c1ec5f6903e6c7aa92a6c3bbeb165/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f636f64656779616e2f636c69656e74)](https://packagist.org/packages/codegyan/client)

---

**Codegyan PHP SDK** for interacting with the [Codegyan API](https://developer.codegyan.in/docs/). If you or your business relies on this package, it's important to support the developers who have contributed their time and effort to create and maintain this valuable tool:

- Prathmesh Yelne : **[github.com/sponsors/prathmeshyelne](https://github.com/sponsors/prathmeshyelne)**

Table of Contents
-----------------

[](#table-of-contents)

- [Get Started](#get-started)
- [Usage](#usage)
    - [Compiler Resource](#compiler-resource)
    - [Tools Resource](#tools-resource)
    - [Articles Resource](#articles-resource)
    - [tutorials Resource](#tutorilas-resource)
- [Troubleshooting](#troubleshooting)
- [Testing](#testing)
- [Services](#services)

Get Started
-----------

[](#get-started)

> **Requires [PHP 8.1+](https://php.net/releases/)**

First, install Codegyan via the [Composer](https://getcomposer.org/) package manager:

```
composer require codegyan/client
```

Then, interact with Codegyan's API:

```
use Codegyan\Client;

// Your API key and client ID
$apiKey = '';
$clientId = '';

// Create a Client instance
$client = new Client($apiKey, $clientId);

$domain = "codegyan.in"; // Domain Here

try {
    $result = $client->toolsApiClient->domainAvailability($domain);
    echo "$result\n";
} catch (Exception $e) {
    echo "Error: " . $e->getMessage() . "\n";
}
```

Usage
-----

[](#usage)

Before using the Pakage, you need to obtain an API key and client ID from Codegyan. Follow these steps to get your API credentials:

1. **Sign Up/Login**: If you don't have an account, sign up for a [Codegyan account](https://codegyan.in/account/signup.php). If you already have an account, log in to your dashboard.
2. **Get Credentials**: Once logged in, navigate to the [Developer Console](https://developer.codegyan.in/) or API settings in your account dashboard. Here, you will find your API key and client ID. Copy these credentials and use them when initializing the Pakage in your code.

### `Compiler` Resource

[](#compiler-resource)

The Compiler resource allows you to compile code snippets. Here's an example of how to use it:

```
use Codegyan\Client;

// Your API key and client ID
$apiKey = '';
$clientId = '';

// Create a Client instance
$client = new Client($apiKey, $clientId);

$lang = "python3";
$code = "print('Hello World')";

try {
    $result = $client->compilerApiClient->compile($lang, $code);
    echo "$result\n";
} catch (Exception $e) {
    echo "Error: " . $e->getMessage() . "\n";
}
```

### `Tools` Resource

[](#tools-resource)

The Tools resource provides various utility functions. Here's an example of how to use it:

```
use Codegyan\Client;

// Your API key and client ID
$apiKey = '';
$clientId = '';

// Create a Client instance
$client = new Client($apiKey, $clientId);

$domain = "example.com";

try {
    $result = $client->toolsApiClient->domainAvailability($domain);
    echo "$result\n";
} catch (Exception $e) {
    echo "Error: " . $e->getMessage() . "\n";
}
```

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

[](#troubleshooting)

If you encounter any issues or have any questions, please feel free to reach out to our support team at .

Testing
-------

[](#testing)

We highly recommend testing your integration with CodeGyan's PHP SDK to ensure its correctness and reliability. You can use PHPUnit or any other testing framework of your choice to write and execute tests for your application.

If you haven't already installed PHPUnit, you can do so by running:

```
composer require --dev phpunit/phpunit
```

Once PHPUnit is installed, you can run your tests using the following command:

```
vendor/bin/phpunit
```

This command will execute all tests located in the tests directory of your project.

> Note : Make sure to write tests that cover various use cases and edge cases of your integration with the CodeGyan SDK to ensure robustness.

Services
--------

[](#services)

For more information about CodeGyan's services, please visit our website.

Codegyan PHP SDK is an open-sourced software licensed under the **[MIT license](https://opensource.org/licenses/MIT)**.

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 92% 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 ~0 days

Total

2

Last Release

736d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/648d0b98bdff35c80c1eae5ebd9e644e1966fcc1a11b651a1e148674e32eadcc?d=identicon)[codegyan](/maintainers/codegyan)

---

Top Contributors

[![prathmeshyelne](https://avatars.githubusercontent.com/u/88598499?v=4)](https://github.com/prathmeshyelne "prathmeshyelne (23 commits)")[![innovilla-prathmesh](https://avatars.githubusercontent.com/u/146651770?v=4)](https://github.com/innovilla-prathmesh "innovilla-prathmesh (2 commits)")

---

Tags

apiapi-clientcodegyancodexcompilersdktoolxphpapiclientsdkcodexcodegyantoolx

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/codegyan-client/health.svg)

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

###  Alternatives

[openai-php/client

OpenAI PHP is a supercharged PHP API client that allows you to interact with the Open AI API

5.8k22.6M232](/packages/openai-php-client)[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k7.6M74](/packages/openai-php-laravel)

PHPackages © 2026

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