Pluggable Google Drive folder management with access control
Sign in with Google to get your unique API key and start using the service.
🔗 Sign in with Google 📦 Download WidgetOAuth2 integration with Google accounts. Each user gets a unique API key for secure access.
Browse, select, and manage Google Drive folders with advanced permission controls.
Grant time-limited access to specific users with automatic expiration management.
Apply official Google Drive restrictions to prevent downloading while allowing viewing.
Reusable JavaScript widget with customizable themes for quick integration.
Automated cron job manages membership expiration and access revocation.
Description: Start Google OAuth2 flow
Response: Redirects to Google OAuth consent screen
Description: OAuth2 callback endpoint
Query Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
| code | string | Required | Authorization code from Google |
Description: Get authenticated user's profile
Headers:
Response:
Description: List Google Drive folders
Headers:
Query Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
| parentId | string | Optional | Parent folder ID (default: 'root') |
Response:
Description: Apply download restrictions to folder and all contents
Headers:
Request Body:
| Parameter | Type | Required | Description |
|---|---|---|---|
| folderId | string | Required | Google Drive folder ID |
Example Request:
Response:
Description: Register a new membership with folder access
Headers:
Request Body:
| Parameter | Type | Required | Description |
|---|---|---|---|
| folderId | string | Required | Google Drive folder ID |
| memberEmail | string | Required | Member's email address |
| endDate | string | Optional | Access expiry date (ISO string) or "-1" for lifetime |
Example Request:
Response:
Description: Revoke member access to folder
Request Body:
| Parameter | Type | Required | Description |
|---|---|---|---|
| folderId | string | Required | Google Drive folder ID |
| memberEmail | string | Required | Member's email address |
Description: Update membership expiration date
Request Body:
| Parameter | Type | Required | Description |
|---|---|---|---|
| folderId | string | Required | Google Drive folder ID |
| memberEmail | string | Required | Member's email address |
| endDate | string | Required | New expiry date (ISO string) or "-1" for lifetime |
Description: List all memberships for authenticated user
Response:
The JavaScript widget provides an easy way to integrate Drive-as-a-Service into your applications.
| Method | Description | Parameters |
|---|---|---|
| authenticate() | Start OAuth flow | None |
| listFolders(parentId) | List Drive folders | parentId (string, optional) |
| registerMembership(folderId, email, endDate) | Register membership | folderId, email, endDate |
| revokeMembership(folderId, email) | Revoke access | folderId, email |
| preventDownload(folderId) | Apply download restrictions | folderId |