---
title: "Create Workspace"
url: "https://developer.pexa.co.uk/apis/workspace-v1-v1/versions/f42817f3-815f-4a74-8ba5-2f83efd8ab42/operations/createWorkspace"
---

> Full API specification: https://developer.pexa.co.uk/apis/workspace-v1-v1/versions/f42817f3-815f-4a74-8ba5-2f83efd8ab42.md

# Create Workspace

`POST` `/partner/api/platformconnect/v1/workspaces`

Operation ID: `createWorkspace`

This API is used to create a new purchase and remortgage workspace using a simple data set, returning the newly created PEXA workspace UUID

## Header parameters

- `X-Request-Correlation-Id` (string, optional)

## Request body (required)

Content types: `application/json`

## Responses

- `202` - ACCEPTED
- `400` - BAD REQUEST
- `500` - INTERNAL SERVER ERROR
- `503` - SERVICE UNAVAILABLE

## OpenAPI definition

```yaml
openapi: 3.0.1
info:
  title: Workspace
  version: v1
servers:
  - url: https://api.pexa.co.uk
    description: API Gateway URL
paths:
  /partner/api/platformconnect/v1/workspaces:
    post:
      tags:
        - WorkspaceV1
      summary: Create Workspace
      description: This API is used to create a new purchase and remortgage workspace
        using a simple data set, returning the newly created PEXA workspace UUID
      security:
        - oauth2:
            - x-api:create:purchase_workspaces
            - x-api:create:remortgage_workspaces
            - create:workspaces
      operationId: createWorkspace
      parameters:
        - in: header
          name: X-Request-Correlation-Id
          schema:
            type: string
            description: The unique identifier for the request
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - transactionType
                - reference
                - property
                - participants
                - parties
              properties:
                transactionType:
                  type: string
                  pattern: ^(PURCHASE|REMORTGAGE)$
                  description: |
                    Allowed values: [`PURCHASE`, `REMORTGAGE`]
                reference:
                  type: string
                  maxLength: 25
                  minLength: 1
                  example: "109344235"
                property:
                  type: object
                  required:
                    - jurisdiction
                    - securityAddress
                  properties:
                    jurisdiction:
                      type: string
                      pattern: ^(ENGLAND_WALES)$
                      example: ENGLAND_WALES
                      description: |
                        Jurisdiction:
                         * `ENGLAND_WALES` - England/Wales
                    securityAddress:
                      type: object
                      required:
                        - postcode
                      properties:
                        name:
                          maxLength: 50
                          minLength: 0
                          type: string
                          example: 1 The House
                        number:
                          maxLength: 4
                          minLength: 0
                          type: string
                          example: 123a
                        flat:
                          maxLength: 30
                          minLength: 0
                          type: string
                          example: Flat 32
                        street:
                          maxLength: 60
                          minLength: 0
                          type: string
                          example: Huddersfield
                        town:
                          maxLength: 30
                          minLength: 0
                          type: string
                          example: West Yorkshire
                        postcode:
                          maxLength: 8
                          minLength: 6
                          type: string
                          example: M16 0RA
                          pattern: ^(([Gg][Ii][Rr]
                            0[Aa]{2})|((([A-Za-z][0-9]{1,2})|(([A-Za-z][A-Ha-hJ-Yj-y][0-9]{1,2})|(([A-Za-z][0-9][A-Za-z])|([A-Za-z][A-Ha-hJ-Yj-y][0-9][A-Za-z]?))))\s[0-9][A-Za-z]{2}))$
                parties:
                  type: array
                  description: >
                    *minItems: 1 - Organisation borrower Party or 1 - Individual
                    borrower Parties* *maxItems: 1 - Organisation borrower Party
                    or 4 - Individual borrower Parties*
                  items:
                    oneOf:
                      - type: object
                        required:
                          - type
                          - partyDetails
                        allOf:
                          - type: object
                            discriminator:
                              propertyName: type
                              mapping:
                                INDIVIDUAL: "#/components/schemas/IndividualDetails"
                                ORGANISATION: "#/components/schemas/OrganisationDetails"
                            properties:
                              role:
                                type: string
                                pattern: ^(BORROWER|BUYER)$
                                description: >
                                  Party Role: Allowed values are BUYER for
                                  purchase workspace and BORROWER for remortgage
                                  workspace
                                   * `BORROWER`
                                   * `BUYER`
                            required:
                              - role
                        properties:
                          type:
                            type: string
                            pattern: ^(INDIVIDUAL)$
                            description: |
                              Party Type:
                               * `INDIVIDUAL`
                          partyDetails:
                            type: object
                            required:
                              - forenames
                              - surname
                            properties:
                              forenames:
                                maxLength: 90
                                minLength: 1
                                type: string
                                example: James Thomas
                                pattern: ^[A-Za-z][A-Za-z\- ']*$
                              surname:
                                maxLength: 50
                                minLength: 1
                                type: string
                                example: Smith
                                pattern: ^[A-Za-z][A-Za-z\- ']*$
                      - type: object
                        allOf:
                          - type: object
                            discriminator:
                              propertyName: type
                              mapping:
                                INDIVIDUAL: "#/components/schemas/IndividualDetails"
                                ORGANISATION: "#/components/schemas/OrganisationDetails"
                            properties:
                              role:
                                type: string
                                pattern: ^(BORROWER|BUYER)$
                                description: >
                                  Party Role: Allowed values are BUYER for
                                  purchase workspace and BORROWER for remortgage
                                  workspace
                                   * `BORROWER`
                                   * `BUYER`
                            required:
                              - role
                        required:
                          - type
                          - partyDetails
                        properties:
                          type:
                            type: string
                            pattern: ^(ORGANISATION)$
                            description: |
                              Party Type:
                               * `ORGANISATION`
                          addresses:
                            type: array
                            items:
                              type: object
                              description: Party address is only applicable for Purchase workspace and should
                                be provided for Organisation buyer party
                              required:
                                - type
                                - details
                              properties:
                                type:
                                  type: string
                                  pattern: ^(REGISTERED_ADDRESS)$
                                  description: |
                                    Address Type:
                                     * `REGISTERED_ADDRESS`
                                details:
                                  type: object
                                  required:
                                    - postcode
                                  properties:
                                    name:
                                      maxLength: 50
                                      minLength: 0
                                      type: string
                                      example: 1 The House
                                    number:
                                      maxLength: 4
                                      minLength: 0
                                      type: string
                                      example: 123a
                                    flat:
                                      maxLength: 30
                                      minLength: 0
                                      type: string
                                      example: Flat 32
                                    street:
                                      maxLength: 60
                                      minLength: 0
                                      type: string
                                      example: Huddersfield
                                    town:
                                      maxLength: 30
                                      minLength: 0
                                      type: string
                                      example: West Yorkshire
                                    postcode:
                                      maxLength: 8
                                      minLength: 6
                                      type: string
                                      example: M16 0RA
                                      pattern: ^(([Gg][Ii][Rr]
                                        0[Aa]{2})|((([A-Za-z][0-9]{1,2})|(([A-Za-z][A-Ha-hJ-Yj-y][0-9]{1,2})|(([A-Za-z][0-9][A-Za-z])|([A-Za-z][A-Ha-hJ-Yj-y][0-9][A-Za-z]?))))\s[0-9][A-Za-z]{2}))$
                            maxItems: 1
                          partyDetails:
                            type: object
                            required:
                              - organisationName
                              - registrationNumber
                              - organisationType
                            properties:
                              organisationName:
                                maxLength: 160
                                minLength: 1
                                type: string
                                example: My Organisation
                                pattern: ^[a-zA-ZÀ-ÖØ-öø-ſĀ-ıĴ-ľŁ-ŉŊ-ŏŐ-őŒ-žǼǺǾẀẂẄỲǽǻǿẁẃẅỳ\d&@£$€¥#‘’'(){}<>!«»“”"\[\]?*=%+\s.,:\/;\\-]+$
                              registrationNumber:
                                type: string
                                minLength: 6
                                maxLength: 8
                                pattern: ^[A-Z0-9]+$
                                example: ABCD1234
                              organisationType:
                                maxLength: 200
                                minLength: 1
                                type: string
                                pattern: ^(LIMITED_COMPANY)$
                                example: LIMITED_COMPANY
                                description: |
                                  Organisation Type:
                                   * `LIMITED_COMPANY`
                participants:
                  type: array
                  items:
                    type: object
                    required:
                      - id
                      - role
                    properties:
                      id:
                        type: string
                        format: uuid
                      role:
                        type: string
                        pattern: ^(INCOMING_LENDER_REPRESENTATIVE|INCOMING_LENDER)$
                        description: |
                          Participant Role:
                           * `INCOMING_LENDER_REPRESENTATIVE`
                           * `INCOMING_LENDER`
                  maxItems: 1
                  minItems: 1
            examples:
              CreateRemortgageWorkspaceRequestWithIndividualBorrower:
                value:
                  transactionType: REMORTGAGE
                  reference: "109344235"
                  property:
                    jurisdiction: ENGLAND_WALES
                    securityAddress:
                      name: 1 The House
                      number: 123a
                      flat: Flat 32
                      street: Huddersfield
                      town: West Yorkshire
                      postcode: M16 0RA
                  parties:
                    - type: INDIVIDUAL
                      role: BORROWER
                      partyDetails:
                        forenames: James
                        surname: Smith
                  participants:
                    - id: 6c6cf8b9-9c9c-4ef4-be70-da426c1d19dd
                      role: INCOMING_LENDER_REPRESENTATIVE
              CreateRemortgageWorkspaceRequestWithOrganisationBorrower:
                value:
                  transactionType: REMORTGAGE
                  reference: "109344235"
                  property:
                    jurisdiction: ENGLAND_WALES
                    securityAddress:
                      name: 1 The House
                      number: 123a
                      flat: Flat 32
                      street: Huddersfield
                      town: West Yorkshire
                      postcode: M16 0RA
                  parties:
                    - type: ORGANISATION
                      role: BORROWER
                      partyDetails:
                        organisationName: James Smith
                        organisationType: LIMITED_COMPANY
                        registrationNumber: "12345678"
                  participants:
                    - id: 6c6cf8b9-9c9c-4ef4-be70-da426c1d19dd
                      role: INCOMING_LENDER_REPRESENTATIVE
              CreatePurchaseWorkspaceRequestWithIndividualBorrower:
                value:
                  transactionType: PURCHASE
                  reference: "109344235"
                  property:
                    jurisdiction: ENGLAND_WALES
                    securityAddress:
                      name: 1 The House
                      number: 123a
                      flat: Flat 32
                      street: Huddersfield
                      town: West Yorkshire
                      postcode: M16 0RA
                  parties:
                    - type: INDIVIDUAL
                      role: BUYER
                      partyDetails:
                        forenames: James
                        surname: Smith
                  participants:
                    - id: 6c6cf8b9-9c9c-4ef4-be70-da426c1d19dd
                      role: INCOMING_LENDER
              CreatePurchaseWorkspaceRequestWithOrganisationBorrower:
                value:
                  transactionType: PURCHASE
                  reference: "109344235"
                  property:
                    jurisdiction: ENGLAND_WALES
                    securityAddress:
                      name: 1 The House
                      number: 123a
                      flat: Flat 32
                      street: Huddersfield
                      town: West Yorkshire
                      postcode: M16 0RA
                  parties:
                    - type: ORGANISATION
                      role: BUYER
                      partyDetails:
                        organisationName: James Smith
                        organisationType: LIMITED_COMPANY
                        registrationNumber: "12345678"
                      addresses:
                        - type: REGISTERED_ADDRESS
                          details:
                            flat: "1234"
                            name: Pexa Ltd.
                            number: "1234"
                            postcode: M16 7YY
                            street: main
                            town: new
                  participants:
                    - id: 6c6cf8b9-9c9c-4ef4-be70-da426c1d19dd
                      role: INCOMING_LENDER_REPRESENTATIVE
        required: true
      responses:
        "202":
          description: ACCEPTED
          headers:
            X-API-Version:
              schema:
                type: string
                description: The API version that was used to process the request.
            X-Request-Correlation-Id:
              schema:
                type: string
                description: The unique identifier for the request
          content:
            application/json:
              schema:
                type: object
                required:
                  - reference
                properties:
                  reference:
                    type: string
                    maxLength: 25
                    minLength: 1
                    example: "109344235"
                  workspaceId:
                    type: string
                    format: uuid
                  workspaceReferenceId:
                    type: string
                    example: PEXA210000012
        "400":
          description: BAD REQUEST
          headers:
            X-API-Version:
              schema:
                type: string
                description: The API version that was used to process the request.
            X-Request-Correlation-Id:
              schema:
                type: string
                description: The unique identifier for the request
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        field:
                          type: string
                          description: Field
                        message:
                          type: string
                          description: Error message
              example:
                errors:
                  - field: securityAddress.number
                    message: size must be between 0 and 4
                  - field: reference
                    message: size must be between 1 and 25
        "500":
          description: INTERNAL SERVER ERROR
          headers:
            X-API-Version:
              schema:
                type: string
                description: The API version that was used to process the request.
            X-Request-Correlation-Id:
              schema:
                type: string
                description: The unique identifier for the request
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        field:
                          type: string
                          description: Field
                        message:
                          type: string
                          description: Error message
              example:
                errors:
                  - message: Internal Server Error
        "503":
          description: SERVICE UNAVAILABLE
          headers:
            X-API-Version:
              schema:
                type: string
                description: The API version that was used to process the request.
            X-Request-Correlation-Id:
              schema:
                type: string
                description: The unique identifier for the request
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        field:
                          type: string
                          description: Field
                        message:
                          type: string
                          description: Error message
              example:
                errors:
                  - message: Service under maintenance
security:
  - oauth2:
      - x-api:create:purchase_workspaces
      - x-api:create:remortgage_workspaces
      - create:workspaces
components:
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://login.pexauk.co.uk/oauth/token
          scopes:
            x-api:create:purchase_workspaces: Permission to create purchase workspace
            x-api:create:remortgage_workspaces: Permission to create remortgage workspace
            x-api:cancel:workspaces: Permission to cancel the workspace
            add:law_firm_reference: add law firm reference
            add:legal_representation_details: add legal representation details
            view:workspaces: view workspace
            create:title_change_request: create title change request
            edit:workspace_parties: edit workspace parties
            x-api:add:legal_representation_details: Permission to add party representation
            x-api:edit:external_law_firm_details: Permission to update external law firm representation
            create:workspaces: Permission to create workspaces
            edit:workspaces: Permission to edit workspaces
            edit:lodgement_proprietors: Permission to edit proprietors linked to lodgement case
            view:lodgement_proprietors: Permission to view proprietors linked to lodgement case
            add:workspace_participants: Permission to add workspace participants
            edit:external_law_firm_details: Permission to edit external law firm details
            edit:law_firm_reference: Permission to edit law firm reference
```
