This is the Java SDK for Casibase, which allows you to easily call Casibase's API.
The Casibase SDK is very easy to use. We will demonstrate the usage steps below.
Initialization requires 5 parameters, all of which are strings:
Name (in order) | Required | Description |
---|---|---|
endpoint | Yes | Casibase server URL, e.g., https://demo-admin.casibase.com |
clientId | Yes | Client ID |
clientSecret | Yes | Client secret |
organizationName | Yes | Name of the Casibase organization, e.g., casbin |
applicationName | No | Name of the Casibase application, e.g., app-casibase |
Currently, the available service is: TaskService
You can create it like this:
TaskService taskService = new TaskService(config);
TaskService
supports basic task operations, such as:
getTask(String name)
: Get a single task by task name.getTasks()
: Get all tasks under the organizationName.addTask(Task task)/updateTask(Task task)/deleteTask(Task task)
: Write to the database.