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

# Update the workspace setup

> Changes the booking link, attribution and outreach schedule. Only the fields sent change. Needs the owner or admin role.

## OpenAPI

```json
{
  "openapi": "3.2.0",
  "info": {
    "title": "Bavlio API",
    "version": "1.0.0"
  },
  "paths": {
    "/workspace": {
      "patch": {
        "tags": [
          "Workspaces"
        ],
        "operationId": "workspaces.updateWorkspaceSetup",
        "parameters": [],
        "security": [
          {
            "bearer": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "Workspace id. Send it in the bavlio-workspace header to act in this workspace."
                    },
                    "org_id": {
                      "type": "string",
                      "description": "Tenant id (a UUID) that scopes the workspace's lead data."
                    },
                    "name": {
                      "type": "string",
                      "description": "Company name."
                    },
                    "sells": {
                      "type": "string",
                      "description": "What the company sells, in one line."
                    },
                    "problems": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Problems the company solves for its customers."
                    },
                    "customers": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Names of current customers; leads at these companies are skipped."
                    },
                    "domain": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ],
                      "description": "Company website domain; null when there is none."
                    },
                    "booking_link": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ],
                      "description": "HTTPS link where leads book a meeting; null when none is set."
                    },
                    "attribution": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "chatgpt",
                            "claude",
                            "perplexity",
                            "google",
                            "reddit",
                            "linkedin",
                            "youtube",
                            "friend",
                            "accelerator",
                            "other"
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ],
                      "description": "Where the user heard about Bavlio; null when not recorded."
                    },
                    "timezone": {
                      "type": "string",
                      "description": "IANA time zone of the outreach schedule; UTC until one is set."
                    },
                    "week_start": {
                      "type": "string",
                      "enum": [
                        "monday",
                        "sunday"
                      ],
                      "description": "First day of the week in Bavlio's calendars."
                    },
                    "working_days": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "sunday",
                          "monday",
                          "tuesday",
                          "wednesday",
                          "thursday",
                          "friday",
                          "saturday"
                        ]
                      },
                      "description": "Days of the week outreach runs on."
                    },
                    "working_hours": {
                      "type": "object",
                      "properties": {
                        "start": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "First working hour in the workspace time zone, from 0 to 23.",
                          "allOf": [
                            {
                              "minimum": 0,
                              "maximum": 23
                            }
                          ]
                        },
                        "end": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "Hour work stops in the workspace time zone, from 1 to 24 and after start.",
                          "allOf": [
                            {
                              "minimum": 1,
                              "maximum": 24
                            }
                          ]
                        }
                      },
                      "required": [
                        "start",
                        "end"
                      ],
                      "additionalProperties": false,
                      "description": "Hours of each working day during which outreach runs."
                    },
                    "onboarded_at": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ],
                      "description": "When onboarding was completed, as an ISO 8601 timestamp; null until then."
                    },
                    "created_at": {
                      "type": "string",
                      "description": "When the workspace was created, as an ISO 8601 timestamp."
                    }
                  },
                  "required": [
                    "id",
                    "org_id",
                    "name",
                    "sells",
                    "problems",
                    "customers",
                    "domain",
                    "booking_link",
                    "attribution",
                    "timezone",
                    "week_start",
                    "working_days",
                    "working_hours",
                    "onboarded_at",
                    "created_at"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "RequestInvalidBody",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RequestInvalidBodyEncoded"
                }
              }
            }
          },
          "401": {
            "description": "AuthMissing | AuthInvalid",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/AuthMissingEncoded"
                    },
                    {
                      "$ref": "#/components/schemas/AuthInvalidEncoded"
                    }
                  ]
                }
              }
            }
          },
          "403": {
            "description": "TeamAdminRequired",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TeamAdminRequiredEncoded"
                }
              }
            }
          },
          "404": {
            "description": "WorkspaceNotFound",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceNotFoundEncoded"
                }
              }
            }
          }
        },
        "description": "Changes the booking link, attribution and outreach schedule. Only the fields sent change. Needs the owner or admin role.",
        "summary": "Update the workspace setup",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "booking_link": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "HTTPS link where leads book a meeting, like `https://calendly.com/you/30min`; null removes it."
                  },
                  "attribution": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "chatgpt",
                          "claude",
                          "perplexity",
                          "google",
                          "reddit",
                          "linkedin",
                          "youtube",
                          "friend",
                          "accelerator",
                          "other"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "Where the user heard about Bavlio; null clears it."
                  },
                  "timezone": {
                    "type": "string",
                    "description": "IANA time zone the working hours are in, like America/New_York."
                  },
                  "week_start": {
                    "type": "string",
                    "enum": [
                      "monday",
                      "sunday"
                    ],
                    "description": "First day of the week in Bavlio's calendars."
                  },
                  "working_days": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "sunday",
                        "monday",
                        "tuesday",
                        "wednesday",
                        "thursday",
                        "friday",
                        "saturday"
                      ]
                    },
                    "minItems": 1,
                    "description": "Days of the week outreach runs on. At least one."
                  },
                  "working_hours": {
                    "type": "object",
                    "properties": {
                      "start": {
                        "type": "integer",
                        "minimum": -9007199254740991,
                        "maximum": 9007199254740991,
                        "description": "First working hour in the workspace time zone, from 0 to 23.",
                        "allOf": [
                          {
                            "minimum": 0,
                            "maximum": 23
                          }
                        ]
                      },
                      "end": {
                        "type": "integer",
                        "minimum": -9007199254740991,
                        "maximum": 9007199254740991,
                        "description": "Hour work stops in the workspace time zone, from 1 to 24 and after start.",
                        "allOf": [
                          {
                            "minimum": 1,
                            "maximum": 24
                          }
                        ]
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ],
                    "additionalProperties": false,
                    "description": "Hours of each working day during which outreach runs."
                  }
                },
                "additionalProperties": false
              }
            }
          },
          "required": true
        }
      }
    }
  },
  "components": {
    "schemas": {
      "AuthInvalidEncoded": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "AuthInvalid"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              401
            ]
          },
          "code": {
            "type": "string",
            "enum": [
              "auth_invalid"
            ]
          },
          "message": {
            "type": "string",
            "enum": [
              "Bearer credential rejected"
            ]
          }
        },
        "required": [
          "_tag",
          "statusCode",
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "AuthMissingEncoded": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "AuthMissing"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              401
            ]
          },
          "code": {
            "type": "string",
            "enum": [
              "auth_missing"
            ]
          },
          "message": {
            "type": "string",
            "enum": [
              "Bearer credential required"
            ]
          }
        },
        "required": [
          "_tag",
          "statusCode",
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "RequestInvalidBodyEncoded": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "RequestInvalidBody"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              400
            ]
          },
          "code": {
            "type": "string",
            "enum": [
              "invalid_body"
            ]
          },
          "message": {
            "type": "string"
          }
        },
        "required": [
          "_tag",
          "statusCode",
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "WorkspaceNotFoundEncoded": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "WorkspaceNotFound"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              404
            ]
          },
          "code": {
            "type": "string",
            "enum": [
              "workspace_not_found"
            ]
          },
          "message": {
            "type": "string",
            "enum": [
              "No such workspace for this account: save a company profile or pick a workspace you belong to"
            ]
          }
        },
        "required": [
          "_tag",
          "statusCode",
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "TeamAdminRequiredEncoded": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "TeamAdminRequired"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              403
            ]
          },
          "code": {
            "type": "string",
            "enum": [
              "team_admin_required"
            ]
          },
          "message": {
            "type": "string",
            "enum": [
              "Only the workspace owner and admins can do this"
            ]
          }
        },
        "required": [
          "_tag",
          "statusCode",
          "code",
          "message"
        ],
        "additionalProperties": false
      }
    },
    "securitySchemes": {
      "bearer": {
        "description": "Send `Authorization: Bearer <token>`. The token is an API key, which starts with `bav_` and comes from creating an API key or starting a registration, or the access token of a Bavlio sign-in.",
        "type": "http",
        "scheme": "Bearer"
      }
    }
  },
  "security": [],
  "tags": [
    {
      "name": "Registration",
      "description": "Open a Bavlio account without signing in. Starting a registration returns an API key for a new ephemeral account, which becomes permanent once its email address is verified."
    },
    {
      "name": "Authentication",
      "description": "Identify the calling account, finish a registration and manage the account's API keys."
    },
    {
      "name": "Account",
      "description": "The account behind your sign-in, and deleting it."
    },
    {
      "name": "Workspaces",
      "description": "A workspace holds the company profile, outreach schedule, team, campaigns and billing Bavlio works with. Calls that act in a workspace use the one whose id is in the bavlio-workspace header, or the account's default workspace when the header is absent."
    },
    {
      "name": "Teams",
      "description": "Manage who belongs to a workspace: its members, their roles and the invitations to join it. Each workspace's plan sets how many team seats it has."
    },
    {
      "name": "Campaigns",
      "description": "A campaign finds leads that match an ideal customer profile (ICP) and buying signals, and reaches out to them through its sequence of LinkedIn and email steps."
    },
    {
      "name": "Lead imports",
      "description": "Bring your own leads: preview a CSV, confirm which column holds what, then import it into a campaign, where the leads go through the same sequence as the ones Bavlio finds."
    },
    {
      "name": "Sequences",
      "description": "A campaign's sequence is the steps Bavlio runs for each lead: profile visits, likes, invites, LinkedIn messages, emails, waits and conditions. Every message and email waits in the review queue for approval before it is sent."
    },
    {
      "name": "Inbox",
      "description": "Conversations with the people your campaigns reached and, for accounts that opt in, your other LinkedIn and email conversations: read them, reply to them and follow changes live."
    },
    {
      "name": "Reviews",
      "description": "Messages and emails go to a lead only after someone approves them. The review queue holds the replies Bavlio drafted for people who answered and the messages and emails it drafted for campaign sequences."
    },
    {
      "name": "Billing",
      "description": "The plans on offer and the workspace's subscription and usage. Plan changes, cancellation and the billing portal need the workspace owner or an admin."
    },
    {
      "name": "LinkedIn",
      "description": "Connect the LinkedIn accounts your campaigns send from, confirm their sign-ins, choose the country LinkedIn sees them from, and disconnect them."
    },
    {
      "name": "Meetings",
      "description": "Meetings booked through the workspace's calendar tool (Google Calendar, Calendly or Cal.com), and the calendar connection that imports them."
    },
    {
      "name": "Email",
      "description": "Connect a Bavimail account, add sending domains and tracking domains, and create the inboxes campaigns send email from."
    }
  ],
  "servers": [
    {
      "url": "https://api.bavlio.com"
    }
  ]
}
```
