[4] API resources

Last modified by admin on 2023/09/06 09:47

Following API endpoint and resources are exposed to be accessible with appropriate authorization.

1.  GetRolePermisson

Get Resources permission collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
nameStringtrueRole name

Response

ReturnType: Collection(Resource)

Example:

Make a GET request to the http://botcenter.akabot.io/api/roles/{name} URL

image-20230307144502-1.png

Headers:

image-20230307144502-2.png

Response:

image-20230307144502-3.png 2. GetUsers

Get User collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
organizationUnitIdIntegerFalse 
searchuserStringFalseLogin(username)
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: login,asc

Response

ReturnType: Collection(User)

Example:

Make a GET request to the http://botcenter.akabot.io/api/users URL

image-20230307144502-4.png

Params:

image-20230307144502-5.png

Headers:

image-20230307144502-6.png

Response:

image-20230307144502-7.png

3. CreateUser

Adds a new user. HTTP method: Post

Parameters

NameTypeDescription
userDTOUser 

Response

ReturnType: User

Example:

Make a POST request to the http://botcenter.akabot.io/api/users URL

image-20230307144502-8.png

Headers:

image-20230307144502-9.png

Request:

image-20230307144502-10.png

image-20230307144502-11.png

Response:

image-20230307144502-12.png

image-20230307144502-13.png

  1.  
    1.  

4. AddRole

Adds Role for user. HTTP method: Put

Parameters

NameTypeDescription
userRoleDTOUserRole 

Response

ReturnType: StatusCode

Example:

Make a PUT request to the http://botcenter.akabot.io/api/user-add-role URL

image-20230307144502-14.png

Headers:

image-20230307144502-15.png

Request:

image-20230307144502-16.png

image-20230307144502-17.png

Response:

image-20230307144502-18.png

Response Code: 200 

5. RemoveRole

Remove Role from user. HTTP method: Put

Parameters

NameTypeDescription
userRoleDTOUserRole 

Response

ReturnType: StatusCode

Example:

Make a PUT request to the http://botcenter.akabot.io/api/user-remove-role URL

image-20230307144502-19.png

Headers:

image-20230307144502-20.png

Request:

image-20230307144502-21.png

image-20230307144502-22.png

Response:

image-20230307144502-23.png

Response Code: 200

6. AddOrganizationUnits

Adds Organization unit for user. HTTP method: Put

Parameters

NameTypeDescription
UserOrganizationUnitDTOUserRole 

Response

ReturnType: StatusCode

Example:

Make a PUT request to the http://botcenter.akabot.io/api/user-add-organizationUnit URL

image-20230307144502-24.png

Headers:

image-20230307144502-25.png

Request:

image-20230307144502-26.png

image-20230307144502-27.png

Response:

image-20230307144502-28.png

Response Code: 200

7. RemoveOrganizationUnits

Remove Organization unit from user. HTTP method: Put

Parameters

NameTypeDescription
UserOrganizationUnitDTOUserRole 

Response

ReturnType: StatusCode

Example:

Make a PUT request to the http://botcenter.akabot.io/api/user-remove-organizationUnit URL

image-20230307144502-29.png

Headers:

image-20230307144502-30.png

Request:

image-20230307144502-31.png

image-20230307144502-32.png

Response:

image-20230307144502-33.png

Response Code: 200

8. UpdateUser

Update user information. HTTP method: Put

Parameters

NameTypeDescription
userDTOUser 

Response

ReturnType: User

Example:

Make a PUT request to the http://botcenter.akabot.io/api/users URL

Request:

image-20230307144502-34.png

image-20230307144502-35.png

Response:

image-20230307144502-36.png

image-20230307144502-37.png

9. ActivatedUser

Activate or deactivate user. HTTP method: Put

Parameters

NameTypeDescription
activateDTOActivate 

Response

ReturnType: StatusCode

Example:

Make a PUT request to the http://botcenter.akabot.io/api/user-activated URL

image-20230307144502-38.png

Headers:

