Skip to content

Flexmonster custom data source API server to load and visualize the data from any data source

License

Notifications You must be signed in to change notification settings

flexmonster/api-data-source

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flexmonster custom data source API server (beta version)

Flexmonster custom data source API is designed for summarized data retrieval from a server to Flexmonster Pivot.

This API will work for projects with their own data access layer, where filtering and aggregation are delegated to a server and Flexmonster receives ready-to-show data.

Sample Node.js server

Inside the /server-nodejs folder you can find the sample Node.js server that implements Flexmonster's custom data source API. All requests from Flexmonster Pivot Table are handled by http://localhost:3400/api/cube endpoints. Raw data is stored in JSON format in the /server-nodejs/data folder. The file name matches the index property of the dataSource configuration object.

To start the server:

cd server-nodejs
npm install
npm start

On the client-side, the configuration looks as follows (check /client/index.html):

new Flexmonster({
    container: "#pivot",
    report: {
        "dataSource": {
            "type": "api",
            "url": "http://localhost:3400/api/cube",
            "index": "fm-product-sales"
        }
    }
});

Sample .NET Core server

Inside the /server-dotnetcore folder you can find another Flexmonster's custom data source API implementation - sample .NET Core server. All requests from Flexmonster Pivot Table are handled by http://localhost:3400/api/cube endpoints. Raw data is stored in JSON format in the /data folder. The file name matches the index property of the dataSource configuration object.

To start the server:

cd server-dotnetcore
dotnet run

On the client-side, the configuration looks like in Sample Node.js server

About

Flexmonster custom data source API server to load and visualize the data from any data source

Topics

Resources

License

Stars

Watchers

Forks

Contributors 11