APIs

This kind of interface is used by sysadmin to set business application, data source and cache.

If adminToken is set by matrixauth.server.adminToken in the parameter when starting matrixauthserver, when calling all interfaces facing sysadmin, you need to set adminToken through the adminToken parameter in the interface parameter, otherwise the interface will report an “administrator token verification failed.” error.

1 Data source setting interface

  • /datasource/add : Add one data source.
Parameter name Required Description
dataSourceName Yes Data source name, unique identification of the data source
dataSourceUrl Yes Data source url
dataSourceDriver Yes Data source driver
dataSourceUserName No Data source user name
dataSourcePassword No Data source password
adminToken No Basis for completing the identity verification of business application administrator
  • /datasource/update : Update one data source.
Parameter name Required Description
dataSourceName Yes Data source name, cannot be modified
dataSourceUrl Yes Data source url
dataSourceDriver Yes Data source driver
dataSourceUserName No Data source user name
dataSourcePassword No Data source password
adminToken No Basis for completing the identity verification of business application administrator
  • /datasource/queryAll : Query all data sources.
Parameter name Required Description
adminToken No Basis for completing the identity verification of business application administrator
  • /datasource/queryByName : Query one data source.
Parameter name Required Description
dataSourceName Yes Data source name
adminToken No Basis for completing the identity verification of business application administrator
  • /datasource/deleteByName : Delete one data source.
Parameter name Required Description
dataSourceName Yes Data source name
adminToken No Basis for completing the identity verification of business application administrator

2 Cache setting interface

  • /cache/add : Add one cache.
Parameter name Required Description
cacheName Yes Cache name, unique identification of the cache
cacheUrl Yes Cache url
cachePassword No Cache password
adminToken No Basis for completing the identity verification of business application administrator
  • /cache/update : Update one cache.
Parameter name Required Description
cacheName Yes Cache name, unique identification of the cache, cannot be modified
cacheUrl Yes Cache url
cachePassword No Cache password
adminToken No Basis for completing the identity verification of business application administrator
  • /cache/queryAll : Query all caches.
Parameter name Required Description
adminToken No Basis for completing the identity verification of business application administrator
  • /cache/queryByName : Query one cache.
Parameter name Required Description
cacheName Yes Cache name
adminToken No Basis for completing the identity verification of business application administrator
  • /cache/deleteByName : Delete one cache.
Parameter name Required Description
cacheName Yes Cache name
adminToken No Basis for completing the identity verification of business application administrator

3 Bussiness application setting interface

  • /application/add : Add one bussiness application.
Parameter name Required Description
appName Yes Name of application, unique identification of application
appToken No If the appToken of the business application is set, the appToken needs to be carried to verify the identity of the business administrator when setting the permission of the application in the future
dataSourceName No The name of the data source used by the business application. If set, the permission information of the business application will be stored in the data source specified by the name; otherwise, the default data source of matrixauthserver will be used
cacheName No The cache name of the business application. If set, the cache specified by the name will be used for the permission information of the business application; otherwise, the cache will not be used for the permission information of the business application
adminToken No Basis for completing the identity verification of business application administrator
  • /application/update : Update one bussiness application.
Parameter name Required Description
appName Yes Name of application, unique identification of application, cannot be modified
appToken No appToken of the application
dataSourceName No The name of the data source
cacheName No Cache name of the business application.
adminToken No Basis for completing the identity verification of business application administrator
  • /application/queryAll : Query all bussiness applications.
Parameter name Required Description
adminToken No Basis for completing the identity verification of business application administrator
  • /application/queryByName : Query one bussiness application.
Parameter name Required Description
appName Yes Name of application
adminToken No Basis for completing the identity verification of business application administrator
  • /application/deleteByName : Delete one bussiness application.
Parameter name Required Description
appName Yes Name of application
adminToken No Basis for completing the identity verification of business application administrator

MatrixAuth-High performance lightweight distributed permission system.