Grappster allows you to integrate your own application. This means that we provide you with the option to add the app you have built yourself. The only thing you need to do is to provide endpoints with your counter data that Grappster will automatically load from.
Please note that this is not an option to integrate any app available online. If you use an app and want it to be integrated with Grappster, please contact us with this feature request. We will take your request into consideration and notify you about our decision.
Please follow the steps below to add your own app to Grappster:
Add your own app to Grappster
Make sure you are logged into Grappster.
- Click the "Settings" button.
- Click the "Apps" button in the dropdown menu.
Select "Connect more apps" in the next screen and then click on "Your Own App" in order to add your own app.
Fill in your own app credentials
- Fill in a name for your application
- Fill in your base domain. This is the domain where all your endpoints providing tha data to Grappster are.
- Fill in your username. (Used to grant Grappster access to your app)*.
- Fill in your Token/Password. (Used to grant Grappster access to your app)*.
- Fill in the client endpoint. This is used to import clients from your app into Grappster. This is optional.
- Add a counter endpoint by clicking the green "Add" button.
* Authorization is done using basic authorization with your username and token colon separated and Base64 encoded.
Add a counter endpoint
A screen pops up with a form where you can enter the counter Endpoints. Grappster will only load counter data. e.g. number of sales, number of sign-up etc.
- Fill in a name for the counter Endpoint.
- Fill in the route for this Endpoint.
- You can test the counter Endpoint. By clicking the "Test the endpoint" button you will get a response whether the Endpoint works or not. When the Endpoint is invalid, it will show the error response, e.g.
- Select the relation type linked to the counter.
Global: Use this if the counter you want to load is not linked to a client or other relation but represents a general count.
Client: Use this if the counter you want to load is linked to a client. This means that you provide Grappster with a count for each individual client which in turn makes it possible for Grappster to analyse the count per client.
- Select Time context.
Load one record each day: This will load the current count at the specific time Grappster calls your endpoint. No historical counts will be loaded.
Load several history records each load: This will load historical counts from your endpoint.
- Select the Value Type.
Value is the added value for the specific period: Each date has the added value. E.g. A counter called "New Sales" has the new sales for each particular day.
Value is the total value for the specific period: Each date has a total value. E.g. A counter called "Sales in progress" has the current total amount of sales each particular day which has the status "in progress".
- You can check the examples responses by clicking one of the four links in the grey box. (More details about the model design in the section "Technical documentation" and here)
- Click the "Add" button to add the counter endpoint.
To create another counter endpoint, click the green "Add" button and walk through the process again as explained above.
Modify your Counter Endpoints
Once you have connected your app by clicking "Connect" Grappster will give your counter a color. This color is used to identify the counter in the charts etc. If you want to change the color or the name of the counter you can go into Settings -> Apps and edit your own app connection and then follow the steps below.
- In order to change the color or the name of your counter endpoint click the edit button which can be found to the right of every endpoint block.
- Change the name of your counter endpoint.
- Change the color of the counter endpoint. This will change the color of the blocks and charts in Grappster.
- Click "Save".
Expect Grappster to call your API approximately 4 times a day spread out at unspecified times. That means that your API has to be reachable 24/7 else some loss of data in Grappster might occure.
Authorization and Security
Grappster sends the username and password in the athorization header in each request and uses the Basic access for this.
E.g authorization: Basic username:password where username and password is encoded with Base64
Your API must use HTTPS else Grappster will not be able to call it.
Grappster can only understand JSON in the response which follows the below explained model.
Grappster expects you to follow a specific model. The model is very basic and is implementable in any language.
The different classes provided in the model is used depending on what type of counter you want Grappster to load. (types explained in section "Add a counter endpoint" above).
Note: Do not change any of the property names in the classes. Doing so will unable Grappster to load your data.