> For the complete documentation index, see [llms.txt](https://zloma-scripts.gitbook.io/zloma-scripts/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://zloma-scripts.gitbook.io/zloma-scripts/zloma_garages-paid/features/shared-access.md).

# Shared Access

Players can share individual vehicles or entire garages with other players, with optional time limits and permission controls.

***

## Sharing a Vehicle

1. Open your garage menu
2. Select a vehicle → **Share Vehicle**
3. Choose a nearby player from the list
4. Set options:
   * **Duration** — how long the access lasts (or permanent)
   * **Can Impound** — whether the shared player can send it to impound
   * **Can Store in Org** — whether shared player can store in an org garage

The recipient receives a notification that they've been granted access.

***

## Sharing a Garage(COMING SOON)

Sharing a garage gives the recipient access to **all vehicles** in that garage.

1. Open your garage menu
2. Click **Share Garage**
3. Select a nearby player
4. Configure duration and permissions

***

## Accessing Shared Vehicles

Shared players can:

* See shared vehicles in the garage where they're stored
* Take out shared vehicles
* View in the shared vehicles menu

**Cannot do (by default):**

* Store shared vehicles in their own garages
* Transfer shared vehicles to organizations
* Share a shared vehicle with someone else

***

## Managing Shared Access

### As the Owner

* View all active shares in the vehicle menu
* **Revoke Access** — immediately removes access for a specific player

### As the Recipient

* View vehicles/garages shared with you
* **Cancel My Access** — voluntarily give up access

***

## Time-Based Expiration

Shared access can have a duration. When the time expires:

* Access is automatically revoked
* The recipient can no longer see or take out the vehicle
* No notification needed — the system checks expiration on each access attempt

***

## Database

Shared access records are stored in `zloma_shared_access`:

| Column              | Description                             |
| ------------------- | --------------------------------------- |
| `owner_identifier`  | Vehicle/garage owner                    |
| `target_identifier` | Player receiving access                 |
| `plate`             | Vehicle plate (null if garage share)    |
| `garage_id`         | Garage ID (null if vehicle share)       |
| `expires_at`        | Expiration timestamp (null = permanent) |
| `can_impound`       | Permission flag                         |
| `can_store_in_org`  | Permission flag                         |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://zloma-scripts.gitbook.io/zloma-scripts/zloma_garages-paid/features/shared-access.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
