Sign in
Sign up
Reference Visual Designer Tutorials
    • API Overview
      • API Endpoint
      • Authentication
      • Requests
      • Responses
      • Paging
      • Reason Codes Dictionary
    • Management APIs
      • Accounts
        • Retrieve Account
        • Create Account
        • Update Account
        • Delete Account
        • Account Roles
      • Tags
        • Create Tag
        • Update Tag
        • Get Tag list
        • Retrieve Tag
        • Delete Tag
      • Profiles
        • Create Profile
        • Update Profile
        • Unlink a Profile from an Account
        • Link a Profile to an Organization
        • Unlink a Profile to an Organization
        • Get Profiles List
        • Paging
        • Filtering & Profile Document Inclusion
        • Get Profile Details
        • Get Profile Relationship
        • Get Account Relationship
        • Delete Profile
      • Applications
      • Clients
        • Create a Client
        • Delete a Client
        • Change Client’s Password
        • Get a List of Available Clients
      • Incoming Phone Numbers
        • IncomingPhoneNumber Instance Resource
        • IncomingPhoneNumbers List Resource
        • Local IncomingPhoneNumber Factory Resource
        • Toll-Free IncomingPhoneNumber Factory Resource
        • Mobile IncomingPhoneNumber Factory Resource
        • Attach a phone number to an application
        • Delete a phone number
        • List of Phone Numbers
        • Incoming Phone Number Regex Support
      • Notifications
      • Usage Records
      • Audit Logs
    • Voice APIs
      • Calls
        • Call List Resource URI
        • Making a Call
        • Modifying Live Calls
        • Examples
        • List Filter
        • Paging Information
      • Outgoing Caller ID
      • Conference Management
        • Supported Operations
        • Conference List Resource URI
      • Conference Participants Management
        • Participants List Resource URI
      • Recordings
      • Refers
        • Resource Properties
        • Supported Operations
        • Paging Information
      • SIP Refer Support
    • SMS APIs
      • Outgoing Caller ID
      • Messages
        • Send SMS
        • Get SMS List
        • Get single SMS Information
        • SMS Attributes
      • Email
    • Turnkey Apps APIs
      • SMS for Microsoft Teams
        • Business Customer
        • Manage Mappings
        • Bot details
        • Messages
      • Smart 2FA
        • Sending One-Time Passwords
        • Verifying One-Time Passwords
        • Cancel One-Time Passwords
        • Session Detail Record (SDR)
        • Get list of One-Time Passwords
        • Get a Single One-Time Password
        • Usage Record One-Time Passwords
      • Message Exchange for Cisco UC-One
        • Create Operation
        • Read Operation
        • Update Operation
        • Delete Operation
        • Error Codes
      • Message Exchange for Cisco Webex Teams
        • Create Operation
        • Read Operation
        • Update Operation
        • Delete Operation
      • Call Queuing
        • Create Queue
        • Queue RCML
        • Enqueue RCML
      • Auto Attendant
        • Enterprise
        • User
        • Announcement
        • Auto Attendant System
        • Menu
        • Schedule
        • Phone Number
        • HMAC Key
      • Number Masking
      • Task Router
        • Create Enterprise
        • Get a List of Enterprises
        • Get Single Enterprise
        • Delete Enterprise
        • Create User
        • Get a List of Users
        • Get a Single User
        • Update User
        • Delete user
      • Campaign Manager
        • Business Customers
          • Business Customer Status
          • Create Business Customer
          • Update Business Customer
          • Delete Business Customer
          • Get List of Business Customers
          • Get Single Business Customer
        • User
          • User Role and Status
          • Create User
          • Update User
          • Delete User
        • Get List of Users
        • Get Single User
        • Manage Credits
        • Create Credit
          • Get List of Credits
          • Get Single Credit
        • Campaign
          • Campaign Status
          • Get List of Campaigns
          • Get Single Campaign
    • RCML
      • Overview
        • Interacting with Your Application
        • RCML Verbs
      • Dial
        • Client
        • Conference
        • Number
        • SIP
      • Email
      • Gather
      • Say
        • SSML Reference
      • Play
      • SMS
      • Hangup
      • Pause
      • Redirect
      • Record
      • Reject
      • Refer
docs 1.0
  • docs
    • 1.0
  • docs
  • Enterprise:RCML
  • Enterprise:Refer

Refer

Refer

During a programmable SIP call, the RCML <Refer> verb instructs Restcomm to initiate a SIP Refer (i.e transfers) towards a SIP infrastructure and handles any NOTIFY messages.

Refer Attributes

Name Allowed Values Default Value

action

relative or absolute URL

no default for <Refer>

method

GET, POST

POST

  • action. The 'action' attribute takes a URL as an argument. When the refer call ends, Restcomm will make a GET or POST request to this URL including the parameters below. If you provide an 'action' URL, Restcomm will continue the current call after the refer finished, using the RCML received in your response to the 'action' URL request. Any RCML verbs occuring after a <Refer> which specifies an 'action' attribute are unreachable. If no 'action' is provided, <Refer> will finish and Restcomm will move on to the next RCML verb in the document. If there is no next verb, Restcomm will end the phone call.

  • method. The 'method' attribute takes the value 'GET' or 'POST'. This tells Restcomm whether to request the URL via HTTP GET or POST.

Refer Action Request HTTP Parameters

The Restcomm parameters passed to your application in its asynchronous request to the Refer action URL. The list of basic parameters can be found in the RCML Voice Request documentation.

The <Refer> request also passes these additional parameters:

Parameter Description

ReferCallStatus

This provides the application with our understanding (based on SIP NOTIFY messages) of the status of the new call created in response to the REFER. If the REFER fails or the endpoint does not send any NOTIFY requests, this parameter will be omitted.

ReferSipResponseCode

The SIP response code received in response to the REFER request Restcomm sends to the SIP endpoint.

NotifySipResponseCode

This is the last SIP response code received on the referred leg, as determined by examining the SIP NOTIFY messages. E.g. If the SIP endpoint initiated a new call but received a SIP 404 response due to the target not being found, this parameter would be set to "404". If the REFER fails or the endpoint does not send any NOTIFY requests, this parameter will be omitted.

Nesting

You must nest the following nouns within <Refer>: SIP

Examples

For examples of how to use the <Refer> verb see below.

Refer to a phone number.

<Response>
    <Refer>
        <Sip>sip:phone_number@domain.com</Sip>
    </Refer>
</Response>

Refer to a phone number with request follow actions.

<Response>
    <Refer action="/handleRefer" method="GET">
        <Sip>sip:phone_number@domain.com</Sip>
    </Refer>
</Response>

Refer Call Flows

The following flow diagrams illustrate the possible call flow scenarios for the RCML <Refer> verb.

Successful Unattended Transfer

The diagram below outlines dialing to a Restcomm IVR. After the subscruber press a digit, call transfered to the destination subscriber.

Successful Unattended Transfer Call Flow
Contact Us

+1 (650) 263 6146

SALES

SUPPORT

GENERAL

Follow Us

Turnkey Applications

SMART 2FA

MESSAGE EXCHANGE

CISCO WEBEX

CALL QUEUE

Learn

BLOG

TERMS AND CONDITIONS

Additional Links

ABOUT

FAQ'S

PRIVACY POLICY

CONTACT