image-20230307144502-39.png

Request:

image-20230307144502-40.png

image-20230307144502-41.png

Response:

image-20230307144502-42.png

Response Code: 200

10. GetAssociatedProcesses

Returns a collection of all available associated process of a Agent. Supported methods: Get

Parameters

NameTypeDescription
robotKeyString 

Response

ReturnType: Collection(WorkFlow)

Example:

Make a GET request to the http://botcenter.akabot.io/api/robotsservice/GetAssociatedProcesses URL

image-20230307144502-43.png

Params:

image-20230307144502-44.png

Headers:

image-20230307144502-45.png

Response:

image-20230307144502-46.png

  1.  

11. Workflows

Get WorkFlow collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
organizationUnitIdIntegerFalse 
environmentIdIntegerFalseAgent Group ID
environmentNameStringFalseAgent Group Name
workflowIdIntegerFalse 
workflowNameStringFalse 
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: name,asc

Response

ReturnType: Collection(WorkFlow)

Example:

Make a GET request to the http://botcenter.akabot.io/api/work-flows URL

image-20230307144502-47.png

Params:

image-20230307144502-48.png

Headers:

image-20230307144502-49.png

Response:

image-20230307144502-50.png

12. WorkFlowVersion

Get WorkFlow version. Supported methods: Get

Parameters

NameTypeRequiredDescription
workflowIdLongTrue 

Response

ReturnType: String

Example:

Make a GET request to the http://botcenter.akabot.io/api/workflowversion URL

image-20230307144502-51.png

Params:

image-20230307144502-52.png

Headers:

image-20230307144502-53.png

Response:

1.0.12380.19828

13. UpdateWorkFlowVersion

Update version of workflow. Supported methods: Put

Parameters

NameTypeDescription
idIntegerworkflowId
versionString 

Response

ReturnType: Workflow

Example:

Make a PUT request to the http://botcenter.akabot.io/api/work-flows/{id}/version URL

image-20230307144502-54.png

Headers:

image-20230307144502-55.png

Response

image-20230307144502-56.png

14. UploadPackage

Upload package to Packages Repository. Supported methods: Post

Parameters

NameParameter TypeTypeContent Type
packageform-dataFilemultipart/form-data
environmentIdsform-dataArray[long]application/json

Response

ReturnType: Packages

Example:

Make a POST request to the http://botcenter.akabot.io/api/packageupload  URL

image-20230307144502-57.png

Params:

image-20230307144502-58.png

Headers:

image-20230307144502-59.png

Response

image-20230307144502-60.png 15. Environments

Get Agent Group. Supported methods: Get

Parameters

NameTypeRequiredDescription
organizationUnitIdIntegerFalse 
environmentnameStringFalseAgent Group Name
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: name,asc

Response

ReturnType: Collection(Environment)

Example:

Make a GET request to the http://botcenter.akabot.io/api/environments URL

image-20230307144502-61.png

Params:

image-20230307144502-62.png

Headers:

image-20230307144502-63.png

Response:

image-20230307144502-64.png

16. StartJob

Adds a new job and sets it in Pending state for each Agent based on the input parameters and notifies the respective Agents about the pending job. HTTP method: Post

Parameters

NameTypeDescription
jobDTOJob 

Response

ReturnType: Job

Example:

Make a POST request to the http://botcenter.akabot.io/api/jobs-processing URL

image-20230307144502-65.png

Headers:

image-20230307144502-66.png

Request:

image-20230307144502-67.png

image-20230307144502-68.png

Response:

image-20230307144502-69.png

image-20230307144502-70.png StopJob

Cancels or terminates the specified job. Supported methods: Put

Parameters

NameTypeDescription
idIntegerjobId
valueString(STOP, KILL) 

Response

ReturnType: Job

Example:

Make a PUT request to the http://botcenter.akabot.io/api/jobs-processing/{id}/{value} URL

image-20230307144502-71.png

Headers:

image-20230307144502-72.png

Response

image-20230307144502-73.png

