DEVELOPERS / EMBED GODESK VOICE

The GoDesk phone, inside your own system.

Your CRM, helpdesk, lending, booking or member system shows the GoDesk phone next to the customer. Your people sign in to your system as they do today; the call pops up the right record, a click on a number calls it, and every call comes back to your system with its recording.

This page is for the developers who build it. GoDesk sets up the workspace with you first: request developer access for a test workspace.

Request developer access ↗
HOW IT FITS

Your sign-in, GoDesk's phone.

Three things to build: one call from your server, a script on your page, and an endpoint for the call record.

No second password

Your server vouches for the person already signed in to your system, and GoDesk gives their phone a session for the extension that person owns. Nobody else's.

Screen pop

The moment a call rings, your page is told who is calling, so it can open the customer before the agent answers.

Click to dial

A click on a number in your system calls it from the agent's phone, and says which record the call is about.

The call record

Every finished call is sent to your system, signed, with its talk time, and its recording once it is ready.

Every phone accounted for

Phones only exist for extensions GoDesk has set up, each with a named owner. A phone your server asks for is always someone's.

In the right country

Each country has its own GoDesk Voice server. Your integration is told where to connect, so it works in every region without changes.

REGIONS

Never name a server.

GoDesk Voice has one server per country, and each workspace lives in one. Your key decides the region (gvs_ke_… is Kenya), and every phone session tells you where to connect: load the phone from its sdk address and call the API at its api address. If your system serves people in several countries, it holds one key per workspace and uses the key of the person's workspace.

BEFORE YOU START

What GoDesk sets up with you.

Phones are never made on the fly. Everything below is done by GoDesk or by the workspace's administrator, in that order:

  1. The workspace, in its country's region, with the number of extensions agreed.
  2. The extensions, each with its owner: the user's ID in your system (for example custom:u-42). Someone who owns no extension gets no phone.
  3. The websites allowed to show the phone, for example https://crm.example.co.ke. Until they are named, no phone starts for your system.
  4. Your key: a phone sessions key, held to your servers' addresses. It lives on your server and never in a web page.
  5. Your call record endpoint: an https:// address on your side, with a signing secret.
What you holdWhereWhat it can do
Phone sessions key gvs_<region>_…Your server, used only from the addresses agreedAsk for a phone for one of your users who already owns an extension. Nothing else: it cannot make extensions, change settings or place calls.
Phone session gve_…The page, for one personThat person's phone and their own calls, for 8 hours, renewed while in use, never longer than 24 hours.
Read-only key (optional)Your serverRead the workspace's call history, recordings and transcripts, for reports or catching up. No changes.
Webhook signing secretYour serverCheck that each call record really came from GoDesk.
STEP 1

Your server asks for a phone.

When one of your users opens a page with the phone, your server asks GoDesk for their session, naming them by their ID in your system. GoDesk finds the extension that user owns, or refuses.

POST https://<server>/provision/v1/tenants/<workspace>/sessions
Authorization: Bearer gvs_ke_<workspace>_…
Content-Type: application/json

{ "user": "u-42" }
200
{ "session": "gve_…", "tenant": "<workspace>", "ext": "1002", "name": "Jane Wanjiru", "expires_in": 28800,
  "region": "ke", "region_name": "Kenya",
  "base": "https://<server>", "api": "https://<server>/provision",
  "sdk": "https://<server>/phone/v1/godesk-phone.js" }
AnswerMeaning
403This user owns no extension (or not the one named in ext), or the key was used from an address it is not allowed.
409The user owns several extensions: the answer lists them (below); ask again with "ext".
412The workspace has not named the websites that may show its phone yet.
429Too many requests: wait the Retry-After seconds.
409
{ "error": "this user owns several extensions: say which (ext)",
  "extensions": [ { "ext": "1002", "name": "Jane Wanjiru" }, { "ext": "1010", "name": "Sales desk" } ] }

Rule: the page gets only the session and the sdk address. The key never leaves your server.

