PHPackages                             morganolufsen/google-cloud-vision-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. [API Development](/categories/api)
4. /
5. morganolufsen/google-cloud-vision-php

ActivePackage[API Development](/categories/api)

morganolufsen/google-cloud-vision-php
=====================================

A simple php library for the google cloud vision API

1.3.0(2y ago)013MITPHP

Since Feb 27Pushed 2y agoCompare

[ Source](https://github.com/MorganOlufsen/google-cloud-vision-php)[ Packagist](https://packagist.org/packages/morganolufsen/google-cloud-vision-php)[ RSS](/packages/morganolufsen-google-cloud-vision-php/feed)WikiDiscussions master Synced 1mo ago

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

google-cloud-vision-php
=======================

[](#google-cloud-vision-php)

Overview
========

[](#overview)

Performs Label detection, face detection, Logo detection, explicit content detection, landmark detection, optical character recogition and web detection on images. You can read more about Google cloud vision here

Getting Started
===============

[](#getting-started)

You will need a google account to use this API so if you do not already have an account with google, head over there and create one

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

[](#installation)

```
composer require wapnen/google-cloud-vision-php
```

Enable the API
--------------

[](#enable-the-api)

To start using the google cloud vision api, follow the instructions here to enable the api for your google account

Authentication
--------------

[](#authentication)

You must set up an Api key to authenticate your requests. Follow the instructions here  to set up an API key for your project on google cloud platform console

Usage
=====

[](#usage)

```

```

Note : You can create as many as 16 Annotate image requests to be sent with the request object

The function `setImageUri();` takes a Google Cloud Storage image location, or publicly-accessible image URL. Alternatively you can use `setImage();` which takes a base64 encoded image string.

You can set as many features as are available to the annotateImageRequest by calling the `setFeature();` function on the annotateImageRequest which takes any of the following enum parameters ; TYPE\_UNSPECIFIED, FACE\_DETECTION, LANDMARK\_DETECTION, LOGO\_DETECTION, LABEL\_DETECTION, TEXT\_DETECTION, DOCUMENT\_TEXT\_DETECTION, SAFE\_SEARCH\_DETECTION, IMAGE\_PROPERTIES, CROP\_HINTS, WEB\_DETECTION.

Optionally, you can set the image context for each annotateImageRequest object like so

```
$annotateImageRequest1 = new AnnotateImageRequest()
$annotateImageRequest1->setImageContext();
$annotateImageRequest1->getImageContext()->setCropHintsParams([1.333]); //array
$annotateImageRequest1->getImageContext()->setWebDetectionParams(false);  //boolean
$annotateImageRequest1->getImageContext()->setLanguageHints([]); //array

```

Finally, the GoogleCloudVision request object takes an array of AnnotateImageRequest objects as the first parameter and the api key as the second parameter

### Response object

[](#response-object)

If successful, you will receive a json object response in the format below;

```
{
  "responses": [
    {
      object(AnnotateImageResponse)
    }
  ]
}

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 62.5% 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

804d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/689832fda3eda47e193b0084363440959af18ab1bf5e983a61087f20cc674ce7?d=identicon)[MorganOlufsen](/maintainers/MorganOlufsen)

---

Top Contributors

[![wapnen](https://avatars.githubusercontent.com/u/18328614?v=4)](https://github.com/wapnen "wapnen (10 commits)")[![MorganOlufsen](https://avatars.githubusercontent.com/u/37509162?v=4)](https://github.com/MorganOlufsen "MorganOlufsen (6 commits)")

---

Tags

phpmachine learningComputer Visiongoogle cloud vision api

### Embed Badge

![Health badge](/badges/morganolufsen-google-cloud-vision-php/health.svg)

```
[![Health](https://phpackages.com/badges/morganolufsen-google-cloud-vision-php/health.svg)](https://phpackages.com/packages/morganolufsen-google-cloud-vision-php)
```

###  Alternatives

[theodo-group/llphant

LLPhant is a library to help you build Generative AI applications.

1.5k311.5k5](/packages/theodo-group-llphant)[mailchimp/transactional

458.9M16](/packages/mailchimp-transactional)[deepseek-php/deepseek-php-client

deepseek PHP client is a robust and community-driven PHP client library for seamless integration with the Deepseek API, offering efficient access to advanced AI and data processing capabilities.

47073.9k5](/packages/deepseek-php-deepseek-php-client)[resend/resend-php

Resend PHP library.

564.7M21](/packages/resend-resend-php)[monkeylearn/monkeylearn-php

Official PHP client for the MonkeyLearn API.

51125.8k1](/packages/monkeylearn-monkeylearn-php)[scriptdevelop/whatsapp-manager

Paquete para manejo de WhatsApp Business API en Laravel

762.6k](/packages/scriptdevelop-whatsapp-manager)

PHPackages © 2026

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