17. GetJob

Get job information. Supported methods: Get

Parameters

NameTypeDescription
idIntegerjobId

Response

ReturnType: Job

Example:

Make a GET request to the http://botcenter.akabot.io/api/jobs/{id} URL

image-20230307144502-74.png

Headers:

image-20230307144502-75.png

Response

image-20230307144502-76.png

18. GetJobs

Get Job collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
organizationUnitIdIntegerFalse 
environmentIdIntegerFalseAgent Group ID
robotIdIntegerFalse 
scheduleIdIntegerFalse 
stateStringFalse

(PENDING, RUNNING, STOPPED, FAULTED, SUCCESSFUL).

Supported multiple states, separated by commas

pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: startTime,desc

Response

ReturnType: Collection(Job)

Example:

Make a GET request to the http://botcenter.akabot.io/api/jobs URL

image-20230307144502-77.png

Params:

image-20230307144502-78.png

Headers:

image-20230307144502-79.png

Response:

image-20230307144502-80.png

19. GetRobotMapping

Get robot mapping information. Supported methods: Get

Parameters

NameTypeDescription
licenseKeyStringAgent key
machineNameString 

Response

ReturnType: RobotMappingVM

Example:

Make a GET request to the http://botcenter.akabot.io/api/robotsservice/GetRobotMappings URL

image-20230307144502-81.png

Params:

image-20230307144502-82.png

Headers:

image-20230307144502-83.png

Response:

image-20230307144502-84.png

20. GetRobots

Get Robot collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
organizationUnitIdIntegerFalse 
environmentIdIntegerFalseAgent Group ID
robotIdIntegerFalse 
robot_typeIntegerFalseDEVELOPMENT(0), ASSITANT(1), STAGING(2), PRODUCTION(3)
robot_statusIntegerFalseAVAILABLE(0), BUSY(1), DISCONNECTED(2), UNRESPONSIVE(3)
searchStringFalseAgent name(robot name)
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: name,asc

Response

ReturnType: Collection(Robot)

Example:

Make a GET request to the http://botcenter.akabot.io/api/robots URL

image-20230307144502-85.png

Params:

image-20230307144502-86.png

Headers:

image-20230307144502-87.png

Response:

image-20230307144502-88.png

21. SubmitHeartbeat

Submit status of agent and get list tasks command. Supported methods: Post

Parameters

NameTypeDescription
heartbeatDTOHeartbeatDTO 

Response

ReturnType: HeartbeatData

Example:

Make a POST request to the http://botcenter.akabot.io/api/robotsservice/SubmitHeartbeat URL

image-20230307144502-89.png

Request:

image-20230307144502-90.png

image-20230307144502-91.png

Headers:

image-20230307144502-92.png

Response:

image-20230307144502-93.png

22. SubmitJobState

Submit status of task from agent. Supported methods: Post

Parameters

NameTypeDescription
heartbeatDTOHeartbeatDTO 

Response

Example:

Make a POST request to the http://botcenter.akabot.io/api/robotsservice/SubmitJobState URL

image-20230307144502-94.png

Request:

image-20230307144502-95.png

image-20230307144502-96.png

Headers:

image-20230307144502-97.png

Response:

23. PushLogs

Push log to center. Supported methods: Post

Parameters

NameTypeDescription
robotNameString 
messagesArray(String) 

Response

ReturnType: Bool

Example:

Make a POST request to the http://botcenter.akabot.io/api/logs/v1 URL

image-20230307144502-98.png

Request:

image-20230307144502-99.png

image-20230307144502-100.png

Headers:

image-20230307144502-101.png

Response:

True

24. GetLogs

Get Log collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
robotNameStringFalse 
workflowIdIntegerFalse 
levelIntegerFalseOFF(0), FATAL(1), ERROR(2), WARNING(3), INFORMATION(4), DEBUG(5), VERBOSE(6)
jobIdStringFalse 
queryStringStringFalseKeyword to query from log message
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: timeStamp,desc

Response

