2016-08-22 3 views

답변

1

REST API를 통해 수행 할 수 있습니다. https://www.twilio.com/docs/api/rest/making-calls.

빠른 예는 다음과 같이 보일 것입니다 :

# Download the Python helper library from twilio.com/docs/python/install 
from twilio.rest import TwilioRestClient 

# Your Account Sid and Auth Token from twilio.com/user/account 
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" 
auth_token = "your_auth_token" 
client = TwilioRestClient(account_sid, auth_token) 

# The following grabs a list of numbers that have sent a message to my Twilio number. 
call_list = client.messages.list(to='+1415XXXXXXX') 

# Then loop through all the numbers in the list and send a call from Twilio number via REST API. 
for c in call_list: 
    client.calls.create(to=c.from_, from_="+1415XXXXXXX", url='YOUR_VOICE_URL') 
+1

감사합니다! 옵션처럼 보이지만 초당 1 회의 통화도 시나리오에 대한 방해물입니다. 우리는 동시 호출이 필요하고 오직 하나만 연결해야합니다. –

+0

다른 해결 방법이 있는지 확실하지 않습니다. –

+0

@IvanZverev CPS는 [요청시] 수정 될 수 있습니다 (http://ahoy.twilio.com/cps)의 수정 대상입니다. 또한 하나의 호출 선택기를 허용하는 것과 관련하여 아이디어는 1. 아웃 바운드 호출을 API로 배치하고 식별자를 저장하는 것입니다. 2. 첫 번째 사람이 응답하면 REST API를 통해 다른 호출을 삭제할 수 있습니다. –

관련 문제