Skip to navigation

Reception API quickstart

Create a customer's workspace, sell it a plan, and put its receptionist on a phone number.

This guide provisions one customer end to end with the Reception API: a workspace on a paid plan, a business profile for the receptionist to answer from, and a phone number that rings it.

Prerequisites

  • An API key from the reseller admin panel, set as ELEVENLABS_API_KEY. The admin panel is open to Reception.ai partners only; to become one, contact our sales team.
  • A card on file for your reseller account. Subscribing a workspace charges it.
  • The Python SDK (pip install elevenlabs) or the TypeScript SDK (npm install @elevenlabs/elevenlabs-js).

Provision a customer

1

Choose a plan

List the tiers you sell. They come cheapest first, and the first one is the trial.

from elevenlabs import ElevenLabs
elevenlabs = ElevenLabs()
tiers = elevenlabs.reception.tiers.list()
for tier in tiers:
print(tier.tier_id, tier.display_name, tier.tier_economics.monthly_price_usd)
2

Create the workspace

Create the customer’s workspace, subscribe it to a paid tier, and invite the business owner. Invites are best-effort: each one’s result is in member_results.

from elevenlabs import ProvisionResellerWorkspaceSubscription, TeamInviteRequest
workspace = elevenlabs.reception.workspaces.create(
business_name="Bright Smile Dental",
subscription=ProvisionResellerWorkspaceSubscription(
tier_id=tiers[1].tier_id,
billing_period="monthly_period",
),
members=[
TeamInviteRequest(email="owner@brightsmiledental.com", role="workspace_admin"),
],
)
workspace_id = workspace.workspace_id

Omit subscription to create a workspace without a plan and assign one later.

3

Describe the business

The receptionist answers from the business profile. From here on, every call acts on the new workspace, so it carries the xi-workspace-id header. Days in operating_hours run from 0 (Monday) to 6 (Sunday), and a day with no entry is closed.

from elevenlabs import TimeRangeModel, WorkingHours
weekday = [TimeRangeModel(start_hour=8, start_minute=0, end_hour=17, end_minute=0)]
elevenlabs.reception.business_profile.update(
xi_workspace_id=workspace_id,
business_country="US",
business_description="Family dental practice offering cleanings, fillings, crowns and teeth whitening.",
timezone="America/Los_Angeles",
operating_hours=WorkingHours(hours={str(day): weekday for day in range(5)}),
)
elevenlabs.reception.knowledge_sources.add_url(
xi_workspace_id=workspace_id,
url="https://brightsmiledental.com",
crawl_entire_site=True,
)

Services, staff, locations and holidays are added the same way, with the services, staff, locations and holidays groups.

4

Finish onboarding

Completing onboarding creates the workspace’s receptionist from the business profile. It is safe to retry. You can also pass complete_onboarding=True when you create the workspace, but the receptionist is then built from the business name alone.

onboarding = elevenlabs.reception.workspaces.complete_onboarding(workspace_id)
receptionist_id = onboarding.customer_facing_agent_id
5

Give the receptionist a phone number

In the US and Canada, a number with one of the requested area codes is taken from the pool or bought, falling back to any number in the business’s country.

assignment = elevenlabs.reception.phone_numbers.create(
xi_workspace_id=workspace_id,
customer_facing_agent_id=receptionist_id,
area_codes=["415", "628"],
)
print(assignment.phone_number)

The receptionist now answers calls to phone_number.

Next steps