CodeCanyon

Purchase ID's available to Developers

17 posts
  • Bought between 1 and 9 items
  • Has been a member for 2-3 years
  • Referred between 1 and 9 users
  • Sold between 1 000 and 5 000 dollars
  • United States
Cueburst says

Hi.

Is it possible to have a “test” purchase ID for each of our items? I’d like to use the API to verify when a user has purchased my item.

Currently, the only way to get it is to buy your own item yourself. (As far as i’m aware) And i don’t fancy loosing 50% ($10) for buying my own work. :P

Any chance we can get a test ID in the future? Adrian

626 posts
  • Bought between 10 and 49 items
  • Exclusive Author
  • Has been a member for 3-4 years
  • Sold between 100 and 1 000 dollars
Thecodingdude says

You can’t buy your own work anyway (not sure if you can when logged out).

Nice idea though.

356 posts
  • Envato Staff
  • Reviewer
  • Sold between 10 000 and 50 000 dollars
  • Has been a member for 4-5 years
  • Bought between 50 and 99 items
  • Contributed a Tutorial to a Tuts+ Site
  • Beta Tester
+4 more
Philo01 staff says

I don’t think there is a test ID. I solved it by creating a second account and purchased one of my own items. But like you said it’s not the most ideal solution.

972 posts
  • United Kingdom
  • Community Superstar
  • Attended a Community Meetup
  • Repeatedly Helped protect Envato Marketplaces against copyright violations
  • Sold between 5 000 and 10 000 dollars
  • Has been a member for 2-3 years
  • Microlancer Beta Tester
  • Bought between 100 and 499 items
  • Referred between 10 and 49 users
+1 more
aaranmcguire says

if you knew anyone that had bought a item of yours you could always ask them, thats what i did when i was testing it out.

2354 posts
  • Grew a moustache for the Envato Movember competition
  • Community Moderator
  • Elite Author
  • Contributed a Blog Post
  • Won a Competition
  • Repeatedly Helped protect Envato Marketplaces against copyright violations
  • Has been a member for 4-5 years
+8 more
dtbaker moderator says

I just create my own test purchase code, and return my own test api data when that code is entered from a certain ip address. Here’s a quick example, it should work.

$license_code = $_REQUEST['license_code'];
if($license_code == 'my_unique_testing_code'){
    $verify_data = '{"verify-purchase":{"buyer":"DEV","created_at":"Wed Dec 01 05:00:47 +1100 2010","licence":"Regular Licence","item_name":"Your Item Name Here","item_id":"123456"}}';
}else{
     $verify_data = file_get_contents("http://marketplace.envato.com/api/edge/".$username."/".$api_key."/verify-purchase:$license_code.json");
}
$license_check = json_decode($verify_data,true);
print_r($license_check);

restricting it to an ip address lets you also use your own unique dev code in certain situations, such as a demo of the item (example) while stopping other people using that demo license code.

it would be nice to have a unique purchase code for each item that worked directly the api though. maybe displayed in the “edit” screen of the authors item.

17 posts
  • Bought between 1 and 9 items
  • Has been a member for 2-3 years
  • Referred between 1 and 9 users
  • Sold between 1 000 and 5 000 dollars
  • United States
Cueburst says

Thanks for that Baker. :)

by
by
by
by
by