## 1. 세무사견적어플 프로그램 기획
저는 세무사견적어플에서 활동하는 세무사/회계사입니다.
저는 어플을 통해 세무상담 견적을 받습니다.
최근 견적 어플의 경쟁심화로 고객들의 세무 상담 요청에 신속하게 대응하기 위해 파이썬을 활용한 견적 자동화 + 소리알림 프로그램을 개발하게 되었습니다. 본 프로그램은 새로운 상담 요청을 실시간으로 모니터링하고, 자동으로 견적과 상세 설명을 제공함으로써 고객 응대 시간을 최소화하는 것을 목표로 합니다.
코드는 claude 로 작성하였습니다.
https://사이트명/requests/received?from=gnb
여기서 내 아이디로 로그인 한다음에 새로운 request 가 오면 바로 알려주는 기능을 뭘로 만들 수 있을까?[1] Python + Selenium을 이용한 방법:
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
import time
from plyer import notification # 데스크톱 알림용
def check_new_requests(username, password):
driver = webdriver.Chrome()
driver.get("https://사이트주소/requests/received")
# 로그인
# (로그인 폼의 실제 element ID나 class name으로 수정 필요)
driver.find_element(By.ID, "username").send_keys(username)
driver.find_element(By.ID, "password").send_keys(password)
driver.find_element(By.CLASS_NAME, "login-button").click()
previous_requests = None
while True:
try:
# 요청 목록을 가져옴 (실제 element selector로 수정 필요)
requests = driver.find_elements(By.CLASS_NAME, "request-item")
current_requests = len(requests)
if previous_requests is not None and current_requests > previous_requests:
# 새로운 요청이 있을 때 알림
notification.notify(
title='새로운 요청!',
message=f'{current_requests - previous_requests}개의 새로운 요청이 있습니다.',
app_icon=None,
timeout=10,
)
previous_requests = current_requests
time.sleep(60) # 1분마다 체크
driver.refresh()
except Exception as e:
print(f"에러 발생: {e}")
driver.refresh()
time.sleep(60)
driver.quit()이외에도
[2] Python + requests 라이브러리를 이용한 방법 (API가 있는 경우):
[3] 크롬 확장 프로그램으로 만드는 방법도 있습니다:
위의 세가지 방법을 추천하였으나 저는 셀레니움을 이용한 방법으로 진행하기로 하였습니다
왜냐면 claude 가 추천 했기 때문 ㅋㅋ
추천하는 방법은 Python + Selenium 입니다. 이유는:
로그인이 필요한 페이지를 자동화하기 쉽습니다
실제 브라우저를 통해 접근하므로 차단될 가능성이 적습니다
데스크톱 알림을 쉽게 구현할 수 있습니다
코드 수정이 비교적 쉽습니다
사용하시려면 다음과 같은 설치가 필요합니다:
작성중에 카카오톡 알림 설정을 위하여 토큰 발행 등 여러가지 어려움이 있었습니다.