Download the PHP package tineye/tineye-api without Composer
On this page you can find all versions of the php package tineye/tineye-api. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download tineye/tineye-api
More information about tineye/tineye-api
Files in tineye/tineye-api
Package tineye-api
Short Description Library to reverse image search using the TinEye API
License MIT
Homepage https://tineye.com
Informations about the package tineye-api
TinEye API PHP Library
tineye-api is a PHP library for the TinEye API. The TinEye API is a paid reverse image search solution for professional, commercial or high-volume users of TinEye.
Contents
- Installation
- Migrating from previous versions
- Getting started
- Methods
- Common parameters
- Search using an image URL
- Search using image data
- Get remaining searches
- Get number of indexed images
- Get the HTTP client
- Support
- Testing
- License
Installation
Install via Composer. If composer is installed, run the following from your shell:
Migrating from previous versions
If you were using any version of the TinEye API library before 2.0.0
, you will need
to make minor changes to your code.
The API object is now instantiated using a single key, api_key
. The value
of this key is the same as your previous private_key
. The public key is no
longer used.
New ✅
Old ❌
Getting started
Once you've installed the library, you can instantiate a TinEyeApi
object with your API key:
If you don't have an account yet, you can still test out the library using our API sandbox by instantiating the TinEyeApi
object
with no arguments:
Note that the API sandbox will not return real results; all results will be the same image of a cat.
Once you've created your TinEyeApi
object you can start searching. You can submit an image using either an
submitting image data
by uploading an image file. You can also check the number of remaining searches
in your account or check the number of images in the TinEye index.
Methods
Common parameters
Each search method (searchUrl
and searchData
) takes an optional parameter params
that takes an associative array with any of these options:
For more information on possible settings please visit the TinEye API documention.
Search using an image URL
Use this method to have TinEye download an image URL and search it against the TinEye index.
Search using image data
Use this method to upload an image to TinEye and search it against the TinEye index.
Get remaining searches
Use this method to get the number and status of remaining search bundles.
Get number of indexed images
Use this method to get the number and images currently indexed by TinEye
Get the HTTP client
This method allows access to the wrapped GuzzleHttp client. More information is available at GuzzleHttp.
Support
Please send comments, recommendations, and bug reports to [email protected].
Testing
Tests are located in the /tests
folder and use PHPunit.
License
Licensed under the MIT License (MIT). Please see License File for more information.