Skip to main content

Overview

The General Configuration API manages system-wide settings and organization-specific configurations that don’t fit into forest-specific categories.
This section is reserved for future configuration endpoints such as system preferences, notification settings, and organization-level defaults.

Organization Settings

GET /api/config/organization

Retrieve organization-level settings. Authentication: Required
Permissions: User must belong to the organization

Response

id
string
Organization UUID
name
string
Organization name
code
string
Organization code
settings
object
Organization-specific settings (JSON object)
isActive
boolean
Whether the organization is active

Example: Get Organization Settings

cURL
curl -X GET https://api.confor.com/api/config/organization \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "id": "org_123",
  "name": "Empresa Forestal Example",
  "code": "EFE",
  "settings": {
    "defaultCurrency": "USD",
    "defaultTimezone": "America/Santo_Domingo",
    "fiscalYearStartMonth": 1
  },
  "isActive": true
}

User Preferences

GET /api/config/user/preferences

Retrieve current user’s preferences. Authentication: Required

Response

userId
string
User UUID
preferences
object
User preference settings:
  • language: Preferred language code
  • theme: UI theme preference
  • notifications: Notification settings

PATCH /api/config/user/preferences

Update current user’s preferences. Authentication: Required

Request Body

language
string
Preferred language: es, en, etc.
theme
string
UI theme: light, dark, auto
notifications
object
Notification preferences:
  • email: Enable/disable email notifications
  • inApp: Enable/disable in-app notifications

System Configuration (Admin Only)

GET /api/config/system

Retrieve system-wide configuration. Authentication: Required
Permissions: SUPER_ADMIN role only

Response

version
string
Application version
environment
string
Environment: production, staging, development
features
object
Feature flags for enabled/disabled functionality
maintenance
object
Maintenance mode settings:
  • enabled: Whether maintenance mode is active
  • message: Message to display during maintenance
  • scheduledEnd: Estimated end time

Configuration Best Practices

Organization Defaults: Set organization-level defaults (currency, timezone) to ensure consistent behavior across all users.
User Preferences: Encourage users to set language and notification preferences for personalized experience.
System Configuration: Only modify system configuration through proper change management processes. Incorrect settings can affect all users.

Future Configuration Endpoints

The following endpoints are planned for future releases:
  • Notification Templates (/api/config/notifications)
    • Manage email and in-app notification templates
    • Customize messaging for different event types
  • Report Templates (/api/config/reports)
    • Define custom report layouts and data sources
    • Schedule automated report generation
  • Integration Settings (/api/config/integrations)
    • Configure third-party integrations (GIS providers, accounting systems)
    • Manage API keys and connection settings
  • Workflow Rules (/api/config/workflows)
    • Define approval workflows for patrimony changes
    • Set up automated triggers and notifications
Suggest additional configuration needs by contacting the CONFOR development team.

Build docs developers (and LLMs) love