Skip to content

Create or update an account

Accounts
POSThttps://api.dcdial.com/api/type=add_account
Changes dataToken

Creates an account with its phone numbers and email addresses, or updates it if an account with the same accountid already exists.

Fields are nested: send them as account[first_name], phones[0][phone_number] and so on, or as a JSON body with Content-Type: application/json.

Parameters

Send as application/x-www-form-urlencoded.

  • typestringrequired

    Selects the operation. Always add_account for this endpoint.

  • tokenstringrequired

    Your API token from Log in. See Authentication.

  • account[company_id]integerrequired

    Your DCDial company ID.

    Example 101
  • account[accountid]stringoptional

    Your reference for the account. If an account with this reference exists, it is updated. If you leave it out, DCDial generates one (for example 2026-04512).

    Example ACC-10045
  • account[first_name]stringoptional

    First name.

    Example Jane
  • account[last_name]stringoptional

    Last name.

    Example Doe
  • account[email]stringoptional

    Primary email address. Defaults to the first of emails.

    Example jane@example.com
  • account[phone]stringoptional

    Primary phone number. Defaults to the first of phones.

    Example 5550100123
  • account[address1]stringoptional

    Address line 1.

    Example 100 Main St
  • account[city]stringoptional

    City.

    Example Atlanta
  • account[state]stringoptional

    Two-letter state code.

    Example GA
  • account[postal_code]stringoptional

    ZIP or postal code.

    Example 30301
  • account[country]stringoptional

    Country code.

    Example US
  • account[balance]numberoptional

    Outstanding balance.

    Example 1250.5
  • account[birthday]stringoptional

    Date of birth (YYYY-MM-DD).

  • account[company_name]stringoptional

    Company name, for business accounts.

  • account[custom1]stringoptional

    Custom fields custom1 to custom20, for your own data.

  • List to add the account's phone numbers and emails to, so campaigns can reach them.

    Example 2048
  • A phone number. Repeat with phones[1], phones[2] … for more.

    Example 5550100123
  • phones[0][phone_type]stringoptional

    Type of the number, for example MOBILE, HOME or WORK.

    Example MOBILE
  • phones[0][time_zone]stringoptional

    UTC offset of the number, such as -6.00. Defaults to US Eastern time.

    Example -5.00
  • emails[0]stringoptional

    An email address. Repeat with emails[1] … for more.

    Example jane@example.com

Notes

This endpoint returns its data without the response wrapper. Use Add an account to a campaign instead if you want the account placed straight into a campaign.

Terminal window
curl https://api.dcdial.com/api/ \
-d type=add_account \
-d token="$DCDIAL_TOKEN" \
-d account[company_id]=101 \
-d account[accountid]=ACC-10045 \
-d account[first_name]=Jane \
-d account[last_name]=Doe \
-d account[balance]=1250.5 \
-d accounts_leads[list_id]=2048 \
-d phones[0][phone_number]=5550100123 \
-d phones[0][phone_type]=MOBILE \
-d emails[0]=jane@example.com
Response · 200 OK
{
"accounts_id": 55120,
"accountid": "ACC-10045",
"success": 1
}

Try it

Environment