Reference Turnkey Applications Tutorials Visual Designer
    • REST API
      • Overview
      • API Endpoint
      • Authentication
      • Requests
      • Responses
      • Paging
      • Reason Codes Dictionary
    • Management APIs
      • Accounts
      • 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
    • Voice
      • Calls
        • Call List Resource URI
        • Making a Call
        • Modifying Live Calls
        • Examples
        • List Filter
        • Paging Information
      • Conference Management
        • Supported Operations
        • Conference List Resource URI
      • Conference Participants Management
        • Participants List Resource URI
      • Recordings
      • SIP Refer Support
    • SMS
      • Messages
        • Send SMS
        • Get SMS List
        • Get single SMS Information
        • SMS Attributes
      • Email
    • RCML
      • Overview
        • Interacting with Your Application
        • RCML Verbs
      • Dial
        • Client
        • Conference
        • Number
        • SIP
      • Email
      • Gather
      • Say
      • Play
      • SMS
      • Hangup
      • Pause
      • Redirect
      • Record
      • Reject
    • Turnkey Apps APIs
      • Smart 2FA
        • Send OTPs
        • Verify OTPs
        • Control OTPs
        • Limit
          • Create Limit
          • Update Limit
          • Delete Limit
          • Get List of Limits
      • Call Queuing
      • Auto Attendant
        • User
        • Announcement
        • Auto Attendant System
        • Menu
        • Schedule
        • Phone Number
        • RCML
        • Usage Records
      • Number Masking
        • Application
        • Mask Number Pool
        • Context
        • Participants
        • Interactions
        • Usage Records
      • Task Router
      • Campaign Manager
        • Create Campaign
        • Update Campaign
        • Delete Campaign
        • Get List of Campaigns
        • Get Single Campaign
        • Get List of Credits
        • Get Single Credit
docs 1.0
  • docs
    • 1.0
  • docs
  • Enterprise:Management APIs
  • Enterprise:Accounts

Account

Enterprise Accounts

Accounts are useful for checking accounts related data, such as Account SID, Auth token, Status, registered numbers and more.

Account Resource URI

/2012-04-24/Accounts/{AccountSid}

Get Account Information

HTTP GET

Returns the representation of an Account resource, including the properties above.

  • Account Resource URI. /2012-04-24/Accounts/{EmailAddress}

Response Headers

Header Description

Link

a link to the effective Profile document with attribute "rel" set to "related"

Update Account Information

HTTP PUT. Modifies an Account resource and returns the representation, including the properties above. Below you will find a list of optional parameters.

Request Parameters

Parameter Description

FriendlyName

A description of this account, up to 64 characters long.

Status

The status of this account. Possible values are active, suspended, and closed.

Password

A password that will be used to generate the AuthToken for the new Account resource.

Examples

Get information about the account.

curl -X GET https://mycompany.restcomm.com/restcomm/2012-04-24/Accounts/ACCOUNT_SID.json  \
   -u 'YourAccountSid:YourAuthToken'
const request = require('request');

// Provide your Account Sid and Auth Token from your Console Account page
const ACCOUNT_SID = 'my_ACCOUNT_SID';
const AUTH_TOKEN = 'my_AUTH_TOKEN';

request({
      method: 'GET',
      url: 'https://mycompany.restcomm.com/restcomm/2012-04-24/Accounts/' + ACCOUNT_SID + '.json',
      auth: { 'user': ACCOUNT_SID, 'pass': AUTH_TOKEN }
   },
   function (error, response, body) {
      // Add your business logic below; status can be found at 'response.statusCode' and response body at 'body'
      ...
   }
);
from http.client import HTTPSConnection
from base64 import b64encode

# Provide your Account Sid and Auth Token from your Console Account page
ACCOUNT_SID = 'my_ACCOUNT_SID'
AUTH_TOKEN = 'my_AUTH_TOKEN'

userAndPass = b64encode(bytes(ACCOUNT_SID + ':' + AUTH_TOKEN, 'utf-8')).decode("ascii")
headers = { 'Authorization' : 'Basic %s' %  userAndPass }

conn = HTTPSConnection('mycompany.restcomm.com')
conn.request("GET", '/restcomm/2012-04-24/Accounts/' + ACCOUNT_SID + '.json',
      headers=headers)
res = conn.getresponse()

# Add your business logic below; status can be found at 'res.status', reason at 'res.reason' and response body can be retrieved with res.read()
...
import java.net.URL;
import javax.net.ssl.HttpsURLConnection;
import java.io.*;
import java.util.Base64;

public class JavaSampleClass {
   // Provide your Account Sid and Auth Token from your Console Account page
   public static final String ACCOUNT_SID = "my_ACCOUNT_SID";
   public static final String AUTH_TOKEN = "my_AUTH_TOKEN";


   public static void main(String[] args) throws Exception {
      String userAndPass = ACCOUNT_SID + ':' + AUTH_TOKEN;
      String encoded = Base64.getEncoder().encodeToString(userAndPass.getBytes());

      URL url = new URL("https://mycompany.restcomm.com/restcomm/2012-04-24/Accounts/" + ACCOUNT_SID + ".json");
      HttpsURLConnection conn = (HttpsURLConnection)url.openConnection();
      conn.setRequestProperty("Authorization", "Basic " + encoded);
      conn.setRequestMethod("GET");

      // Add your business logic below; response code can be obtained from 'conn.getResponseCode()' and input stream from 'conn.getInputStream()'
      ...
  }
}

Account Attributes

Attribute Description

Sid

A string that uniquely identifies this account.

DateCreated

The date that this account was created.

DateUpdated

The date that this account was last updated.

FriendlyName

A description of this account, up to 64 characters long. By default the FriendlyName is your email address.

Role

The role of the account. Can be Administrator, Developer or ProvisioningAgent. Administrator has full access rights on all platform resources. Developer is like Administrator but is not allowed to manage sub-accounts. ProvisioningAgent is like Developer but is not allowed to read the actual text of SMS messages and cannot remove Recordings.

Status

The status of this account. Possible values are active, suspended, and closed.

AuthToken

The authorization token for this account. This should not be shared.

Uri

The URI for this account, relative to https://$DOMAIN/restcomm/2012-04-24/.

Distributed Request Processing

The CPaaS platform has a distributed microservice architecture, that enables linear scalability during traffic growth and handles a high volume of REST API requests, voice calls, and SMS messages. Each architecture component handles different types of requests.

When you modify the provisioning data via the Management REST APIs, up to few minutes are needed for the update to reflect the changes in all call processing units that handle calls and SMS. Provisioning data modifications are done using the HTTP POST, PUT and DELETE methods. The POST method updates records immediately with no delay during the operation.

Distributed request processing is available for the following Management APIs, as well as the CPaaS Console.

  • Accounts

  • Clients

  • Incoming Phone Numbers

Platform

Programmable Voice

Programmable SMS

Turnkey Applications

Smart 2FA

Call Queue

Auto Attendant

Number Masking

Task Router

Campaign Manager

Learn

Terms And Conditions

About

ABOUT

CONTACT US

© 2020, All rights reserved.