2017 © Pedro Peláez
 

library stocksnap

Unofficial PHP HTTP client to access Stocksnap's API

image

diza/stocksnap

Unofficial PHP HTTP client to access Stocksnap's API

  • Sunday, January 15, 2017
  • by taduuda
  • Repository
  • 1 Watchers
  • 0 Stars
  • 16 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

stocksnap-php

Unofficial PHP HTTP client to access Stocksnap's API, (*1)

Installation

Stocksnap-PHP uses Composer. To use it, require the library, (*2)

composer require diza/stocksnap

Usage

API methods

Diza\Stocksnap\HttpClient->all_photos($order_by, $sort_order, $page)

Retrieve a list of photos., (*3)

Note: You need to instantiate an httpclient object first, (*4)

Arguments, (*5)

Argument Type Opt/Required Note
$order_by string Opt (Default: date) Accepted values: date, trending, views, downloads, favorites
$sort_order string Opt (Default: desc) Accepted values: asc, desc
$page int Opt (Default: 1)

Example, (*6)

$stocksnap = new Diza\Stocksnap\HttpClient();
$photos = $stocksnap->all_photos($order_by, $sort_order, $page);

===, (*7)

Diza\Stocksnap\HttpClient->author_photos($author_id, $page)

Retrieve author's/user's photos., (*8)

Note: You need to instantiate an httpclient object first, (*9)

Arguments, (*10)

Argument Type Opt/Required
$author_id int Required
$page int Opt (Default: 1)

Example, (*11)

$stocksnap = new Diza\Stocksnap\HttpClient();
$photos = $stocksnap->author_photos($author_id, $page);

===, (*12)

Diza\Stocksnap\HttpClient->search($terms, $$order_by, $sort_order, $page)

Retrieve photos for a search term., (*13)

Note: You need to instantiate an httpclient object first, (*14)

Arguments, (*15)

Argument Type Opt/Required Note
$terms string Required Search terms (separated by +)
$order_by string Opt (Default: relevance) Accepted values: relevance, date, trending, views, downloads, favorites
$sort_order string Opt (Default: desc) Accepted values: asc, desc
$page int Opt (Default: 1)

Example, (*16)

$stocksnap = new Diza\Stocksnap\HttpClient();
$photos = $stocksnap->search($terms, $order_by, $sort_order, $page);

The Versions

15/01 2017

dev-master

9999999-dev

Unofficial PHP HTTP client to access Stocksnap's API

  Sources   Download

MIT

The Requires

 

The Development Requires

http client web service http client stocksnap

15/01 2017

v0.1.2

0.1.2.0

Unofficial PHP HTTP client to access Stocksnap's API

  Sources   Download

MIT

The Requires

 

The Development Requires

http client web service http client stocksnap

15/01 2017

v0.1.1

0.1.1.0

Unofficial PHP HTTP client to access Stocksnap's API

  Sources   Download

MIT

The Requires

 

The Development Requires

http client web service http client stocksnap

14/01 2017

v0.1.0

0.1.0.0

PHP HTTP client to access Stocksnap's API

  Sources   Download

MIT

The Requires

 

The Development Requires

http client web service http client stocksnap