Overview
Projects are the core organizational unit in QFieldCloud. Each project represents a QGIS project that can be synchronized between QGIS desktop and QField mobile app. Projects contain geographic data, configurations, and metadata required for field data collection.Project Model
TheProject model in QFieldCloud is defined in core/models.py:1066 and represents a directory structure containing QGIS project files and associated data.
Key Fields
- id: UUID primary key, auto-generated
- name: Project name (alphanumeric, underscores, hyphens, dots allowed)
- description: Optional text description
- owner: Foreign key to User (Person or Organization)
- is_public: Boolean flag for project visibility
- the_qgis_file_name: Name of the main QGIS project file (.qgs/.qgz)
- project_details: JSON field containing parsed project metadata
- created_at: Timestamp of project creation
- updated_at: Timestamp of last update
- file_storage: Storage backend name (e.g., “s3”, “minio”)
- file_storage_bytes: Cached size of project files
Creating a Project
API Endpoint
Request Body
Example with cURL
Permissions
To create a project, the authenticated user must:- Have an active account
- Have sufficient storage quota
- Be the owner or have admin rights to the organization (if creating for an organization)
core/views/projects_views.py:49 for permission checks.
Project Visibility
Public Projects
Projects withis_public=True:
- Visible to all authenticated users
- Read-only access for non-collaborators
- Owner and collaborators retain edit permissions
- Listed in the public projects endpoint
Private Projects
Projects withis_public=False:
- Only visible to owner and collaborators
- Access controlled by collaboration roles
- Subject to subscription limits on collaborators
Project Settings
File Storage Configuration
Projects can be configured to use different storage backends:STORAGES setting.
Attachment Storage
Separate storage configuration for attachment files:Version Control
Control file version retention:Conflict Resolution
Restricted Project Files
Project Lifecycle
1. Creation
When a project is created:- UUID is auto-generated
- Owner’s storage quota is checked
- Storage backend is initialized
- Timestamps are set
2. File Upload
After creation, upload QGIS project files:.qgs or .qgz file is uploaded:
- A
ProcessProjectfileJobis automatically triggered - Project metadata is extracted into
project_details - Layer information is parsed and validated
3. Active Use
During active use:- Files can be uploaded/downloaded
- Deltas are created from mobile edits
- Packaging jobs prepare data for offline use
- Collaborators can be added/removed
4. Deletion
- Removes all associated files from storage
- Deletes all collaborators
- Removes all jobs and deltas
- Cannot be undone
core/views/projects_views.py:168 for deletion logic.
Project Status
Projects have computed status based on current state:Status Values
- ok: Project is ready to use
- busy: Background jobs are running
- failed: Project has configuration errors
Status Codes
- ok: No issues
- failed_process_projectfile: Missing or invalid QGIS project file
- too_many_collaborators: Exceeds subscription limit
core/models.py:1801 for status computation logic.
Querying Projects
List User’s Projects
- The owner
- A collaborator
- Organization member (for organization-owned projects)
Filtering
TheProjectQueryset.for_user() method filters projects:
user_role: The user’s role on the projectuser_role_origin: How the role was assigned (owner, collaborator, organization, etc.)user_role_is_valid: Whether the role is currently valid
core/models.py:976 for query implementation.
Special Project Types
Shared Datasets Project
A special project namedshared_datasets used for localized datasets:
- Stores shared data layers
- Cannot contain QGIS project files
- Provides data to other projects via localized layers
API Reference
Retrieve Project
Update Project
Transfer Ownership
Change project owner (requires sufficient quota):core/views/projects_views.py:144 for transfer validation.
Related Resources
- Collaboration - Managing project collaborators
- File Management - Uploading and managing project files
- Synchronization - Syncing with QField mobile