# LEAPWORK API  
```  v4  ```  
``` OAS 3.0 ```

### Integrations

#### GET
/api/v4/schedules  
**Get All Schedules**

/api/v4/run/{runId}  
**Get Run by Id**

/api/v4/run/{runId}/status  
**Get Run Status by Run Id**

/api/v4/schedules/hierarchy  
**Get Schedules Hierarchy**

/api/v4/runItems/{runItemId}  
**Get Run Item by Id**

/api/v4/schedules/run/{runId}  
**Get All Schedules**

/api/v4/run/{runId}/runItemIds  
**Get Run Item Ids by Run Id**

/api/v4/schedules/{scheduleId}  
**Get Schedule by Id**

/api/v4/schedules/{scheduleName}  
**Get All Schedules**

/api/v4/schedules/{scheduleName}/paginated  
**Get All Schedules (Paginated)**

/api/v4/runItems/{runItemId}/video  
**Get Run Item Video**

/api/v4/runItems/{runItemId}/report  
**Get Run Item PDF Report**

/api/v4/flows/{flowId}/runItems/all  
**Get all run ids by flow id**

/api/v4/flows/{flowId}/runItems/last  
**Get last run id by flow id**

/api/v4/schedules/{scheduleId}/status  
**Get Schedule Run Status**

/api/v4/runItems/{runItemId}/subtitles  
**Get Run Item Video Subtitles**

/api/v4/steps/{runListStepId}/flowInfos  
**Get flow titles by run list's step id**

/api/v4/runItems/{runItemId}/keyframes/{offset}  
**Get Run Item Keyframes**

/api/v4/schedules/{scheduleId}/runIds/{filterBy}  
**Get Run Ids by Schedule Id**

/api/v4/runItems/{runItemId}/screenshot/{screenshotId}  
**Get Run Item Screenshot By ScreenshotId**

/api/v4/runItems/{runItemId}/keyframes/{offset}/{blockTitle}/{logMessage}  
**Get Run Item Keyframes**

/api/v4/runItems/{runItemId}/keyframes/{offset}/{blockTitle}/{logMessage}/paginated  
**Get Run Item Keyframes (Paginated)**

#### PUT
/api/v4/run/{runId}/stop  
**Stop Schedule by Run Id**

/api/v4/run/{runId}/reRunOnAgents  
**Re-Run on Agents**

/api/v4/run/{runId}/reRun/{agentId}  
**Re-Run**

/api/v4/schedules/{scheduleId}/stop  
**Stop Schedule by Schedule Id**

/api/v4/schedules/{scheduleId}/runNow  
**Run Schedule Now**

/api/v4/flows/{flowId}/agent/{agentId}  
**Run Flow by Id**

### Agent

#### GET
/api/v4/agents  
**Get All Agents**

/api/v4/agents/{agentId}  
**Get Agent by Id**

/api/v4/agents/agentsStatuses  
**Get all agents connection statuses**

/api/v4/agents/agentStatus/{agentId}  
**Get agent's connection status**

#### PUT
/api/v4/agents/create/saucelabs  
**Create Sauce Labs**

/api/v4/agents/create/gridlastic  
**Create Gridlastic**

/api/v4/agents/create/lambdatest  
**Create LambdaTest**

/api/v4/agents/create/remoteagent  
**Create Remote Agent**

/api/v4/agents/create/browserstack  
**Create Browser Stack**

/api/v4/agents/create/seleniumgrid  
**Create Selenium Grid**

/api/v4/agents/create/{teamId}/saucelabs  
**Create Sauce Labs**

/api/v4/agents/create/{teamId}/gridlastic  
**Create Gridlastic**

/api/v4/agents/create/{teamId}/lambdatest  
**Create LambdaTest**

/api/v4/agents/update/saucelabs/{agentId}  
**Update Sauce Labs**

/api/v4/agents/create/{teamId}/remoteagent  
**Create Remote Agent**

/api/v4/agents/update/gridlastic/{agentId}  
**Update Gridlastic**

/api/v4/agents/update/lambdatest/{agentId}  
**Update LambdaTest**

/api/v4/agents/create/{teamId}/browserstack  
**Create Browser Stack**

/api/v4/agents/create/{teamId}/seleniumgrid  
**Create Selenium Grid**

/api/v4/agents/update/remoteagent/{agentId}  
**Update Remote Agent**

/api/v4/agents/update/browserstack/{agentId}  
**Update Browser Stack**

/api/v4/agents/update/seleniumgrid/{agentId}  
**Update Selenium Grid**

/api/v4/agents/update/{teamId}/saucelabs/{agentId}  
**Update Sauce Labs**

/api/v4/agents/update/{teamId}/gridlastic/{agentId}  
**Update Gridlastic**

/api/v4/agents/update/{teamId}/lambdatest/{agentId}  
**Update LambdaTest**

/api/v4/agents/update/{teamId}/remoteagent/{agentId}  
**Update Remote Agent**

/api/v4/agents/update/{teamId}/browserstack/{agentId}  
**Update Browser Stack**

/api/v4/agents/update/{teamId}/seleniumgrid/{agentId}  
**Update Selenium Grid**

#### DELETE
/api/v4/agents/delete/{agentId}  
**Deleting Remote Agent**

