Title: HTTP ERROR 500
Last modified: March 26, 2020

---

# HTTP ERROR 500

 *  Resolved [arepsv](https://wordpress.org/support/users/arepsv/)
 * (@arepsv)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/)
 * lmfwc is installed on the main domain.
    (example.com).
 * then I create a new sub domain for the GET AND POST License Key.
    at (sub.example.
   com/index.php)
 * I followed the documentation at
    [link](https://www.licensemanager.at/docs/rest-api/developer-documentation/create-a-license/)
 * Everything works fine, except when I want “POST” to make a new license key.
 * in the browser only appears
    “HTTP ERROR 500”.
 * is there a solution ..?

Viewing 5 replies - 1 through 5 (of 5 total)

 *  [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * (@drazenbebic)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12585463)
 * Hello [@arepsv](https://wordpress.org/support/users/arepsv/)
 * Thank you for your message and for using my plugin.
 * I don’t understand what exactly it is you did. But if you installed the plugin
   on the main domain, shouldn’t you make your requests there?
 * Also, do you have any PHP error logs?
 *  Thread Starter [arepsv](https://wordpress.org/support/users/arepsv/)
 * (@arepsv)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12585549)
 * _I want my clients to be able to make their own license key on the index.php_
 * I tried to make a new license key.
    but failed, the browser only displays http
   error 500 if I try to get the license key, then the $ response is successful
 * index.php (sub.domain.com)
    LMFWC ( instaled in my wordpress site domain.com )
 *     ```
       <?php
       $curl = curl_init();
   
       curl_setopt_array($curl, array(
         CURLOPT_URL => "http://domain.com/wp-json/lmfwc/v2/licenses?consumer_key=ck_e85b2e88e5f5d597e6203687663b5dc331b24bdf&consumer_secret=cs_e85df435670679aa3d6a5aa1d8db7fc35a186e91",
         CURLOPT_RETURNTRANSFER => true,
         CURLOPT_ENCODING => "",
         CURLOPT_MAXREDIRS => 10,
         CURLOPT_TIMEOUT => 0,
         CURLOPT_FOLLOWLOCATION => false,
         CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
         CURLOPT_CUSTOMREQUEST => "POST",
         CURLOPT_POSTFIELDS =>"{
       	"product_id": "1777",
       	"license_key": "ECHOES-SILENCE-PATIENCE-AND-GRACE",
       	"valid_for": "365",
       	"status": "active",
       	"times_activated_max": 1
       }",
         CURLOPT_HTTPHEADER => array(
           "Content-Type: application/json"
         ),
       ));
   
       $response = curl_exec($curl);
       $err = curl_error($curl);
   
       curl_close($curl);
   
       if ($err) {
         echo "cURL Error #:" . $err;
       } else {
         echo $response;
       }
       ?>
       ```
   
 *  [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * (@drazenbebic)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12585691)
 * [@arepsv](https://wordpress.org/support/users/arepsv/)
 * And what do your PHP error logs say?
 * I would also strongly suggest to first try everything out with POSTMAN: [https://www.postman.com/](https://www.postman.com/)
 * After it works there, you can port your requests to your website.
 *  Thread Starter [arepsv](https://wordpress.org/support/users/arepsv/)
 * (@arepsv)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12586898)
 * **#SOLVED**
 * {“success”:true,”data”:{“id”:”9″,”orderId”:null,”productId”:”1777″,”licenseKey”:”
   ECHOES-SILENCE-PATIENCE-AND-GRACE”,”expiresAt”:null,”validFor”:”365″,”source”:”
   3″,”status”:”3″,”timesActivated”:null,”timesActivatedMax”:”1″,”createdAt”:”2020-
   03-26 13:05:18″,”createdBy”:”1″,”updatedAt”:null,”updatedBy”:null}}
 * I want to ask,
    response [‘status’] = 1,2,3 etc, what does that represent? 2 
   = license active ..? please explain..
 *  [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * (@drazenbebic)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12588320)
 * Hello [@arepsv](https://wordpress.org/support/users/arepsv/)
 * Take a look at the status enumerator here:
 * [https://plugins.trac.wordpress.org/browser/license-manager-for-woocommerce/trunk/includes/enums/LicenseStatus.php](https://plugins.trac.wordpress.org/browser/license-manager-for-woocommerce/trunk/includes/enums/LicenseStatus.php)
 * 1 = SOLD
    2 = DELIVERED 3 = ACTIVE 4 = INACTIVE

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘HTTP ERROR 500’ is closed to new replies.

 * ![](https://ps.w.org/license-manager-for-woocommerce/assets/icon-256x256.gif?
   rev=2824216)
 * [License Manager for WooCommerce](https://wordpress.org/plugins/license-manager-for-woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/license-manager-for-woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/license-manager-for-woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/license-manager-for-woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/license-manager-for-woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/license-manager-for-woocommerce/reviews/)

## Tags

 * [api](https://wordpress.org/support/topic-tag/api/)
 * [manager](https://wordpress.org/support/topic-tag/manager/)
 * [rest](https://wordpress.org/support/topic-tag/rest/)
 * [validation](https://wordpress.org/support/topic-tag/validation/)

 * 5 replies
 * 2 participants
 * Last reply from: [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/http-error-500-181/#post-12588320)
 * Status: resolved