STEP 2

Your page shows the phone.

<script src="SDK_ADDRESS_FROM_THE_SESSION"></script>
<script>
  const phone = GoDeskPhone.init({ session: SESSION_FROM_YOUR_SERVER });

  // screen pop
  phone.on("call.ringing", (e) => {
    if (e.direction === "inbound") openCustomerByNumber(e.from);
  });

  // click to dial, saying which record the call is about
  document.querySelectorAll("[data-call]").forEach((el) =>
    el.addEventListener("click", () => phone.dial(el.dataset.call, "crm:lead:" + el.dataset.lead)));

  // the session ended: ask your server for a new one
  phone.on("session.signed_out", () => location.reload());
</script>

The phone runs in a frame on the GoDesk server: its login and its audio never enter your page, and it works only on the websites the workspace named. The script has no built-in server and connects to the server it was loaded from. Your page needs https:// (browsers allow the microphone only there), and the person allows the microphone once.

Options

OptionMeaning
sessionThe phone session from your server.
positionbottom-right (default) or bottom-left.
opentrue starts the phone open instead of as a small button.
bindTelLinkstrue makes every tel: link on the page call through the phone.
baseOnly if you host the script yourself: https://<server>/phone/v1.

Methods

MethodDoes
dial(number, ref)Calls a number or an extension. ref is optional and says which record the call is about (below).
answer() · hangup()Answers the ringing call; ends or declines a call.
mute(true | false)Mutes or unmutes the microphone.
sendDtmf(digits)Sends keypad tones (0-9, *, #), for menus on the other side.
transfer(target)Passes the call to another extension or number.
signOut()Signs the phone out and ends the session.
show() · hide()Opens or folds the phone. inCall (a property) says whether a call is on.
destroy()Takes the phone off the page and removes everything it added, for single-page apps leaving a view. The session stays valid: call signOut() first to end it, and init() again to bring a phone back.
on(event, fn) · off(event, fn)Listens to an event: fn(payload). "*" listens to all of them: fn(eventName, payload).

Events on the page

EventCarries
call.ringingInbound: direction, from, name. Outbound: direction, to.
call.answereddirection, peer, answered_at, and dialer_ref when the call had a ref.
call.endeddirection, peer, started_at, answered_at, ended_at, billsec (talk seconds), dialer_ref.
state.changedregistered: whether the phone can take and make calls.
dnd.changedon: do not disturb switched on or off.
session.signed_in · session.signed_outWho signed in (tenant, ext, name); the session ended.
readyThe phone has loaded. Commands sent before it wait and are not lost.

Rule: page events are for the screen. Keep the call record from the webhooks in step 3, which arrive even if the page was closed.

The ref: which record a call is about

Three parts separated by colons: your system (up to 20 lower-case letters or digits), the kind of record (up to 20 lower-case letters, digits or _) and its ID (up to 40 letters, digits, _ or -). For example crm:lead:4711 or acme:ticket:T-889. Anything else is ignored. It comes back in the page events and as reference in the live webhooks, with the call's call_id.

STEP 3

Your system receives every call.

GoDesk posts each event to your endpoint as JSON, signed. Answer 2xx quickly; anything else is retried with growing gaps for several hours.

Rule: de-duplicate on call_id + event. A delivery can arrive more than once.

EventWhenUse it for
call.ringingAn agent's phone rings, or their outgoing call rings the numberLive boards; it carries the reference of a call placed from a record.
call.answeredThat call is answeredLive boards and timers.
call.endedEvery finished call, answered or notThe call record: direction, numbers, extension, start, answer and end times, talk time, outcome, queue.
call.recordedAn answered call's recording is readyA signed link to the recording, valid for 6 hours; download it to keep it.
X-GoDesk-Signature: t=1764064744, v1=5d41402abc4b2a76b9719d911017c592...

{ "event": "call.ended", "tenant": "<workspace>", "call_id": "1764064742.2214",
  "direction": "outbound", "ext": "1002", "from": "1002", "to": "0712345678",
  "started_at": "2026-11-25T12:59:02+0300", "answered_at": "2026-11-25T12:59:11+0300",
  "ended_at": "2026-11-25T13:03:44+0300", "duration": 282, "billsec": 273,
  "disposition": "ANSWERED", "queue": "" }
{ "event": "call.recorded", "tenant": "<workspace>", "call_id": "1764064742.2214",
  "direction": "outbound", "ext": "1002", "from": "1002", "to": "0712345678",
  "started_at": "2026-11-25T12:59:02+0300", "answered_at": "2026-11-25T12:59:11+0300",
  "ended_at": "2026-11-25T13:03:44+0300", "duration": 282, "billsec": 273,
  "disposition": "ANSWERED", "queue": "",
  "recording_url": "https://<server>/provision/rec?file=…&exp=…&sig=…",
  "transcription": null }

recording_url streams the recording (WAV) with no key: the link is its own signature and works for 6 hours. Download it when the event arrives; a retried event carries a fresh link.

Checking a delivery. Compute HMAC-SHA256(secret, t + "." + raw body) and compare it with v1 in constant time. Accept t within 5 minutes of your clock and keep the clock on NTP; every attempt, retries included, carries a fresh t.

call.ended and call.recorded carry the same call_id as the live events, so a call placed from a record (its reference came in call.ringing) lands on that record.

Rule: one call, one entry. If your system is also kept in step with GoDesk through the Connector Standard, take calls from one of the two: leave calls off on that connection, or do not log them from these events.

OPTIONAL

Calls from your server, and the history.

Your server can also place a call for the person, for example from a button in a back-office screen, with that person's own phone session as the key. Their phone rings first; when they answer, GoDesk dials the number with the workspace's own rules (caller ID, recording, limits).

POST https://<server>/provision/v1/tenants/<workspace>/calls
Authorization: Bearer gve_…
Idempotency-Key: lead-4711-call-1

{ "from_ext": "1002", "to": "0712345678", "reference": "crm:lead:4711" }

reference here is free text up to 100 characters, shown on the agent's phone and returned in the live webhooks. Use the same system:kind:id form as the phone's ref, so one piece of code files calls from both.

The full contract is published as OpenAPI on each server at https://<server>/panel/openapi/calls-v1.yaml. For reports, a read-only key reads the workspace's call history and recordings (GET /tenants/<workspace>/calls); ask GoDesk for one.

SECURITY

What your team must do.

  • Keep the key on your server. Tell GoDesk the addresses it calls from, and never put it in a page, an app or a repository.
  • Ask for a phone only for the person signed in to your system, by their own ID, after your own sign-in checks.
  • Serve the pages that show the phone over https://, from the websites the workspace named.
  • Check every webhook's signature and time, and receive deliveries only on an https:// endpoint.
  • Treat recordings and call records as personal data: download, store and delete them under your own rules.
  • If a key may have leaked, ask the workspace to revoke it and issue a new one.

On our side, a phone exists only for an extension GoDesk set up with a named owner, it uses a browser line of its own (never a desk phone's login), and it works only on the named websites. Taking someone off an extension signs their phone out at once.

GOING LIVE

Checklist.

  1. Each of your users who calls owns an extension, under the ID your server sends.
  2. The websites that show the phone are named, all on https://.
  3. Your key is on your server only, held to its addresses, and your code never names a server: it uses the sdk address from the session.
  4. Your endpoint checks the signature, answers 2xx fast and ignores repeats.
  5. Calls are logged in your system once (webhooks or Connector Standard, not both).
  6. One test call each way with two-way audio, from a real agent's browser.
VENDORS, INTEGRATORS, SOFTWARE HOUSES

Put calling inside your product.

Build it once and every client on GoDesk, in any of our regions, gets calling inside your system. Tell us about your system and we will set up a test workspace with you.

Request developer access ↗