/api/v4/agents/delete/{teamId}/{agentId}  
**Deleting Remote Agent**

### Variables

#### GET
/api/v4/variables  
**Get All Variables**

/api/v4/variables/{name}  
**Get Variable by Name**

#### PUT
/api/v4/variables  
**Edit Variable by Name**

### ImportExport

#### GET
/api/v4/export/{timeoutMinutes}/{targetItemId}  
**Export**

/api/v4/export/{teamId}/{timeoutMinutes}/{targetItemId}  
**Export**

#### POST
/api/v4/import/{timeoutMinutes}/{targetItemId}  
**Import**

/api/v4/import/{teamId}/{timeoutMinutes}/{targetItemId}  
**Import**

### FlowHierarchy

#### GET
/api/v4/hierarchy/{itemId}  
**Get Hierarchy**

/api/v4/hierarchy/flowinfo/{itemId}  
**Get Flow Info**

#### PUT
/api/v4/hierarchy/create/folder/{itemId}  
**Create Folder Hierarchy**

/api/v4/hierarchy/create/folder/{teamId}/{itemId}  
**Create Folder Hierarchy**

### License

#### GET
/api/v4/license/all  
**Get all licenses, including expired**

/api/v4/license/active  
**Get all active licenses**

/api/v4/license/controllerId  
**Get controller id**

/api/v4/license/refresh-license  
**Refresh license**

#### PUT
/api/v4/license/activate  
**Tries to activate input license**

### Team

#### GET
/api/v4/team/all  
**Get all teams**

### User

#### GET
/api/v4/user/all  
**Get All Users**

/api/v4/user/notActive/{date}/{teamId}  
**Get Users not active since a date**

#### PUT
/api/v4/user/new  
**Create User**

/api/v4/user/password/{userId}  
**Update User Password**

/api/v4/user/{userId}/AddUserToTeams  
**Add User To Teams**

#### DELETE
/api/v4/user/{userId}  
**Delete User By userId**

/api/v4/user/{userId}/RemoveUserFromTeams  
**Remove User From Teams**

### AuditLogs

#### GET
/api/v4/auditlogs/export  
**Export Audit Logs**

#### Schemas

- AgentApiInfo  
- AgentAuthenticationType  
- AgentConnectionStatus  
- AgentConnectionStatusApiResult  
- AgentIntegrationInfo  
- AgentLicenseBlockState  
- ApiRerunOptions  
- ApiRunItemFailReason  
- ApiRunItemStatus  
- ApiRunType  
- ApiScheduleStep  
- ApiScheduleVariable  
- AssetHierarchyApiInfo  
- AuditLogsInfo  
- BrowserName  
- BrowserStackInfo  
- ControllerApiInfo  
- CreateAgentResponse  
- CreateUserResponse  
- CreatedHierarchyItemApiResponse  
- DapperDateTimeOffset  
- DeleteAgentResponse  
- DeleteUserResponse  
- EnumAssetHierarchyType  
- EnvironmentConnectionType  
- EnvironmentParallelization  
- FlowInfoResponse  
- FlowIntegrationInfo  
- FlowShortInfo  
- FlowStatusEnum  
- GetLastRunItemIdApiResponse  
- GridlasticInfo  
- ImportApiResponse  
- KeyFrameIntegrationInfo  
- KeyFrameIntegrationInfoPaginatedApiResponse  
- KeyframeMetadataTypeEnum  
- LSignal  
- LambdaTestInfo  
- LevelEnum  
- LicenseApiInfo  
- MobileDeviceOrientation  
- NewUserInfo  
- ProxyType  
- RemoteAgentInfo  
- ReserveAgentsStrategyEnum  
- ResolutionInfo  
- RunIdsApiResponse  
- RunIntegrationInfo  
- RunItemIdsApiResponse  
- RunItemIntegrationInfoV4  
- RunListStepFlowsResponse  
- RunListStepStartCondition  
- RunListStepStartOrder  
- RunScheduleApiResponse  
- RunStatus  
- SAPLogonMode  
- SauceLabsInfo  
- ScheduleApiInfo  
- ScheduleApiInfoPaginatedApiResponse  
- ScheduleCantRunBehavior  
- ScheduleFlowReportTypeEnum  
- ScheduleHierarchyApiInfo  
- ScheduleInfoWithHierarchy  
- ScheduleIntegrationInfo  
- ScheduleReTryPolicyType  
- ScheduleRecurringApiModel  
- ScheduleRecurringDayApiModel  
- ScheduleRecurringEndType  
- ScheduleRecurringMonthApiModel  
- ScheduleRecurringSmallUnitOfTimeApiModel  
- ScheduleRecurringType  
- ScheduleRecurringWeekApiModel  
- ScheduleRunListStepApiModel  
- SeleniumGridInfo  
- SeleniumGridPlatformType  
- SpecificDayType  
- SpecificDayUnit  
- StartRunApiResponse  
- StatusApiResponse  
- StopApiResponse  
- SupportedTerminalApp  
- TeamApiInfo  
- TeamApiShortInfo  
- UpdateAgentResponse  
- UpdateUserResponse  
- UserApiAccess  
- UserApiInfo  
- UserPasswordInfo  
- UserTeamInfo  
- UserType  
- VariableProxy  
- WebProxyConfigurationInfo
