REST API Introduction - Event Notifications
The Ribbit Platform will generate many different kinds of events. These events may be received via HTTP POSTs to URLs that can be configured for each application in a domain. At present, events are generated for Message and Call resources. These events include but are not limited to:
- New Call Received
- Active Call Status Change (on hold, etc.)
- Low/No Credit Warning
- New Voicemail Message
- New Voicemail Transcription
- New SMS Message
- Message Deleted
Each event will contain the following parameters encoded as a JSON string:
| Name | Value | Notes |
| type | string | Type of event (CallInitiated, for example). |
| time | time | Time the event occurred. |
| resource | uri | The URI corresponding to this event. |
| params | object | Parameters associated with this resource that may have changed as a result of this event. |
Example:
<< POST <notificationUrl>
Json={ "type":"cc_call_vmpickup","time":"2009-03-24T19:24:24Z",
"resource":"http://rest.ribbit.com/rest/1.0/calls/67be2a0c-6c65-102c-a24a-00188b741119/1234",
"params":{ "callid":2608143,
"guid":"cce3cd2d-190c-454a-a4a5-42f2ea3e28ab",
"source":"sip:restQA031009-001@mailinator.com",
"dest":"tel:16503355954"}
} }
>> 200 OK
