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

# Get workspace

> Workspace identity, creation time, timezone, and configured reporting schedule.

Returns the workspace's identity, creation time, timezone, and configured reporting schedule. Returns 404 for a missing or inactive workspace.

Requires workspace Read. There are no query parameters or pagination. This operation does not return activity statistics.

> [!NOTE]
>
> The schedule describes configured cadence and boundary times in the workspace's timezone, not available report ranges. It does not guarantee a completed report, available metrics, or complete historical ingestion. Boundary times are not guaranteed report generation or completion times.
>
> Use [List workspace reporting periods](https://docs.macroscope.com/api-reference/endpoint/list-workspace-reporting-periods.md) to discover computed windows for the operation you plan to call. Discovery reflects currently processed data, not all historical availability or a completeness guarantee; windows can be partial and can change as history is processed.

## Authorization

**Authorization** `string` *required*

`Bearer <key>`. See [Authentication](https://docs.macroscope.com/api#authentication).

## Path parameters

**workspaceType** `string` *required*

`GITHUB_ORGANIZATION` or `GITHUB_USER`.

**workspaceId** `string` *required*

Numeric GitHub ID of the organization or user.

## Response

**workspace** `object`

**properties**

**name** `string`

Resource name, `workspaces/{workspaceType}/{workspaceId}`.

**workspaceType** `string`

`GITHUB_ORGANIZATION` or `GITHUB_USER`.

**workspaceId** `string`

Workspace identifier. Treat as a string, not a number.

**displayName** `string`

Current GitHub organization or user login. Can change.

**timezone** `string`

IANA timezone, e.g. `"America/Los_Angeles"`. Default timezone for metric bucketing and the timezone for reporting boundaries.

**createdAt** `string`

Workspace creation time (RFC 3339), not the earliest activity date or a statement about historical data availability.

**reportingSchedule** `object`

Configured reporting cadence and boundaries, interpreted in `timezone`. Does not identify available ranges.

**properties**

**cadence** `string`

`REPORTING_CADENCE_WEEKLY` or `REPORTING_CADENCE_BIWEEKLY`. `REPORTING_CADENCE_UNSPECIFIED` is not returned for a valid schedule.

**boundaryWeekday** `integer`

Configured weekday: `0` Sunday, `1` Monday, `2` Tuesday, `3` Wednesday, `4` Thursday, `5` Friday, `6` Saturday. Always populated, including `0`.

**boundaryHour** `integer`

Configured hour in the workspace timezone, from `0` to `23`. Always populated, including `0` (midnight).

```bash cURL theme={null}
curl https://api.macroscope.com/api/v1/workspaces/GITHUB_ORGANIZATION/12345678 \
  -H "Authorization: Bearer $MACROSCOPE_API_KEY"
```

```python Python theme={null}
import os, requests

r = requests.get(
    "https://api.macroscope.com/api/v1/workspaces/GITHUB_ORGANIZATION/12345678",
    headers={"Authorization": f"Bearer {os.environ['MACROSCOPE_API_KEY']}"},
)
print(r.json())
```

```javascript JavaScript theme={null}
const res = await fetch(
  "https://api.macroscope.com/api/v1/workspaces/GITHUB_ORGANIZATION/12345678",
  { headers: { Authorization: `Bearer ${process.env.MACROSCOPE_API_KEY}` } }
);
console.log(await res.json());
```

```json 200 theme={null}
{
  "workspace": {
    "name": "workspaces/GITHUB_ORGANIZATION/12345678",
    "workspaceType": "GITHUB_ORGANIZATION",
    "workspaceId": "12345678",
    "displayName": "acme",
    "timezone": "America/Los_Angeles",
    "createdAt": "2024-01-02T03:04:05Z",
    "reportingSchedule": {
      "cadence": "REPORTING_CADENCE_WEEKLY",
      "boundaryWeekday": 5,
      "boundaryHour": 18
    }
  }
}
```

```json 401 theme={null}
{ "code": 16, "message": "unauthenticated" }
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.