Class CallGatewayController

java.lang.Object
com.bytedesk.call.gateway.CallGatewayController

@RestController @RequestMapping("/freeswitch/api/v1/gateways") @ConditionalOnProperty(name="bytedesk.call.freeswitch.enabled", havingValue="true") public class CallGatewayController extends Object
Call网关管理REST API控制器
  • Field Details

  • Constructor Details

    • CallGatewayController

      public CallGatewayController()
  • Method Details

    • createGateway

      @PostMapping public org.springframework.http.ResponseEntity<JsonResult<?>> createGateway(@Valid @RequestBody @Valid CallGatewayRequest request)
      创建网关
    • getGateway

      @GetMapping("/{id}") public org.springframework.http.ResponseEntity<JsonResult<?>> getGateway(@PathVariable Long id)
      获取网关详情
    • getGatewayByName

      @GetMapping("/name/{gatewayName}") public org.springframework.http.ResponseEntity<JsonResult<?>> getGatewayByName(@PathVariable String gatewayName)
      根据名称获取网关
    • getGateways

      @GetMapping public org.springframework.http.ResponseEntity<JsonResult<?>> getGateways(@RequestParam(defaultValue="0") int page, @RequestParam(defaultValue="20") int size, @RequestParam(defaultValue="id") String sortBy, @RequestParam(defaultValue="desc") String sortDir)
      获取网关列表(分页)
    • getEnabledGateways

      @GetMapping("/enabled") public org.springframework.http.ResponseEntity<JsonResult<?>> getEnabledGateways()
      获取启用的网关列表
    • getOnlineGateways

      @GetMapping("/online") public org.springframework.http.ResponseEntity<JsonResult<?>> getOnlineGateways()
      获取在线的网关列表
    • getGatewaysByStatus

      @GetMapping("/status/{status}") public org.springframework.http.ResponseEntity<JsonResult<?>> getGatewaysByStatus(@PathVariable String status)
      根据状态获取网关列表
    • updateGateway

      @PutMapping("/{id}") public org.springframework.http.ResponseEntity<JsonResult<?>> updateGateway(@PathVariable Long id, @Valid @RequestBody @Valid CallGatewayRequest request)
      更新网关
    • enableGateway

      @PutMapping("/{id}/enable") public org.springframework.http.ResponseEntity<JsonResult<?>> enableGateway(@PathVariable Long id)
      启用网关
    • disableGateway

      @PutMapping("/{id}/disable") public org.springframework.http.ResponseEntity<JsonResult<?>> disableGateway(@PathVariable Long id)
      禁用网关
    • updateGatewayStatus

      @PutMapping("/{id}/status") public org.springframework.http.ResponseEntity<JsonResult<?>> updateGatewayStatus(@PathVariable Long id, @RequestParam String status)
      更新网关状态
    • deleteGateway

      @DeleteMapping("/{id}") public org.springframework.http.ResponseEntity<JsonResult<?>> deleteGateway(@PathVariable Long id)
      删除网关
    • getGatewayStats

      @GetMapping("/stats") public org.springframework.http.ResponseEntity<JsonResult<?>> getGatewayStats()
      获取网关统计信息
    • checkGatewayNameExists

      @GetMapping("/exists/{gatewayName}") public org.springframework.http.ResponseEntity<JsonResult<?>> checkGatewayNameExists(@PathVariable String gatewayName)
      检查网关名称是否存在