Team members
The people who sign in to an account, each with their own login and role. Call these with your own key, and add X-Sub-Account-Id to work on a sub-account’s team. Sub-accounts themselves are on Sub-accounts.
#Add a team member
Adds a person to the team, with their own login and an invite email with a sign-in link. With X-Sub-Account-Id it’s that sub-account’s team. Needs the Manage team permission (invite_team).
Parameters
emailstringRequired- Their login email. The invite goes here.
first_name, last_namestringroleenumDefaultadminadmin: everything, billing and team included (Admin on the Team page).member: send texts and work with contacts and reports, but can’t buy numbers or spend money (Member).viewer: read only.agent: a member who also uses the dialer, which needs a free dialer seat; the Team page shows it as Member. The Team page preset Full teammate has no value here. Left out, role isadmin, which includes billing: sendmemberunless the person should manage billing and the team.sub_account_accessenumall: they can also open your sub-accounts.organization_only: they work in your main account only. Left out, Ready picks it the way the Team page does.X-Sub-Account-Idinteger · header- The sub-account to add them to. Leave it out to add them to your own account.
Returns 201 with data.id (their user id) and data.email.
Errors
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_request | Missing email, or a role not in the list. |
| 400 | unknown_field | A field it doesn’t accept. |
| 400 | already_on_team | They’re already on this team, or it’s the owner’s email. Nothing to do. |
| 403 | permission_grant_exceeds_your_own | The role has more access than the key’s user. |
| 403 | sub_account_forbidden | Not a sub-account you manage. Nothing was added. |
| 403 | forbidden | No dialer seat free for an agent. |
| 403 | permission_denied | The key’s user can’t manage the team. |
| 500 | internal_error | It may or may not have been added. Check the team in Ready before you send it again. |
#List team members
The people on the team, newest first, as the Team page lists them. Sub-accounts aren’t in it: use List sub-accounts. With X-Sub-Account-Id it’s that sub-account’s team. Needs the Manage team permission (invite_team).
Returns
data[]object[]- One per person:
id,email,first_name,last_name,role,status,invite_status(pendinguntil they sign in the first time, thenactive),invite_expired,sub_account_access,holds_dialer_seatandcreated_at.
Errors
| HTTP | Code | When |
|---|---|---|
| 403 | permission_denied | The key’s user can’t manage the team. |
| 500 | internal_error | The list couldn’t be read. Retry. |
#Update a team member
Changes a person’s name, role or sub-account access. Send only what you want to change. A role change signs them out, so their next sign-in has the new access. Needs the Manage team permission (invite_team).
Parameters
idinteger · pathRequired- Their
idfrom List team members. first_name, last_namestringroleenum- The same roles as Add a team member.
agentneeds a free dialer seat. sub_account_accessenumallororganization_only.
Returns data.id. Their email can’t be changed with an API key.
Errors
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_request, unknown_field | Nothing to change, a role not in the list, or a field it doesn’t accept. |
| 403 | permission_grant_exceeds_your_own | The change gives them more access than the key’s user has. Nothing changed. |
| 403 | cannot_edit_own_access | The key’s user is changing their own role or access. |
| 403 | forbidden | No dialer seat free for agent (other changes you sent were saved). |
| 403 | permission_denied | The key’s user can’t manage the team. |
| 404 | member_not_found | No one on this team has that id. |
| 500 | internal_error | Some changes may have saved. List the team before you send it again. |
#Resend a team invite
Emails a new invite with a new sign-in link. Links in earlier invites stop working. Send an Idempotency-Key header so a retry doesn’t send a second email. Needs the Manage team permission (invite_team).
Parameters
idinteger · pathRequired- Their
idfrom List team members.
Returns data.id, data.email and data.expires_at (when the new link stops working).
Errors
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_request, unknown_field | id isn’t a whole number, or the body has a field. |
| 404 | member_not_found | No one on this team has that id. |
| 403 | permission_denied | The key’s user can’t manage the team. |
| 500 | internal_error | The new link could not be made. Send it again. |
| 502 | internal_error | The new link was made but the email did not go out, and links in earlier invites no longer work. Send it again. |
See also: the guide to doing this in the app.