PHPackages                             asharma327/apispreadsheets-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. [Utility &amp; Helpers](/categories/utility)
4. /
5. asharma327/apispreadsheets-php

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

asharma327/apispreadsheets-php
==============================

Api Spreadsheets PHP Library

1.0.1(4y ago)2855MITPHPPHP &gt;=7.0

Since Feb 12Pushed 4y ago2 watchersCompare

[ Source](https://github.com/asharma327/apispreadsheets-php)[ Packagist](https://packagist.org/packages/asharma327/apispreadsheets-php)[ RSS](/packages/asharma327-apispreadsheets-php/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

API Spreadsheets
================

[](#api-spreadsheets)

PHP library for [API Spreadsheets](https://www.apispreadsheets.com/docs)

Requirements
------------

[](#requirements)

- PHP &gt;= 7.0

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

[](#installation)

```
composer require asharma327/apispreadsheets-php

```

Usage
-----

[](#usage)

### 1. Create

[](#1-create)

The create method will create new rows in the file.

The required parameters are:

- `fileId`:`string` This id of the spreadsheet.
- `data`:`array` The rows that you want to create.

```
require 'vendor/autoload.php';

use ApiSpreadsheets\Spreadsheet;

// Data can have 3 formats:
$data = [
    'Id' => 1,
    'Name' => 'AT&T'
];

// Or:
$data = [[
    'Id' => 1,
    'Name' => 'AT&T'
], [
    'Id' => 2,
    'Name' => 'Apple'
]];

// Or:
$data = [
    'Id' => [1, 2],
    'Name' => ['AT&T', 'Apple']
];

$response = Spreadsheet::create('fileId', $data);

// Or if the file is private you can provide API keys as extra parameters:
$response = Spreadsheet::create('fileId', $data, 'accessKey', 'secretKey');

// ['message' => 'Your rows were created successfully', 'status_code' => 201]
```

### 2. Update

[](#2-update)

The update method will update values in columns.

The required parameters are:

- `fileId`:`string` This id of the spreadsheet.
- `data`:`array` The data you want to update.
- `query`: `string` SQL style query to update the rows that you want.

```
require 'vendor/autoload.php';

use ApiSpreadsheets\Spreadsheet;

$data = [
    'Id' => 1,
    'Name' => 'AT&T'
];

$query = "select*from[fileId]whereId=1";

$response = Spreadsheet::update('fileId', $data, $query);

// Or if the file is private you can provide API keys as extra parameters:
$response = Spreadsheet::update('fileId', $data, $query, 'accessKey', 'secretKey');

// ['message' => 'Your rows were updated successfully', 'status_code' => 201]
```

### 3. Read

[](#3-read)

The read method will read rows from your file.

The required parameter is:

- `fileId`:`string` This id of the spreadsheet.

```
require 'vendor/autoload.php';

use ApiSpreadsheets\Spreadsheet;

// An optional array to filter or change how the returned rows look like
$params = [
    'dataFormat' => 'column', // Can be matrix or column, the default is row.
    'limit' => 10, // limit the returned rows
    'count' => true, // only return the count of the result
    'query' => "select*from{$file_id}whereId=1" // SQL style query to get a subset of rows.
];

$response = Spreadsheet::read('fileId', $params);

// Or if the file is private you can provide API keys as extra parameters:
$response = Spreadsheet::read('fileId', $params, 'accessKey', 'secretKey');

// Response:

// in case of dataFormat is row (default):
// ['data' => [['Id' => 1, 'Name' => 'Apple'], [...]], 'status_code' => 200]

// column dataFormat:
// ['Id' => [1, ...], 'Name' => ['Apple', ...], 'status_code' => 200]

// matrix dataFormat:
// ['data' => [[1, 'Apple'], [...]], 'status_code' => 200]

// In case of count is true
// ['count' => 10, 'status_code' => 200]
```

### 4. Delete

[](#4-delete)

The delete method will delete rows from your file.

The required parameters are:

- `fileId`:`string` This id of the spreadsheet.
- `query`: `string` SQL style DELETE query to specify which rows to delete.

```
require 'vendor/autoload.php';

use ApiSpreadsheets\Spreadsheet;

$query = "delete*from[fileID]whereId=1";

$response = Spreadsheet::delete('fileId', $query);

// Or if the file is private you can provide API keys as extra parameters:
$response = Spreadsheet::delete('fileId', $query, 'accessKey', 'secretKey');

// ['message' => '2 rows were deleted', 'status_code' => 200]
```

API Error Handling
------------------

[](#api-error-handling)

If the API request has an error, an array with `error` and `status_code` key pairs will be returned, for example:

```
['error' = 'Error message', 'status_code' => 400]
```

For More information please consult the API docs:

License
-------

[](#license)

The MIT License (MIT). Please see [LICENSE](../master/LICENSE) for more information.

###  Health Score

26

—

LowBetter than 40% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

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

Total

2

Last Release

1537d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e7c8b39605776777ed569d63275d02caf2f30dfe454e18b24c2c9bc1d3c04126?d=identicon)[apispreadsheets](/maintainers/apispreadsheets)

---

Top Contributors

[![amrshawky](https://avatars.githubusercontent.com/u/17335226?v=4)](https://github.com/amrshawky "amrshawky (7 commits)")

---

Tags

spreadsheetsapi spreadsheetsapispreadsheets.com

### Embed Badge

![Health badge](/badges/asharma327-apispreadsheets-php/health.svg)

```
[![Health](https://phpackages.com/badges/asharma327-apispreadsheets-php/health.svg)](https://phpackages.com/packages/asharma327-apispreadsheets-php)
```

###  Alternatives

[gossi/composer-localdev-plugin

Composer Plugin for local development

333.3k](/packages/gossi-composer-localdev-plugin)

PHPackages © 2026

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