API - get account name of API key's holder



With callrail API we are able to list accounts that are accessible for a given API key but we are not able to get primary account name whose the API key belongs.
When a user provides us with an API key we need to be able to show them a name associated to the API key, so what we did so far was to call the endpoint /v3/a.json and to pick the first account in the array. However it proved to show wrong name in many cases.

Are we able to get primary account’s details attached to a given API key?


Hi @sghzal, I might need more information on what you’re trying to solve for. API Keys are tied to an application user, and thus have access to all accounts that particular user has access to. There is no definitive ‘primary account’ in that relationship.

Some accounts (those managed in Account Center) have a parent-child relationship, but not all. Are you asking for some indication of the parent account, if that relationship exists? Or something else?


Hi Laura,

What I need is a name for this account, the one of the application user tied to the API KEY.

For example take a company named ACME.

  • ACME has a callrail account.
  • on their callrail account they also have access to more account from other companies they manage:
    • Adams LLC
    • Jast Inc
    • Skiles Group
  • ACME user connects to his callrail’s account and finds the API key from the settings
  • ACME user uses this API to connect callrail API.

In the api when we call the list of accounts for ACME API key and we get the following:

  • Adams LLC
  • Jast Inc
  • ACME
  • Skiles Group

We have no ways to get the account name the API key belongs to, in that case “ACME”.

To make sure there is no confusion: I use the term “account” because that’s where the user connects to access callrail UI with email/password, then opens the settings and grabs his API key. Maybe you are using an other term for that. Maybe I can call it “API key holder’s details”.



Hi @sghzal, API Keys belong to individual users, not the accounts. So in your example the API key is not assigned to ACME. It is assigned to an employee, marketer, or other person affiliated with ACME, who is set up as user in CallRail. That person logs in with their email address & password, then accesses their API Key details. The API key will have access to everything that individual user has access to in the CallRail app, including accounts other than ACME.

To solve for this, you may need to add some Account Selection function in your UI, or have some other means of collecting the details of the specific account your customer wants to connect.


@Laura That won’t solve our issues unfortunately as it’s not how our platform is intended to work. I’ll see how we can workaround.

In the interim please let me know if you have any plan on implementing something that would allow to get unique name of the api key owner.