ReturnType: Collection(Job)

Example:

Make a GET request to the http://botcenter.akabot.io/api/logs URL

image-20230307144502-102.png

Params:

image-20230307144502-103.png

Headers:

image-20230307144502-104.png

Response:

image-20230307144502-105.png

25. GetAsset

Get asset information. Supported methods: Get

Parameters

NameTypeDescription
assetNameString 
robotKeyString 

Response

ReturnType: AssetVM

Example:

Make a GET request to the http://botcenter.akabot.io/api/studioservice/GetAsset URL

image-20230307144502-106.png

Params:

image-20230307144502-107.png

Headers:

image-20230307144502-108.png

Response:

image-20230307144502-109.png

26. SetAsset

Update value of asset. Supported methods: Post

Parameters

NameTypeDescription
assetVMAssetVM 

Response

ReturnType: Bool

Example:

Make a POST request to the http://botcenter.akabot.io/api/studioservice/SetAsset URL

image-20230307144502-110.png

Request:

image-20230307144502-111.png

image-20230307144502-112.png

Headers:

image-20230307144502-113.png

Response:

True

27. GetQueue

Get Queue collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
nameLongFalseQueue id
queueNameStringFalseQueue name
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: timeStamp,desc

Response

ReturnType: Collection(Queue)

Example:

Make a GET request to the http://botcenter.akabot.io/api/queue URL

image-20230307144502-114.png

Params:

image-20230307144502-115.png

Headers:

image-20230307144502-116.png

Response:

image-20230307144502-117.png28. GetQueuItems

Get QueueItem collections. Supported methods: Post

Parameters

NameTypeDescription
queueNameString 
referenceString 
filterStrategyString (STARTSWITH, EQUALS)For reference
statusString(New, InProgress, Failed, Successful, Abandoned, Retried, Deleted, Expired)Status of queue item, support filter multi value
FromDateTimeCreate date
ToDateTimeCreate date
TopIntLimit item return
SkipIntOffset

Response

ReturnType: Collection(QueueItem)

Example:

Make a POST request to the http://botcenter.akabot.io/api/queue/getQueueItems URL

image-20230307144502-118.png

Request:

image-20230307144502-119.png

image-20230307144502-120.png

Headers:

image-20230307144502-121.png

Response:

image-20230307144502-122.png

29. GetQueueDetails

Get QueueItem collections. Supported methods: Get

Parameters

NameTypeRequiredDescription
idLongtrueQueue id
referenceStringFalse 
exceptionIntegerFalseApplication(0), Business(1)
priorityIntegerFalseHigh(3), Normal(2), Low(1)
statusIntegerFalseNew(0), InProgress(1), Failed(2), Successful(3), Abandoned(4), Retried(5), Deleted(6), Expired(7)
specificDataStringFalseKeyword to query from specificData
startFromDateTimeFalseQuery from starttime
startToDateTimeFalseQuery from starttime
pageIntegerFalsePage number of the requested page
sizeIntegerFalseSize of a page(top)
sortStringFalse

Sorting criteria in the format: property(,asc|desc)

Ex: timeStamp,desc

Response

ReturnType: Collection(QueueItems)

Example:

Make a GET request to the http://botcenter.akabot.io/api/queue/{id}/detail URL

image-20230307144502-123.png

Params:

image-20230307144502-124.png

Headers:

image-20230307144502-125.png

Response:

image-20230307144502-126.png

30. AddQueueItem

Adds a queue item. HTTP method: Post

Parameters

NameTypeDescription
queueNameString 
priorityString(High, Normal, Low) 
referenceString 
robotNameString 
specificDataString 
deadlineDataTime 
postponeDateTime 

Response

ReturnType: HttpStatus

Example:

Make a POST request to the http://botcenter.akabot.io/api/queue/addQueueItem URL

image-20230307144502-127.png

Headers:

image-20230307144502-128.png

Request:

image-20230307144502-129.png

 

Created by admin on 2022/12/26 16:54
  
Navigation