|
2 | 2 |
|
3 | 3 | An API client for Envato in PHP, with simplified OAuth, token storage, and request sending. |
4 | 4 |
|
5 | | -## Contents |
6 | | - |
7 | 5 | - [Notes](#notes) |
8 | 6 | - [Installation](#installation) |
9 | 7 | - [Authentication](#authentication) |
10 | | - - [Personal Token](#personal-token) |
11 | | - - [OAuth](#oauth) |
12 | | - - [Persistent OAuth](#persistent-oauth) |
| 8 | + - [Personal Token](#personal-token) |
| 9 | + - [OAuth](#oauth) |
| 10 | + - [Persistent OAuth](#persistent-oauth) |
13 | 11 | - [Sending Requests](#sending-requests) |
14 | | - - [Getting Request Time](#getting-request-time) |
15 | | - - [Rate Limiting](#rate-limiting) |
| 12 | + - [Getting Request Time](#getting-request-time) |
| 13 | + - [Rate Limiting](#rate-limiting) |
16 | 14 | - [Catalog](#catalog) |
17 | | - - [Look up a public collection](#look-up-a-public-collection) |
18 | | - - [Look up a single item](#look-up-a-single-item) |
19 | | - - [Look up a single WordPress theme/plugin version](#look-up-a-single-wordpress-themeplugin-version) |
20 | | - - [Search for items](#search-for-items) |
21 | | - - [Search for comments](#search-for-comments) |
22 | | - - [Popular items by site](#popular-items-by-site) |
23 | | - - [Categories by site](#categories-by-site) |
24 | | - - [Prices for a particular item](#prices-for-a-particular-item) |
25 | | - - [New items by site and category](#new-items-by-site-and-category) |
26 | | - - [Find featured items](#find-featured-items) |
27 | | - - [Random new items](#random-new-items) |
| 15 | + - [Look up a public collection](#look-up-a-public-collection) |
| 16 | + - [Look up a single item](#look-up-a-single-item) |
| 17 | + - [Look up a single WordPress theme/plugin version](#look-up-a-single-wordpress-themeplugin-version) |
| 18 | + - [Search for items](#search-for-items) |
| 19 | + - [Search for comments](#search-for-comments) |
| 20 | + - [Popular items by site](#popular-items-by-site) |
| 21 | + - [Categories by site](#categories-by-site) |
| 22 | + - [Prices for a particular item](#prices-for-a-particular-item) |
| 23 | + - [New items by site and category](#new-items-by-site-and-category) |
| 24 | + - [Find featured items](#find-featured-items) |
| 25 | + - [Random new items](#random-new-items) |
28 | 26 | - [Profile](#profile) |
29 | | - - [List all of current user's collections](#list-all-of-current-users-collections) |
30 | | - - [Look up a collection by ID](#look-up-a-collection-by-id) |
31 | | - - [Get a user's profile details](#get-a-users-profile-details) |
32 | | - - [List a user's badges](#list-a-users-badges) |
33 | | - - [Get a user's items by site](#get-a-users-items-by-site) |
34 | | - - [Get a user's newest items](#get-a-users-newest-items) |
| 27 | + - [List all of current user's collections](#list-all-of-current-users-collections) |
| 28 | + - [Look up a collection by ID](#look-up-a-collection-by-id) |
| 29 | + - [Get a user's profile details](#get-a-users-profile-details) |
| 30 | + - [List a user's badges](#list-a-users-badges) |
| 31 | + - [Get a user's items by site](#get-a-users-items-by-site) |
| 32 | + - [Get a user's newest items](#get-a-users-newest-items) |
35 | 33 | - [User](#user) |
36 | | - - [List an author's sales](#list-an-authors-sales) |
37 | | - - [Look up a sale by purchase code](#look-up-a-sale-by-purchase-code) |
38 | | - - [List a buyer's purchases](#list-a-buyers-purchases) |
39 | | - - [Look up a buyer's purchase by code](#look-up-a-buyers-purchase-by-code) |
40 | | - - [Get private account details](#get-private-account-details) |
41 | | - - [Get the current user's username](#get-the-current-users-username) |
42 | | - - [Get the current user's email](#get-the-current-users-email) |
43 | | - - [Get the user's sales by month](#get-the-users-sales-by-month) |
| 34 | + - [List an author's sales](#list-an-authors-sales) |
| 35 | + - [Look up a sale by purchase code](#look-up-a-sale-by-purchase-code) |
| 36 | + - [List a buyer's purchases](#list-a-buyers-purchases) |
| 37 | + - [Look up a buyer's purchase by code](#look-up-a-buyers-purchase-by-code) |
| 38 | + - [Download a buyer's purchase](#download-a-buyers-purchase) |
| 39 | + - [Get private account details](#get-private-account-details) |
| 40 | + - [Get the current user's username](#get-the-current-users-username) |
| 41 | + - [Get the current user's email](#get-the-current-users-email) |
| 42 | + - [Get the user's sales by month](#get-the-users-sales-by-month) |
44 | 43 | - [Market](#market) |
45 | | - - [Get total number of users](#get-total-number-of-users) |
46 | | - - [Get total number of items](#get-total-number-of-items) |
47 | | - - [Get total number of items by site](#get-total-number-of-items-by-site) |
48 | | -- [Handling Errors & Exceptions](#handling-errors-exceptions) |
49 | | - - [Authorization Errors](#authorization-errors) |
50 | | - - [Request Errors](#request-errors) |
| 44 | + - [Get total number of users](#get-total-number-of-users) |
| 45 | + - [Get total number of items](#get-total-number-of-items) |
| 46 | + - [Get total number of items by site](#get-total-number-of-items-by-site) |
| 47 | +- [Handling Errors & Exceptions](#handling-errors--exceptions) |
| 48 | + - [Authorization Errors](#authorization-errors) |
| 49 | + - [Request Errors](#request-errors) |
51 | 50 | - [Examples](#examples) |
52 | | - - [Verifying Purchase Codes](#verifying-purchase-codes) |
| 51 | + - [Verifying Purchase Codes](#verifying-purchase-codes) |
53 | 52 | - [Contributors](#contributors) |
54 | 53 |
|
55 | 54 | ## Notes |
@@ -340,6 +339,13 @@ $client->user->purchases(); |
340 | 339 | $client->user->purchase(['code' => '*****']); |
341 | 340 | ``` |
342 | 341 |
|
| 342 | +### Download a buyer's purchase |
| 343 | + |
| 344 | +```php |
| 345 | +$client->user->download(['purchase_code' => '*****']); |
| 346 | +$client->user->download(['item_id' => '123456']); |
| 347 | +``` |
| 348 | + |
343 | 349 | ### Get private account details |
344 | 350 |
|
345 | 351 | ```php |
@@ -444,7 +450,8 @@ else { |
444 | 450 |
|
445 | 451 | ## Contributors |
446 | 452 |
|
447 | | -Special thanks to the following people for contributing to this package: |
| 453 | +Special thanks to the following contributors for their help in maintaining this package: |
448 | 454 |
|
449 | 455 | - [@gdarko](https://github.com/gdarko) |
450 | 456 | - [@Dibbyo456](https://github.com/Dibbyo456) |
| 457 | +- [@evrpress](https://github.com/evrpress) |
0 commit comments