# The Space object

## Attributes

- `name` (string, Beta)
  The name of the app space. The name must contain only lowercase alphanumeric characters and hyphens.
   It must be unique within the workspace.
  Example: `my-space`
  Constraints: `[ 2 .. 30 ] characters`
- `description` (string, Beta)
  The description of the app space.
  Example: `My app space for team applications.`
  Constraints: `<= 500 characters`
- `status` (object, Beta, Output only)
  The status of the app space.
  - `state` (string, Beta, Output only)
    The state of the app space.
    Possible values:
    - `SPACE_CREATING`
    - `SPACE_ACTIVE`
    - `SPACE_ERROR`
    - `SPACE_DELETING`
    - `SPACE_DELETED`
    - `SPACE_UPDATING`
  - `message` (string, Beta, Output only)
    Message providing context about the current state.
- `id` (string, Beta, Output only)
  The unique identifier of the app space.
- `create_time` (string, Beta, Output only)
  The creation time of the app space. Formatted timestamp in ISO 6801.
- `creator` (string, Beta, Output only)
  The email of the user that created the app space.
  Example: `user@test.com`
- `update_time` (string, Beta, Output only)
  The update time of the app space. Formatted timestamp in ISO 6801.
- `updater` (string, Beta, Output only)
  The email of the user that last updated the app space.
  Example: `user@test.com`
- `resources` (array of object, Beta)
  Resources for the app space. Resources configured at the space level are available to all apps in the space.
  - `name` (string)
    Name of the App Resource.
    Example: `api-key`
    Constraints: `[ 2 .. 30 ] characters`
  - `description` (string)
    Description of the App Resource.
    Example: `API key for external service.`
    Constraints: `<= 50 characters`
  - `secret` (object)
    - `scope` (string)
      Scope of the secret to grant permission on.
      Example: `my-scope`
    - `key` (string)
      Key of the secret to grant permission on.
      Example: `my-key`
    - `permission` (string)
      Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: "READ", "WRITE", "MANAGE".
      Possible values:
      - `READ`
      - `WRITE`
      - `MANAGE`
      Example: `READ`
  - `sql_warehouse` (object)
    - `id` (string)
      Id of the SQL warehouse to grant permission on.
      Example: `e9ca293f79a74b5c`
    - `permission` (string)
      Permission to grant on the SQL warehouse. Supported permissions are: "CAN_MANAGE", "CAN_USE", "IS_OWNER".
      Possible values:
      - `CAN_MANAGE`
      - `CAN_USE`
      - `IS_OWNER`
      Example: `CAN_USE`
  - `serving_endpoint` (object)
    - `name` (string)
      Name of the serving endpoint to grant permission on.
      Example: `databricks-meta-llama-3-1-70b-instruct`
    - `permission` (string)
      Permission to grant on the serving endpoint. Supported permissions are: "CAN_MANAGE", "CAN_QUERY", "CAN_VIEW".
      Possible values:
      - `CAN_MANAGE`
      - `CAN_QUERY`
      - `CAN_VIEW`
      Example: `CAN_QUERY`
  - `job` (object)
    - `id` (string)
      Id of the job to grant permission on.
      Example: `1234`
    - `permission` (string)
      Permissions to grant on the Job. Supported permissions are: "CAN_MANAGE", "IS_OWNER", "CAN_MANAGE_RUN", "CAN_VIEW".
      Possible values:
      - `CAN_MANAGE`
      - `IS_OWNER`
      - `CAN_MANAGE_RUN`
      - `CAN_VIEW`
      Example: `CAN_VIEW`
  - `uc_securable` (object)
    - `securable_full_name` (string)
      Example: `my-catalog.my-schema.my-volume`
    - `securable_type` (string)
      Possible values:
      - `VOLUME`
      - `TABLE`
      - `FUNCTION`
      - `CONNECTION`
      - `MODEL_SERVICE`
      Example: `VOLUME`
    - `permission` (string)
      Possible values:
      - `READ_VOLUME`
      - `WRITE_VOLUME`
      - `SELECT`
      - `EXECUTE`
      - `USE_CONNECTION`
      - `MODIFY`
    - `securable_kind` (string, GA, Output only)
      The securable kind from Unity Catalog.
       See https://docs.databricks.com/api/workspace/tables/get#securable_kind_manifest-securable_kind.
  - `database` (object)
    - `instance_name` (string)
      Example: `my-database-instance`
    - `database_name` (string)
      Example: `my-database`
    - `permission` (string)
      Possible values:
      - `CAN_CONNECT_AND_CREATE`
      Example: `CAN_CONNECT_AND_CREATE`
  - `genie_space` (object)
    - `name` (string)
      Example: `my-genie-space`
    - `space_id` (string)
      Example: `550e8400-e29b-41d4-a716-446655440000`
    - `permission` (string)
      Possible values:
      - `CAN_MANAGE`
      - `CAN_EDIT`
      - `CAN_RUN`
      - `CAN_VIEW`
      Example: `CAN_MANAGE`
  - `experiment` (object)
    - `experiment_id` (string)
      Example: `1021971371025173`
    - `permission` (string)
      Possible values:
      - `CAN_MANAGE`
      - `CAN_EDIT`
      - `CAN_READ`
      Example: `CAN_MANAGE`
  - `app` (object, GA)
    - `name` (string, GA)
      Example: `my-app`
    - `permission` (string, GA)
      Possible values:
      - `CAN_USE`
      Example: `CAN_USE`
  - `postgres` (object, GA)
    - `branch` (string, GA)
      Example: `projects/proj-abc123/branches/branch-xyz789`
    - `database` (string, GA)
      Example: `projects/proj-abc123/branches/branch-xyz789/databases/db-456`
    - `permission` (string, GA)
      Possible values:
      - `CAN_CONNECT_AND_CREATE`
      Example: `CAN_CONNECT_AND_CREATE`
- `user_api_scopes` (array of string, Beta)
  OAuth scopes for apps in the space.
- `effective_user_api_scopes` (array of string, Beta, Output only)
  The effective api scopes granted to the user access token.
- `service_principal_id` (int64, Beta, Output only)
  The service principal ID for the app space.
- `service_principal_name` (string, Beta, Output only)
  The service principal name for the app space.
- `service_principal_client_id` (string, uuid, Beta, Output only)
  The service principal client ID for the app space.
- `usage_policy_id` (string, uuid, Beta)
  The usage policy ID for managing cost at the space level.
  Example: `550e8400-e29b-41d4-a716-446655440000`
  Constraints: `= 36 characters`
- `effective_usage_policy_id` (string, uuid, Beta, Output only)
  The effective usage policy ID used by apps in the space.

## Example

```json
{
  "name": "my-space",
  "description": "My app space for team applications.",
  "status": {
    "state": "SPACE_CREATING",
    "message": "string"
  },
  "id": "string",
  "create_time": "string",
  "creator": "user@test.com",
  "update_time": "string",
  "updater": "user@test.com",
  "resources": [
    {
      "name": "api-key",
      "description": "API key for external service.",
      "secret": {},
      "sql_warehouse": {},
      "serving_endpoint": {},
      "job": {},
      "uc_securable": {},
      "database": {},
      "genie_space": {},
      "experiment": {},
      "app": {},
      "postgres": {}
    }
  ],
  "user_api_scopes": [
    "string"
  ],
  "effective_user_api_scopes": [
    "string"
  ],
  "service_principal_id": 0,
  "service_principal_name": "string",
  "service_principal_client_id": "string",
  "usage_policy_id": "550e8400-e29b-41d4-a716-446655440000",
  "effective_usage_policy_id": "string"
}
```


