> ## Documentation Index
> Fetch the complete documentation index at: https://docs.seam.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a Workspace

> Creates a new [workspace](https://docs.seam.co/core-concepts/workspaces).



## OpenAPI

````yaml /openapi.json post /workspaces/create
openapi: 3.0.0
info:
  title: Seam Connect
  version: 1.0.0
servers:
  - url: https://connect.getseam.com
security: []
tags:
  - description: access_codes
    name: /access_codes
  - description: acs
    name: /acs
  - description: action_attempts
    name: /action_attempts
  - description: client_sessions
    name: /client_sessions
  - description: connected_accounts
    name: /connected_accounts
  - description: connect_webviews
    name: /connect_webviews
  - description: devices
    name: /devices
  - description: events
    name: /events
  - description: health
    name: /health
  - description: locks
    name: /locks
  - description: networks
    name: /networks
  - description: noise_sensors
    name: /noise_sensors
  - description: phones
    name: /phones
  - description: thermostats
    name: /thermostats
  - description: user_identities
    name: /user_identities
  - description: webhooks
    name: /webhooks
  - description: workspaces
    name: /workspaces
paths:
  /workspaces/create:
    post:
      tags:
        - /workspaces
      summary: Create a Workspace
      description: >-
        Creates a new
        [workspace](https://docs.seam.co/core-concepts/workspaces).
      operationId: workspacesCreatePost
      requestBody:
        content:
          application/json:
            schema:
              properties:
                company_name:
                  description: Company name for the new workspace.
                  type: string
                connect_partner_name:
                  deprecated: true
                  description: Connect partner name for the new workspace.
                  nullable: true
                  type: string
                  x-deprecated: Use `company_name` instead.
                connect_webview_customization:
                  description: >-
                    [Connect
                    Webview](https://docs.seam.co/core-concepts/connect-webviews)
                    customizations for the new workspace. See also [Customize
                    the Look and Feel of Your Connect
                    Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
                  properties:
                    logo_shape:
                      description: >-
                        Logo shape for [Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                        in the new workspace. See also [Customize the Look and
                        Feel of Your Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
                      enum:
                        - circle
                        - square
                      nullable: true
                      type: string
                    primary_button_color:
                      description: >-
                        Primary button color for [Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                        in the new workspace. See also [Customize the Look and
                        Feel of Your Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
                      nullable: true
                      type: string
                    primary_button_text_color:
                      description: >-
                        Primary button text color for [Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                        in the new workspace. See also [Customize the Look and
                        Feel of Your Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
                      nullable: true
                      type: string
                    success_message:
                      description: >-
                        Success message for [Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                        in the new workspace. See also [Customize the Look and
                        Feel of Your Connect
                        Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
                      nullable: true
                      type: string
                  type: object
                is_sandbox:
                  default: false
                  description: >-
                    Indicates whether the new workspace is a [sandbox
                    workspace](https://docs.seam.co/core-concepts/workspaces#sandbox-workspaces).
                  type: boolean
                name:
                  description: Name of the new workspace.
                  type: string
                organization_id:
                  description: ID of the organization to associate with the new workspace.
                  format: uuid
                  type: string
                webview_logo_shape:
                  deprecated: true
                  enum:
                    - circle
                    - square
                  type: string
                  x-deprecated: >-
                    Use `connect_webview_customization.webview_logo_shape`
                    instead.
                webview_primary_button_color:
                  deprecated: true
                  type: string
                  x-deprecated: >-
                    Use
                    `connect_webview_customization.webview_primary_button_color`
                    instead.
                webview_primary_button_text_color:
                  deprecated: true
                  type: string
                  x-deprecated: >-
                    Use
                    `connect_webview_customization.webview_primary_button_text_color`
                    instead.
                webview_success_message:
                  deprecated: true
                  type: string
                  x-deprecated: >-
                    Use `connect_webview_customization.webview_success_message`
                    instead.
              required:
                - name
              type: object
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  ok:
                    type: boolean
                  workspace:
                    $ref: '#/components/schemas/workspace'
                required:
                  - workspace
                  - ok
                type: object
          description: OK
        '400':
          description: Bad Request
        '401':
          description: Unauthorized
      security:
        - pat_without_workspace: []
        - console_session_with_workspace: []
        - console_session_without_workspace: []
      x-codeSamples:
        - lang: javascript
          label: Seam SDK
          source: |-
            await seam.workspaces.create({
              name: "My Sandbox Workspace",
              company_name: "Acme",
              connect_partner_name: "Acme",
              is_sandbox: true,
              is_publishable_key_auth_enabled: true,
              publishable_key: "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
              webview_primary_button_color: "#232426",
              webview_primary_button_text_color: "#FFFDE7",
              webview_logo_shape: "circle",
              webview_success_message:
                "Your account has been successfully connected to Acme!",
              connect_webview_customization: {
                inviter_logo_url:
                  "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                logo_shape: "circle",
                primary_button_color: "#232426",
                primary_button_text_color: "#FFFDE7",
                success_message: "Your account has been successfully connected to Acme!",
              },
            });

            /*
            {
              "company_name": "Acme",
              "connect_partner_name": "Acme",
              "connect_webview_customization": {
                "inviter_logo_url": "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                "logo_shape": "circle",
                "primary_button_color": "#232426",
                "primary_button_text_color": "#FFFDE7",
                "success_message": "Your account has been successfully connected to Acme!"
              },
              "is_sandbox": true,
              "is_publishable_key_auth_enabled": true,
              "publishable_key": "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
              "is_suspended": false,
              "name": "My Sandbox Workspace",
              "workspace_id": "6a0b6282-6a98-4fef-811e-0904c485ac7a"
            }
            */
        - lang: bash
          label: cURL
          source: >-
            curl --include --request POST
            "https://connect.getseam.com/workspaces/create" \
              --header "Authorization: Bearer $SEAM_API_KEY" \
              --json @- <<EOF
            {
              "name": "My Sandbox Workspace",
              "company_name": "Acme",
              "connect_partner_name": "Acme",
              "is_sandbox": true,
              "is_publishable_key_auth_enabled": true,
              "publishable_key": "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
              "webview_primary_button_color": "#232426",
              "webview_primary_button_text_color": "#FFFDE7",
              "webview_logo_shape": "circle",
              "webview_success_message": "Your account has been successfully connected to Acme!",
              "connect_webview_customization": {
                "inviter_logo_url": "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                "logo_shape": "circle",
                "primary_button_color": "#232426",
                "primary_button_text_color": "#FFFDE7",
                "success_message": "Your account has been successfully connected to Acme!"
              }
            }

            EOF


            # Response:

            # {

            #   "workspace": {

            #     "company_name": "Acme",

            #     "connect_partner_name": "Acme",

            #     "connect_webview_customization": {

            #       "inviter_logo_url":
            "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",

            #       "logo_shape": "circle",

            #       "primary_button_color": "#232426",

            #       "primary_button_text_color": "#FFFDE7",

            #       "success_message": "Your account has been successfully
            connected to Acme!"

            #     },

            #     "is_sandbox": true,

            #     "is_publishable_key_auth_enabled": true,

            #     "publishable_key": "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",

            #     "is_suspended": false,

            #     "name": "My Sandbox Workspace",

            #     "workspace_id": "6a0b6282-6a98-4fef-811e-0904c485ac7a"

            #   }

            # }
        - lang: python
          label: Seam SDK
          source: |-
            seam.workspaces.create(
                name="My Sandbox Workspace",
                company_name="Acme",
                connect_partner_name="Acme",
                is_sandbox=true,
                is_publishable_key_auth_enabled=true,
                publishable_key="seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
                webview_primary_button_color="#232426",
                webview_primary_button_text_color="#FFFDE7",
                webview_logo_shape="circle",
                webview_success_message="Your account has been successfully connected to Acme!",
                connect_webview_customization={
                    "inviter_logo_url": "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                    "logo_shape": "circle",
                    "primary_button_color": "#232426",
                    "primary_button_text_color": "#FFFDE7",
                    "success_message": "Your account has been successfully connected to Acme!",
                },
            )

            # Workspace(
                company_name="Acme",
                connect_partner_name="Acme",
                connect_webview_customization={
                    "inviter_logo_url": "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                    "logo_shape": "circle",
                    "primary_button_color": "#232426",
                    "primary_button_text_color": "#FFFDE7",
                    "success_message": "Your account has been successfully connected to Acme!",
                },
                is_sandbox=true,
                is_publishable_key_auth_enabled=true,
                publishable_key="seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
                is_suspended=false,
                name="My Sandbox Workspace",
                workspace_id="6a0b6282-6a98-4fef-811e-0904c485ac7a",
            )
        - lang: ruby
          label: Seam SDK
          source: |-
            seam.workspaces.create(
              name: "My Sandbox Workspace",
              company_name: "Acme",
              connect_partner_name: "Acme",
              is_sandbox: true,
              is_publishable_key_auth_enabled: true,
              publishable_key: "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
              webview_primary_button_color: "#232426",
              webview_primary_button_text_color: "#FFFDE7",
              webview_logo_shape: "circle",
              webview_success_message: "Your account has been successfully connected to Acme!",
              connect_webview_customization: {
                inviter_logo_url:
                  "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                logo_shape: "circle",
                primary_button_color: "#232426",
                primary_button_text_color: "#FFFDE7",
                success_message: "Your account has been successfully connected to Acme!",
              },
            )

            # => {
              "company_name" => "Acme",
              "connect_partner_name" => "Acme",
              "connect_webview_customization" => {
                inviter_logo_url:
                  "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                logo_shape: "circle",
                primary_button_color: "#232426",
                primary_button_text_color: "#FFFDE7",
                success_message: "Your account has been successfully connected to Acme!",
              },
              "is_sandbox" => true,
              "is_publishable_key_auth_enabled" => true,
              "publishable_key" => "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
              "is_suspended" => false,
              "name" => "My Sandbox Workspace",
              "workspace_id" => "6a0b6282-6a98-4fef-811e-0904c485ac7a",
            }
        - lang: php
          label: Seam SDK
          source: |-
            $seam->workspaces->create(
                name: "My Sandbox Workspace",
                company_name: "Acme",
                connect_partner_name: "Acme",
                is_sandbox: true,
                is_publishable_key_auth_enabled: true,
                publishable_key: "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
                webview_primary_button_color: "#232426",
                webview_primary_button_text_color: "#FFFDE7",
                webview_logo_shape: "circle",
                webview_success_message: "Your account has been successfully connected to Acme!",
                connect_webview_customization: [
                    "inviter_logo_url" =>
                        "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                    "logo_shape" => "circle",
                    "primary_button_color" => "#232426",
                    "primary_button_text_color" => "#FFFDE7",
                    "success_message" =>
                        "Your account has been successfully connected to Acme!",
                ],
            );

            // [
                "company_name" => "Acme",
                "connect_partner_name" => "Acme",
                "connect_webview_customization" => [
                    "inviter_logo_url" =>
                        "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",
                    "logo_shape" => "circle",
                    "primary_button_color" => "#232426",
                    "primary_button_text_color" => "#FFFDE7",
                    "success_message" =>
                        "Your account has been successfully connected to Acme!",
                ],
                "is_sandbox" => true,
                "is_publishable_key_auth_enabled" => true,
                "publishable_key" => "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",
                "is_suspended" => false,
                "name" => "My Sandbox Workspace",
                "workspace_id" => "6a0b6282-6a98-4fef-811e-0904c485ac7a",
            ];
        - lang: bash
          label: Seam CLI
          source: >-
            seam workspaces create --name "My Sandbox Workspace" --company_name
            "Acme" --connect_partner_name "Acme" --is_sandbox true
            --is_publishable_key_auth_enabled true --publishable_key
            "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE"
            --webview_primary_button_color "#232426"
            --webview_primary_button_text_color "#FFFDE7" --webview_logo_shape
            "circle" --webview_success_message "Your account has been
            successfully connected to Acme!" --connect_webview_customization
            {"inviter_logo_url":"https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c","logo_shape":"circle","primary_button_color":"#232426","primary_button_text_color":"#FFFDE7","success_message":"Your
            account has been successfully connected to Acme!"}


            # {

            #   "company_name": "Acme",

            #   "connect_partner_name": "Acme",

            #   "connect_webview_customization": {

            #     "inviter_logo_url":
            "https://connect.getseam.com/internal/images/view?image_id=1de135fa-f0c2-4e57-90d0-6b9a7d090a0c",

            #     "logo_shape": "circle",

            #     "primary_button_color": "#232426",

            #     "primary_button_text_color": "#FFFDE7",

            #     "success_message": "Your account has been successfully
            connected to Acme!"

            #   },

            #   "is_sandbox": true,

            #   "is_publishable_key_auth_enabled": true,

            #   "publishable_key": "seam_pk1fGd41X_zKs0ZELRTEc8nWxiBsEXAMPLE",

            #   "is_suspended": false,

            #   "name": "My Sandbox Workspace",

            #   "workspace_id": "6a0b6282-6a98-4fef-811e-0904c485ac7a"

            # }
components:
  schemas:
    workspace:
      description: >-
        Represents a Seam
        [workspace](https://docs.seam.co/core-concepts/workspaces). A workspace
        is a top-level entity that encompasses all other resources below it,
        such as devices, connected accounts, and Connect Webviews. Seam provides
        two types of workspaces. A [sandbox
        workspace](https://docs.seam.co/core-concepts/workspaces#sandbox-workspaces)
        is a special type of workspace designed for testing code.
      properties:
        company_name:
          description: >-
            Company name associated with the
            [workspace](https://docs.seam.co/core-concepts/workspaces).
          type: string
        connect_partner_name:
          deprecated: true
          nullable: true
          type: string
          x-deprecated: Use `company_name` instead.
        connect_webview_customization:
          properties:
            inviter_logo_url:
              description: >-
                URL of the inviter logo for [Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                in the workspace. See also [Customize the Look and Feel of Your
                Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
              type: string
            logo_shape:
              description: >-
                Logo shape for [Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                in the workspace. See also [Customize the Look and Feel of Your
                Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
              enum:
                - circle
                - square
              type: string
            primary_button_color:
              description: >-
                Primary button color for [Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                in the workspace. See also [Customize the Look and Feel of Your
                Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
              type: string
            primary_button_text_color:
              description: >-
                Primary button text color for [Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                in the workspace. See also [Customize the Look and Feel of Your
                Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
              type: string
            success_message:
              description: >-
                Success message for [Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews)
                in the workspace. See also [Customize the Look and Feel of Your
                Connect
                Webviews](https://docs.seam.co/core-concepts/connect-webviews/customizing-connect-webviews#customize-the-look-and-feel-of-your-connect-webviews).
              type: string
          type: object
        is_publishable_key_auth_enabled:
          description: >-
            Indicates whether publishable key authentication is enabled for this
            workspace.
          type: boolean
        is_sandbox:
          description: >-
            Indicates whether the workspace is a [sandbox
            workspace](https://docs.seam.co/core-concepts/workspaces#sandbox-workspaces).
          type: boolean
        is_suspended:
          description: >-
            Indicates whether the [sandbox
            workspace](https://docs.seam.co/core-concepts/workspaces#sandbox-workspaces)
            is suspended. Seam suspends sandbox workspaces that have not been
            accessed in 14 days.
          type: boolean
        name:
          description: >-
            Name of the
            [workspace](https://docs.seam.co/core-concepts/workspaces).
          type: string
        publishable_key:
          description: >-
            Publishable key for the
            [workspace](https://docs.seam.co/core-concepts/workspaces). This key
            is used to identify the workspace in client-side applications.
          type: string
        workspace_id:
          description: >-
            ID of the
            [workspace](https://docs.seam.co/core-concepts/workspaces).
          format: uuid
          type: string
      required:
        - workspace_id
        - name
        - company_name
        - is_sandbox
        - connect_webview_customization
        - is_suspended
        - connect_partner_name
        - is_publishable_key_auth_enabled
      type: object
      x-route-path: /workspaces
  securitySchemes:
    pat_without_workspace:
      bearerFormat: API Token
      scheme: bearer
      type: http
    console_session_with_workspace:
      bearerFormat: Console Session Token
      scheme: bearer
      type: http
    console_session_without_workspace:
      bearerFormat: Console Session Token
      scheme: bearer
      type: http

````