Create workspace in account of my organisation through the API? | Community
Skip to main content
Question

Create workspace in account of my organisation through the API?

  • July 3, 2025
  • 1 reply
  • 19 views

My organisation has a an “organisation” at Typeform of which my colleague is the owner and I am a member. I have registered an application there. I have used OAuth 2.0 to generate an access token for that application, as per these instructions:

https://www.typeform.com/developers/get-started/applications/

However, workspaces created using this access token appear in my personal account and not in my organisation’s account.

In the documentation of the API I read
 

“The workspace gets created in the account where the user has the organisation role - owner.”

This confuses me, because I would think a user might be owner of several organisations. Moreover, it would preclude control over where the workspace is created. It seems I can create workspaces in my organisation's account through the the web interface. It also seems I can choose the workspace (and hence, the account) where a form is created through the API. So why not for workspaces?

Is there any way I can choose where a workspace gets created through the API, and if so, how?

1 reply

Laura Marco
Typeform

Hello! Laura here from Typeform’s support team.

 

You can create a workspace in the organisation you belong to by using this API call:


POST - https://api.typeform.com/accounts/{account_id}/workspaces  (Documentation here)

You can use your personal access token, but by specifying the {account_id} of the owner of the organisation, the workspace will be created in that organisation. 
 
Where can you find the account_id of the owner of your organisation? 

  1. Go to the organisation you belong to by switching organisations from the top-left corner of your workspace. More details here: How to switch organisations
  2. Check the URL of your browser. It would be something like this:
    https://admin.typeform.com/accounts/XXXXXXXXXXXXXX/workspaces/YYYYY
  3. Grab the "XXXXXXXXXXXXXX" value. It will be the account_id of the owner of the organisation. 

 
This will create the workspace in the organisation you belong to, still, it will remain private as you will be the only member in the workspace. 
 
You can then use the "Update Workspace" API call:
 

PATCH -  https://api.typeform.com/workspaces/{workspace_id} - Documentation here

and send the request body:

[
{
    "op": "add",
    "path": "/members",
    "value": {
      "email": "test@test.com",
      "role": "owner"
    }
}
]

 

I hope this helps!