Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Excerpt

The Komet Sales API helps you develop additional tools that are directly tied into the system. This will allow growers, customers or 3rd parties (such as other technology companies or your in-house developers) to expand and build on the Komet Sales platform.

 



The API is an interface for accessing the Komet Sales data using HTTP and JSON. The API makes it easy to create web and desktop applications that integrate with the Komet Sales. Some potential uses include:

  • Creating a customized e-commerce solution that uses Komet Sales as the backend for order processing and inventory management.
  • Allowing the growers to integrate Komet Sales directly into their systems to review/confirm orders.
  • Integrating with your CRM system.
  • Interacting with other 3rd party systems that your company uses.

 


UI Expand
titleHow to use the API

The Komet Sales API has a single point of entry:


Code Block
themeEclipse
https://api.kometsales.com/api/method.action


Please note that all requests must be submitted using SSL. You must send an authentication token per each request. Please use the login method to get your token and save it into your application. You will be able to use the same token from this point forward. You can also create tokens that are not linked to a user and access to a specific set of API methods can be limited.

Please note that the API is limited to 1,000 requests per user per day, based on the plan that the company has in Komet Sales. In other words, if the company is paying for 3 users in Komet Sales, your external system can only call the Komet Sales API 3,000 times (1,000 x 3) per day.

...

UI Expand
titleHow to Test an API Method

In the next example, we use Postman to test API methods. Postman is a API Development Environment. Other API Development Environment include Insomnia, SoapUI, curl, etc.


Within Komet, there are two basic types of request: POST and GET.


Instructions to test POST methods

UI Steps
sizesmall

POST methods are used to send data to a server to create/update a resource.

UI Step

Open the Postman App.


UI Step

Choose the request type (POST).


UI Step

Select the format. This can be selected from the Body Type. In this case, is JSON.


UI Step

Click on the Body tab. Check the raw option. The "Text" dropdown menu and select JSON (application/json).


UI Step

Enter the URL of the request and then proceed to enter the parameters.


UI Step

To enter the parameters, you can copy and paste the sample request. Click on Beautify so the format is corrected.


UI Step

Verify the parameters and once you have finished click on Send. The method should return the results, as it is shown on the documentation response sample.


Instructions to test GET methods


UI Steps
sizesmall

GET methods are used to request data from a specified resource.

UI Step

Open the Postman App.


UI Step

Choose the request type (GET).


UI Step

Enter the URL that correspond to the request.


UI Step

For GET methods, you must enter the URL params.



UI Step

Click on Params. Proceed to enter each input parameter required (e.g. authentication token). Once you have finished, click on Send.



Info
titleInformation

Some methods will require additional information on the header, such as X-SALES-CHANNEL, X-ACCOUNT. This information must be entered in the same way the input parameters are entered.