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

# Get Legal Status

> Check whether the authenticated customer must accept general or contract-specific terms and conditions before using the portal.

# Get Legal Status

Returns the legal terms acceptance status for the current customer. The portal checks this on every authenticated session bootstrap. If `MustAgreeToTerms` is `true`, a blocking modal is shown with the full terms text before the customer can continue.

## Authentication

Requires a valid customer bearer token.

## Response

<ResponseField name="MustAgreeToTerms" type="boolean">
  `true` when the customer must accept one or more outstanding terms before accessing the portal. Show the acceptance modal when this is `true`.
</ResponseField>

<ResponseField name="GeneralTermsAccepted" type="boolean">
  Whether the customer has already accepted the space's general terms and conditions.
</ResponseField>

<ResponseField name="GeneralTerms" type="string">
  HTML or plain-text content of the general terms and conditions to display to the customer.
</ResponseField>

<ResponseField name="ContractTerms" type="array | undefined">
  Array of contract-specific terms the customer must accept. Present only when there are pending contract terms. Each entry contains:
</ResponseField>

<ResponseField name="ContractTerms[].Id" type="number">
  Unique identifier of the contract.
</ResponseField>

<ResponseField name="ContractTerms[].StartDate" type="string">
  ISO 8601 date when the contract starts.
</ResponseField>

<ResponseField name="ContractTerms[].TariffName" type="string">
  Display name of the plan associated with this contract.
</ResponseField>

<ResponseField name="ContractTerms[].TermsAndConditions" type="string">
  HTML or plain-text content of the contract-specific terms to display.
</ResponseField>

## Example Response

```json theme={null}
{
  "MustAgreeToTerms": true,
  "GeneralTermsAccepted": false,
  "GeneralTerms": "<p>By using this portal you agree to our <a href='...'>terms</a>.</p>",
  "ContractTerms": [
    {
      "Id": 101,
      "StartDate": "2026-04-01T00:00:00Z",
      "TariffName": "Hot Desk Monthly",
      "TermsAndConditions": "<p>These terms govern your Hot Desk Monthly membership...</p>"
    }
  ]
}
```

## TypeScript Integration

```typescript theme={null}
import endpoints from '@/api/endpoints'
import { useTypedData } from '@/api/fetchData'

const endpoint = endpoints.system.legal_status()

const { resource: legalStatus } = useTypedData(httpClient, endpoint)

if (legalStatus?.MustAgreeToTerms) {
  // Show the legal terms modal
}
```

## Usage in Portal

| Context                              | Source file                   |
| ------------------------------------ | ----------------------------- |
| Session bootstrap — legal terms gate | `src/App.tsx` or auth context |
| Legal terms acceptance modal         | `src/components/LegalTerms/`  |

## Error Responses

<ResponseField name="401 Unauthorized" type="error">
  The bearer token is missing, expired, or invalid. The customer must sign in.
</ResponseField>

## Related Endpoints

| Method | Endpoint                   | Description                            |
| ------ | -------------------------- | -------------------------------------- |
| `POST` | `/api/public/legal/accept` | Record acceptance of outstanding terms |
