Title: API documentation
Last modified: March 29, 2019

---

# API documentation

 *  Resolved [gokuale](https://wordpress.org/support/users/gokuale/)
 * (@gokuale)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/api-documentation-8/)
 * Hello,
    thanks for this plugin, it’s awesome.
 * I would like to ask you if there is an api documentation because this is my situation:
 * i have external generator that create a license key, i would like to import it
   in your plugin and setting days for active license.
    I would like to link this
   license to an order because the external generator creates me a license code 
   after an order is complete.
 * it’s possible for your plugin to manage this?
    thanks a lot

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

 *  [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * (@drazenbebic)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/api-documentation-8/#post-11370683)
 * Hello [@gokuale](https://wordpress.org/support/users/gokuale/),
 * thanks for the input, I’m really happy that you find my plugin useful.
 * Let me just break down your points to see if I understood your scenario correctly:
    - User purchases license on external site
    - External site makes an API request to the plugin
    - Plugin saves the license key and external order ID inside the database
 * Please correct me if I misunderstood something. The API is currently in a small
   rework process, I am adapting the structure of the response and adding some more
   routes. That’s also why I have been delaying the API documentation. However, 
   you can download the current Postman collection here:
 * [https://www.bebic.at/assets/lmfwc.postman_collection.json](https://www.bebic.at/assets/lmfwc.postman_collection.json)
 * The response currently returns the object with the data, for example **lmfwc/
   v1/licenses/{id}** will return:
 *     ```
       {
           "id": "36",
           "order_id": null,
           "product_id": "28",
           "license_key": encrypted license key,
           "hash": hashed lciense key,
           "created_at": "2019-03-25 11:44:04",
           "expires_at": null,
           "valid_for": "120",
           "source": "2",
           "status": "3"
       }
       ```
   
 * This will be changed, the requests will have the following format and all license
   keys will be sent out DECRYPTED instead of ENCRYPTED.
 *     ```
       {
           "success" => true,
           "data" => {
               "id": "36",
               "order_id": null,
               "product_id": "28",
               "license_key": decrypted license key,
               "created_at": "2019-03-25 11:44:04",
               "expires_at": null,
               "valid_for": "120",
               "source": "2",
               "status": "3"
           }
       }
       ```
   
 *  [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * (@drazenbebic)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/api-documentation-8/#post-11399076)
 * I’m closing this topic and marking it as solved, since it has been over a week
   without a reply.

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

The topic ‘API documentation’ 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

 * [backorder](https://wordpress.org/support/topic-tag/backorder/)
 * [key](https://wordpress.org/support/topic-tag/key/)
 * [manager](https://wordpress.org/support/topic-tag/manager/)
 * [pre-order](https://wordpress.org/support/topic-tag/pre-order/)
 * [pre-sale](https://wordpress.org/support/topic-tag/pre-sale/)

 * 2 replies
 * 2 participants
 * Last reply from: [Drazen Bebic](https://wordpress.org/support/users/drazenbebic/)
 * Last activity: [7 years, 1 month ago](https://wordpress.org/support/topic/api-documentation-8/#post-11399076)
 * Status: resolved