contract CKProxy is Pausable {
  KittyCoreInterface public kittyCore;
  AuctionInterface public saleAuction;
  AuctionInterface public siringAuction;

constructor(address payable _owner, address _kittyCoreAddress) Pausable(_owner) public {
    require(_kittyCoreAddress != address(0), 'Invalid Kitty Core contract address');
    kittyCore = KittyCoreInterface(_kittyCoreAddress);
    require(kittyCore.supportsInterface(0x9a20483d), 'Invalid Kitty Core contract');

    saleAuction = AuctionInterface(kittyCore.saleAuction());
    siringAuction = AuctionInterface(kittyCore.siringAuction());
  }

  /**
   * Owner or operator can transfer kitty
   */
  function transferKitty(address _to, uint256 _kittyId) external onlyOwnerOrOperator {
    kittyCore.transfer(_to, _kittyId);
  }

  /**
   * Owner or operator can transfer kittie in batched to optimize gas usage
   */
  function transferKittyBulk(address _to, uint256[] calldata _kittyIds) external onlyOwnerOrOperator {
    for(uint256 i = 0; i < _kittyIds.length; i++) {
      kittyCore.transfer(_to, _kittyIds[i]);
    }
  }

  /**
   * Owner or operator can transferFrom kitty
   */
  function transferKittyFrom(address _from, address _to, uint256 _kittyId) external onlyOwnerOrOperator {
    kittyCore.transferFrom(_from, _to, _kittyId);
  }

  /**
   * Owner or operator an approve kitty
   */
  function approveKitty(address _to, uint256 _kittyId) external  onlyOwnerOrOperator {
    kittyCore.approve(_to, _kittyId);
  }

  /**
   * Owner or operator can start sales auction for kitty owned by contract
   */
  function createSaleAuction(uint256 _kittyId, uint256 _startingPrice, uint256 _endingPrice, uint256 _duration) external onlyOwnerOrOperator {
    kittyCore.createSaleAuction(_kittyId, _startingPrice, _endingPrice, _duration);
  }

  /**
   * Owner or operator can cancel sales auction for kitty owned by contract
   */
  function cancelSaleAuction(uint256 _kittyId) external onlyOwnerOrOperator {
    saleAuction.cancelAuction(_kittyId);
  }

  /**
   * Owner or operator can start siring auction for kitty owned by contract
   */
  function createSiringAuction(uint256 _kittyId, uint256 _startingPrice, uint256 _endingPrice, uint256 _duration) external onlyOwnerOrOperator {
    kittyCore.createSiringAuction(_kittyId, _startingPrice, _endingPrice, _duration);
  }

  /**
   * Owner or operator can cancel siring auction for kitty owned by contract
   */
  function cancelSiringAuction(uint256 _kittyId) external onlyOwnerOrOperator {
    siringAuction.cancelAuction(_kittyId);
  }
}
/**
 * @title CKProxy
 * @dev CKProxy contract allows owner or operator to proxy call to CK Core contract to manage kitties owned by contract
 */
function createSiringAuction(uint256 _kittyId, uint256 _startingPrice, uint256 _endingPrice, uint256 _duration) external onlyOwnerOrOperator {
    kittyCore.createSiringAuction(_kittyId, _startingPrice, _endingPrice, _duration);
  }
/**
 * Owner or operator can start siring auction for kitty owned by contract
 */